Package org.yaml.snakeyaml.events
Class ScalarEvent
java.lang.Object
org.yaml.snakeyaml.events.Event
org.yaml.snakeyaml.events.NodeEvent
org.yaml.snakeyaml.events.ScalarEvent
Marks a scalar value.
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionScalarEvent
(String anchor, String tag, ImplicitTuple implicit, String value, Mark startMark, Mark endMark, Character style) Deprecated.ScalarEvent
(String anchor, String tag, ImplicitTuple implicit, String value, Mark startMark, Mark endMark, DumperOptions.ScalarStyle style) -
Method Summary
Modifier and TypeMethodDescriptionprotected String
Generate human readable representation of the EventGet the type (kind) if this EventStyle of the scalar.getStyle()
Deprecated.use getScalarStyle() insteadgetTag()
Tag of this scalar.getValue()
String representation of the value.boolean
isPlain()
Methods inherited from class org.yaml.snakeyaml.events.Event
equals, getEndMark, getStartMark, hashCode, is, toString
-
Constructor Details
-
ScalarEvent
public ScalarEvent(String anchor, String tag, ImplicitTuple implicit, String value, Mark startMark, Mark endMark, DumperOptions.ScalarStyle style) -
ScalarEvent
@Deprecated public ScalarEvent(String anchor, String tag, ImplicitTuple implicit, String value, Mark startMark, Mark endMark, Character style) Deprecated.
-
-
Method Details
-
getTag
Tag of this scalar.- Returns:
- The tag of this scalar, or
null
if no explicit tag is available.
-
getScalarStyle
Style of the scalar.- null
- Flow Style - Plain
- '\''
- Flow Style - Single-Quoted
- '"'
- Flow Style - Double-Quoted
- '|'
- Block Style - Literal
- '>'
- Block Style - Folded
- Returns:
- Style of the scalar.
- See Also:
-
getStyle
Deprecated.use getScalarStyle() instead- Returns:
- char which is a value behind ScalarStyle
-
getValue
String representation of the value.Without quotes and escaping.
- Returns:
- Value as Unicode string.
-
getImplicit
-
getArguments
Description copied from class:Event
Generate human readable representation of the Event- Overrides:
getArguments
in classNodeEvent
- Returns:
- representation fore humans
- See Also:
-
getEventId
Description copied from class:Event
Get the type (kind) if this Event- Specified by:
getEventId
in classEvent
- Returns:
- the ID of this Event
-
isPlain
public boolean isPlain()
-