Table of Contents

Class VdfNode

Namespace
LlamaLogic.ValveDataFormat
Assembly
LlamaLogic.ValveDataFormat.dll

Represents a node in a VDF document

public class VdfNode : IEquatable<VdfNode>
Inheritance
VdfNode
Implements
Derived
Inherited Members

Properties

TrailingComment

Gets/sets the comment which will follow the VdfNode

public string? TrailingComment { get; set; }

Property Value

string

Methods

Deserialize(StreamReader)

Deserializes a list of VdfNode from a specified reader

public static IReadOnlyList<VdfNode> Deserialize(StreamReader reader)

Parameters

reader StreamReader

Returns

IReadOnlyList<VdfNode>

DeserializeAsync(StreamReader)

Deserializes a list of VdfNode from a specified reader asynchronously

public static Task<IReadOnlyList<VdfNode>> DeserializeAsync(StreamReader reader)

Parameters

reader StreamReader

Returns

Task<IReadOnlyList<VdfNode>>

Equals(VdfNode?)

Indicates whether the current object is equal to another object of the same type.

public virtual bool Equals(VdfNode? other)

Parameters

other VdfNode

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Determines whether the specified object is equal to the current object.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

GetHashCode()

Serves as the default hash function.

public override int GetHashCode()

Returns

int

A hash code for the current object.

Parse(string)

Parses a list of VdfNode from a specified string

public static IReadOnlyList<VdfNode> Parse(string s)

Parameters

s string

The string to parse

Returns

IReadOnlyList<VdfNode>

Serialize(StreamWriter)

Serializes this VdfNode to the specified writer

public void Serialize(StreamWriter writer)

Parameters

writer StreamWriter

SerializeAsync(StreamWriter)

Serializes this VdfNode to the specified writer asynchronously

public ValueTask SerializeAsync(StreamWriter writer)

Parameters

writer StreamWriter

Returns

ValueTask

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

TryParse(string?, out IReadOnlyList<VdfNode>)

Tries to parse a list of VdfNode from a specified string

public static bool TryParse(string? s, out IReadOnlyList<VdfNode> result)

Parameters

s string

The string to parse

result IReadOnlyList<VdfNode>

The list of VdfNode if s was successfully parsed

Returns

bool

true if s was successfully parsed; otherwise, false

Operators

operator ==(VdfNode?, VdfNode?)

public static bool operator ==(VdfNode? left, VdfNode? right)

Parameters

left VdfNode
right VdfNode

Returns

bool

operator !=(VdfNode?, VdfNode?)

public static bool operator !=(VdfNode? left, VdfNode? right)

Parameters

left VdfNode
right VdfNode

Returns

bool