Package yapion.serializing
Class YAPIONDeserializer
- java.lang.Object
-
- yapion.serializing.YAPIONDeserializer
-
public final class YAPIONDeserializer extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description YAPIONDeserializer(@NonNull YAPIONObject yapionObject, java.lang.String context)
Creates a YAPIONDeserializer for deserializing a YAPIONObject with a specified context.YAPIONDeserializer(@NonNull YAPIONObject yapionObject, java.lang.String context, @NonNull TypeReMapper typeReMapper)
Creates a YAPIONDeserializer for deserializing a YAPIONObject with a specified context.
-
Method Summary
Modifier and Type Method Description static java.lang.Object
deserialize(@NonNull YAPIONObject yapionObject)
Serialize an YAPION Object to an Object.static java.lang.Object
deserialize(@NonNull YAPIONObject yapionObject, @NonNull TypeReMapper typeReMapper)
Serialize an YAPION Object to an Object.static java.lang.Object
deserialize(@NonNull YAPIONObject yapionObject, java.lang.String context)
Serialize an YAPION Object to an Object.static java.lang.Object
deserialize(@NonNull YAPIONObject yapionObject, java.lang.String context, @NonNull TypeReMapper typeReMapper)
Serialize an YAPION Object to an Object.java.lang.Class<?>
getClass(java.lang.String className)
DeserializeResult
getDeserializeResult()
Get theDeserializeResult
.java.lang.Object
getObject()
Get the deserialized Object.YAPIONDeserializer
parse()
Parses the YAPIONObject to the Object.java.lang.Object
parse(YAPIONAnyType yapionAnyType)
java.lang.Object
parse(YAPIONAnyType yapionAnyType, YAPIONDeserializer yapionDeserializer)
Deprecated.since 0.12.0 useparse(YAPIONAnyType)
instead
-
-
-
Constructor Detail
-
YAPIONDeserializer
public YAPIONDeserializer(@NonNull @NonNull YAPIONObject yapionObject, java.lang.String context)
Creates a YAPIONDeserializer for deserializing a YAPIONObject with a specified context.- Parameters:
yapionObject
- to deserializecontext
- the context for deserialization
-
YAPIONDeserializer
public YAPIONDeserializer(@NonNull @NonNull YAPIONObject yapionObject, java.lang.String context, @NonNull @NonNull TypeReMapper typeReMapper)
Creates a YAPIONDeserializer for deserializing a YAPIONObject with a specified context.- Parameters:
yapionObject
- to deserializecontext
- the context for deserializationtypeReMapper
- the mapper to remap any '@type' variable to a new class
-
-
Method Detail
-
deserialize
public static java.lang.Object deserialize(@NonNull @NonNull YAPIONObject yapionObject)
Serialize an YAPION Object to an Object.- Parameters:
yapionObject
- to deserialize- Returns:
- Object from the YAPIONObject to deserialize
-
deserialize
public static java.lang.Object deserialize(@NonNull @NonNull YAPIONObject yapionObject, @NonNull @NonNull TypeReMapper typeReMapper)
Serialize an YAPION Object to an Object.- Parameters:
yapionObject
- to deserializetypeReMapper
- the mapper to remap any '@type' variable to a new class- Returns:
- Object from the YAPIONObject to deserialize
-
deserialize
public static java.lang.Object deserialize(@NonNull @NonNull YAPIONObject yapionObject, java.lang.String context)
Serialize an YAPION Object to an Object.- Parameters:
yapionObject
- to deserializecontext
- the context for deserialization- Returns:
- Object from the YAPIONObject to deserialize
-
deserialize
public static java.lang.Object deserialize(@NonNull @NonNull YAPIONObject yapionObject, java.lang.String context, @NonNull @NonNull TypeReMapper typeReMapper)
Serialize an YAPION Object to an Object.- Parameters:
yapionObject
- to deserializecontext
- the context for deserializationtypeReMapper
- the mapper to remap any '@type' variable to a new class- Returns:
- Object from the YAPIONObject to deserialize
-
parse
@Deprecated public java.lang.Object parse(YAPIONAnyType yapionAnyType, YAPIONDeserializer yapionDeserializer)
Deprecated.since 0.12.0 useparse(YAPIONAnyType)
instead- Parameters:
yapionAnyType
- to parseyapionDeserializer
- to parse with- Returns:
- the Object of the
YAPIONAnyType
inputted
-
parse
public java.lang.Object parse(YAPIONAnyType yapionAnyType)
- Parameters:
yapionAnyType
- to parse- Returns:
- the Object of the
YAPIONAnyType
inputted
-
getClass
public java.lang.Class<?> getClass(java.lang.String className)
-
parse
public YAPIONDeserializer parse()
Parses the YAPIONObject to the Object.
-
getObject
public java.lang.Object getObject()
Get the deserialized Object.- Returns:
- Object from the YAPIONObject to deserialize
-
getDeserializeResult
public DeserializeResult getDeserializeResult()
Get theDeserializeResult
.- Returns:
DeserializeResult
used by this instance
-
-