C# Class YamlDotNet.RepresentationModel.YamlNode

Represents a single node in the YAML document.
ファイルを表示 Open project: aaubry/YamlDotNet Class Usage Examples

Public Methods

Method Description
Accept ( IYamlVisitor visitor ) : void

Accepts the specified visitor by calling the appropriate Visit method on it.

GetHashCode ( ) : int

Serves as a hash function for a particular type.

ToString ( ) : string
this ( YamlNode key ) : YamlNode

Gets the value associated with a key in a YamlMappingNode.

this ( int index ) : YamlNode

Gets the nth element in a YamlSequenceNode.

Protected Methods

Method Description
CombineHashCodes ( int h1, int h2 ) : int

Combines two hash codes into one.

Equals ( YamlNode other ) : bool

Provides a basic implementation of Object.Equals

GetHashCode ( object value ) : int

Gets the hash code of the specified object, or zero if the object is null.

SafeEquals ( object first, object second ) : bool

Gets a value indicating whether two objects are equal.

Private Methods

Method Description
Emit ( IEmitter emitter, EmitterState state ) : void

Saves the current node to the specified emitter.

Load ( NodeEvent yamlEvent, DocumentLoadingState state ) : void

Loads the specified event.

ParseNode ( IParser parser, DocumentLoadingState state ) : YamlNode

Parses the node represented by the next event in parser.

ResolveAliases ( DocumentLoadingState state ) : void

Resolves the aliases that could not be resolved when the node was created.

SafeAllNodes ( RecursionLevel level ) : IEnumerable

When implemented, recursively enumerates all the nodes from the document, starting on the current node. If RecursionLevel.Maximum is reached, a MaximumRecursionLevelReachedException is thrown instead of continuing and crashing with a StackOverflowException.

Save ( IEmitter emitter, EmitterState state ) : void

Saves the current node to the specified emitter.

ToString ( RecursionLevel level ) : string

Method Details

Accept() public abstract method

Accepts the specified visitor by calling the appropriate Visit method on it.
public abstract Accept ( IYamlVisitor visitor ) : void
visitor IYamlVisitor /// A . ///
return void

CombineHashCodes() protected static method

Combines two hash codes into one.
protected static CombineHashCodes ( int h1, int h2 ) : int
h1 int
h2 int
return int

Equals() protected method

Provides a basic implementation of Object.Equals
protected Equals ( YamlNode other ) : bool
other YamlNode
return bool

GetHashCode() public method

Serves as a hash function for a particular type.
public GetHashCode ( ) : int
return int

GetHashCode() protected static method

Gets the hash code of the specified object, or zero if the object is null.
protected static GetHashCode ( object value ) : int
value object
return int

SafeEquals() protected static method

Gets a value indicating whether two objects are equal.
protected static SafeEquals ( object first, object second ) : bool
first object
second object
return bool

ToString() public method

public ToString ( ) : string
return string

this() public method

Gets the value associated with a key in a YamlMappingNode.
public this ( YamlNode key ) : YamlNode
key YamlNode
return YamlNode

this() public method

Gets the nth element in a YamlSequenceNode.
public this ( int index ) : YamlNode
index int
return YamlNode