Top Description Fields Constructors Methods
org.snakeyaml.engine.v2.common

public Class SpecVersion

extends Object
implements Serializable
Class Inheritance
All Implemented Interfaces
java.io.Serializable
Imports
java.io.Serializable

YAML Version indicator

Field Summary

Modifier and TypeField and Description
private final int
major

keep major

private final int
minor

keep minor

Constructor Summary

AccessConstructor and Description
public
SpecVersion(int
- major part ov version, must be 1
major
,
int
- minor part of version, may be 0 or 1
minor
)

Create

Method Summary

Modifier and TypeMethod and Description
public int

Returns:

1
getMajor
()

getter

public int

Returns:

0 or 1
getMinor
()

getter

public String

Returns:

text
getRepresentation
()

create readable text

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

majorback to summary
private final int major

keep major

minorback to summary
private final int minor

keep minor

Constructor Detail

SpecVersionback to summary
public SpecVersion(int major, int minor)

Create

Parameters
major:int

- major part ov version, must be 1

minor:int

- minor part of version, may be 0 or 1

Method Detail

getMajorback to summary
public int getMajor()

getter

Returns:int

1

getMinorback to summary
public int getMinor()

getter

Returns:int

0 or 1

getRepresentationback to summary
public String getRepresentation()

create readable text

Returns:String

text

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override