| Modifier and Type | Field and Description |
|---|---|
| protected FlowStyle | defaultFlowStyle
flow style for collections |
| protected ScalarStyle | defaultScalarStyle
scalar style |
| protected RepresentToNode | nullRepresenter
in Java 'null' is not a type. |
| protected Object | objectToRepresent
the current object to be converted to Node |
| protected final Map | parentClassRepresenters
Keep representers which match a parent of the class to be represented |
| protected final Map | representedObjects
Keep references of already represented instances. |
| protected final Map | representers
Keep representers which must match the class exactly |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected Optional | Returns: RepresentToNode to call to create a Node- the data to be serialized data)Find the representer which is suitable to represent the internal structure of the provided instance to a Node |
| public Node | |
| protected final Node | Returns: Node for the provided source- the source data)Find the representer and use it to create the Node from instance |
| protected Node | Returns: Node for the source Map- the tag for Node tag, Map<?, ?> - the source mapping, FlowStyle - the style of Node flowStyle)Create Node for the provided Map |
| protected NodeTuple | Returns: the tuple where both key and value are converted to Node- Map entry entryCreate a tuple for one key pair |
| protected Node | Returns: Node to emit- the tag to emit tag, String - the value to emit value, ScalarStyle - scalar style when preferred style)Create scalar node for the provided string object. |
| protected Node | Returns: Node for string- the tag for Node tag, String - the surce value)Create Node for string using PLAIN scalar style if possible |
| protected Node | Returns: the Node from the source iterable- tag to use in Node tag, Iterable<?> - the source sequence, FlowStyle - the flow style flowStyle)Create Node |
| defaultFlowStyle | back to summary |
|---|---|
| protected FlowStyle defaultFlowStyle flow style for collections | |
| defaultScalarStyle | back to summary |
|---|---|
| protected ScalarStyle defaultScalarStyle scalar style | |
| nullRepresenter | back to summary |
|---|---|
| protected RepresentToNode nullRepresenter in Java 'null' is not a type. So we have to keep the null representer separately | |
| objectToRepresent | back to summary |
|---|---|
| protected Object objectToRepresent the current object to be converted to Node | |
| parentClassRepresenters | back to summary |
|---|---|
| protected final Map<Class<?>, RepresentToNode> parentClassRepresenters Keep representers which match a parent of the class to be represented | |
| representedObjects | back to summary |
|---|---|
| protected final Map<Object, Node> representedObjects Keep references of already represented instances. The order is important (map can be also a sequence of key-values) | |
| representers | back to summary |
|---|---|
| protected final Map<Class<?>, RepresentToNode> representers Keep representers which must match the class exactly | |
| BaseRepresenter | back to summary |
|---|---|
| public BaseRepresenter() | |
| findRepresenterFor | back to summary |
|---|---|
| protected Optional Find the representer which is suitable to represent the internal structure of the provided instance to a Node
| |
| represent | back to summary |
|---|---|
| public Node represent(Object data) Represent the provided Java instance to a Node | |
| representData | back to summary |
|---|---|
| protected final Node representData(Object data) Find the representer and use it to create the Node from instance | |
| representMapping | back to summary |
|---|---|
| protected Node representMapping(Tag tag, Map<?, ?> mapping, FlowStyle flowStyle) Create Node for the provided Map | |
| representMappingEntry | back to summary |
|---|---|
| protected NodeTuple representMappingEntry(Map. Create a tuple for one key pair | |
| representScalar | back to summary |
|---|---|
| protected Node representScalar(Tag tag, String value, ScalarStyle style) Create scalar node for the provided string object.
| |
| representScalar | back to summary |
|---|---|
| protected Node representScalar(Tag tag, String value) Create Node for string using PLAIN scalar style if possible | |
| representSequence | back to summary |
|---|---|
| protected Node representSequence(Tag tag, Iterable<?> sequence, FlowStyle flowStyle) Create Node | |