Top Description Inners Fields Constructors Methods
org.yaml.snakeyaml.representer

pack-priv Class SafeRepresenter

extends BaseRepresenter
Class Inheritance
Known Direct Subclasses
org.yaml.snakeyaml.representer.Representer
Imports
java.math.BigInteger, java.nio.charset.StandardCharsets, java.util.ArrayList, .Arrays, .Calendar, .Date, .HashMap, .Iterator, .LinkedHashMap, .List, .Map, .Set, .TimeZone, .UUID, java.util.regex.Pattern, org.yaml.snakeyaml.DumperOptions, org.yaml.snakeyaml.error.YAMLException, org.yaml.snakeyaml.external.biz.base64Coder.Base64Coder, org.yaml.snakeyaml.nodes.Node, .Tag, org.yaml.snakeyaml.reader.StreamReader

Represent standard Java classes

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
protected class
protected class
protected class
protected class
protected class
protected class
protected class
protected class
protected class
protected class
protected class
SafeRepresenter.RepresentPrimitiveArray

Represents primitive arrays, such as short[] and float[], by converting them into equivalent List<short> and List<float> using the appropriate autoboxing type.

protected class
protected class
protected class

Field Summary

Modifier and TypeField and Description
protected Map<Class<? extends Object>, Tag>
private static final Pattern
protected DumperOptions.NonPrintableStyle
protected TimeZone
Inherited from org.yaml.snakeyaml.representer.BaseRepresenter:
defaultFlowStyledefaultScalarStylemultiRepresentersnullRepresenterobjectToRepresentrepresentedObjectsrepresenters

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Tag

Returns:

the previous tag associated with the Class
addClassTag
(Class<? extends Object>
Class which tag is changed
clazz
,
Tag
new tag to be used for every instance of the specified Class
tag
)

Define a tag for the Class to serialize.

protected Tag
getTag(Class<?> clazz, Tag defaultTag)

public TimeZone
public void
Inherited from org.yaml.snakeyaml.representer.BaseRepresenter:
getDefaultFlowStylegetDefaultScalarStylegetPropertyUtilsisExplicitPropertyUtilsrepresentrepresentDatarepresentMappingrepresentScalarrepresentScalarrepresentSequencesetDefaultFlowStylesetDefaultScalarStylesetPropertyUtils

Field Detail

classTagsback to summary
protected Map<Class<? extends Object>, Tag> classTags
MULTILINE_PATTERNback to summary
private static final Pattern MULTILINE_PATTERN
nonPrintableStyleback to summary
protected DumperOptions.NonPrintableStyle nonPrintableStyle
timeZoneback to summary
protected TimeZone timeZone

Constructor Detail

SafeRepresenterback to summary
public SafeRepresenter(DumperOptions options)

Method Detail

addClassTagback to summary
public Tag addClassTag(Class<? extends Object> clazz, Tag tag)

Define a tag for the Class to serialize.

Parameters
clazz:Class<? extends Object>

Class which tag is changed

tag:Tag

new tag to be used for every instance of the specified Class

Returns:Tag

the previous tag associated with the Class

getTagback to summary
protected Tag getTag(Class<?> clazz, Tag defaultTag)
getTimeZoneback to summary
public TimeZone getTimeZone()
setTimeZoneback to summary
public void setTimeZone(TimeZone timeZone)
org.yaml.snakeyaml.representer back to summary

private Class SafeRepresenter.IteratorWrapper

extends Object
implements Iterable<Object>
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.IteratorWrapper
All Implemented Interfaces
java.lang.Iterable

Field Summary

Modifier and TypeField and Description
private final Iterator<Object>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Iterator<Object>
iterator()

Implements java.lang.Iterable.iterator.

Returns an iterator over elements of type T.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

iterback to summary
private final Iterator<Object> iter

Constructor Detail

IteratorWrapperback to summary
public IteratorWrapper(Iterator<Object> iter)

Method Detail

iteratorback to summary
public Iterator<Object> iterator()

Implements java.lang.Iterable.iterator.

Doc from java.lang.Iterable.iterator.

Returns an iterator over elements of type T.

Returns:Iterator<Object>

an Iterator.

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentArray

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentArray
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentArrayback to summary
protected RepresentArray()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentBoolean

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentBoolean
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentBooleanback to summary
protected RepresentBoolean()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentByteArray

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentByteArray
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentByteArrayback to summary
protected RepresentByteArray()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentDate

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentDateback to summary
protected RepresentDate()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentEnum

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentEnumback to summary
protected RepresentEnum()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentIterator

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentIterator
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentIteratorback to summary
protected RepresentIterator()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

Annotations
@SuppressWarnings:unchecked
org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentList

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentListback to summary
protected RepresentList()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

Annotations
@SuppressWarnings:unchecked
org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentMap

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentMapback to summary
protected RepresentMap()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

Annotations
@SuppressWarnings:unchecked
org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentNull

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentNullback to summary
protected RepresentNull()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentNumber

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentNumber
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentNumberback to summary
protected RepresentNumber()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentPrimitiveArray

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentPrimitiveArray
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Represents primitive arrays, such as short[] and float[], by converting them into equivalent List and List using the appropriate autoboxing type.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
private List<Boolean>
private List<Byte>
private List<Character>
private List<Double>
private List<Float>
private List<Integer>
private List<Long>
private List<Short>
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentPrimitiveArrayback to summary
protected RepresentPrimitiveArray()

Method Detail

asBooleanListback to summary
private List<Boolean> asBooleanList(Object in)
asByteListback to summary
private List<Byte> asByteList(Object in)
asCharListback to summary
private List<Character> asCharList(Object in)
asDoubleListback to summary
private List<Double> asDoubleList(Object in)
asFloatListback to summary
private List<Float> asFloatList(Object in)
asIntListback to summary
private List<Integer> asIntList(Object in)
asLongListback to summary
private List<Long> asLongList(Object in)
asShortListback to summary
private List<Short> asShortList(Object in)
representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentSet

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentSetback to summary
protected RepresentSet()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

Annotations
@SuppressWarnings:unchecked
org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentString

extends Object
implements Represent
Class Inheritance
  • java.lang.Object
  • org.yaml.snakeyaml.representer.SafeRepresenter.RepresentString
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentStringback to summary
protected RepresentString()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump

org.yaml.snakeyaml.representer back to summary

protected Class SafeRepresenter.RepresentUuid

extends Object
implements Represent
Class Inheritance
All Implemented Interfaces
org.yaml.snakeyaml.representer.Represent

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public Node
representData(Object
the instance to represent
data
)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Create a Node
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

RepresentUuidback to summary
protected RepresentUuid()

Method Detail

representDataback to summary
public Node representData(Object data)

Implements org.yaml.snakeyaml.representer.Represent.representData.

Doc from org.yaml.snakeyaml.representer.Represent.representData.

Create a Node

Parameters
data:Object

the instance to represent

Returns:Node

Node to dump