Expect() Method

Definition

Namespace SharpYaml
Assembly SharpYaml.dll

Ensures that the current event is of the specified type, returns it and moves to the next event.

public T Expect<T>()
    where T : ParsingEvent

Type parameters

T
Type of the ParsingEvent.

Returns

{T}
Returns the current event.