API

API reference

Every public type of the Styml package, by namespace, with its members and its documentation.

The public types of the Styml package, generated from its XML documentation. Most of the documentation comes from System.Text.Json, renamed for YAML; the guide shows the types at work.

System.Runtime.InteropServicesLink to this heading

Type Kind Description
YamlMarshal class An unsafe class that provides a set of methods to access the underlying data representations of YAML types.

System.Text.YamlLink to this heading

Type Kind Description
Utf8YamlReader struct Provides a high-performance API for forward-only, read-only access to the UTF-8 encoded YAML text. It processes the text sequentially with no caching and adheres strictly to the YAML 1.2 specification by default (https://tools.ietf.org/html/rfc8259). When it encounters invalid YAML, it throws a YamlException with basic error information like line number and byte position on the line. Since this type is a ref struct, it does not directly support async. However, it does provide support for reentrancy to read incomplete data, and continue reading once more data is presented. To be able to set max depth while reading OR allow skipping comments, create an instance of YamlReaderState and pass that in to the reader.
Utf8YamlWriter class Provides a high-performance API for forward-only, non-cached writing of UTF-8 encoded YAML text.
YamlCollectionStyle enum The style Utf8YamlWriter.WriteCollectionStyle requests for the next collection a block-style writer starts.
YamlCommentHandling enum This enum defines the various ways the Utf8YamlReader can deal with comments.
YamlDocument class Represents the structure of a YAML value in a lightweight, read-only form.
YamlDocumentOptions struct Provides the ability for the user to define custom behavior when parsing YAML to create a YamlDocument.
YamlDuplicateKeyHandling enum What reading does with a mapping key that appears twice (M5c). Keys are compared as their consumer holds them: by decoded text in a YamlDocument, a node, an Object or a string-keyed dictionary; by the converted key in a typed dictionary; and by the member they match in a typed object. A repeated key that no member maps, or one inside a value that is skipped, is not judged.
YamlElement struct Represents a specific YAML value within a YamlDocument.
YamlElement.ArrayEnumerator struct An enumerable and enumerator for the contents of a YAML array.
YamlElement.ObjectEnumerator struct An enumerable and enumerator for the properties of a YAML object.
YamlEncodedText struct Provides a way to transform UTF-8 or UTF-16 encoded text into a form that is suitable for YAML.
YamlException class Defines a custom exception object that is thrown when invalid YAML text is encountered, when the defined maximum depth is passed, or the YAML text is not compatible with the type of a property on an object.
YamlKeyKind enum What the current YamlTokenType.PropertyName token of a Utf8YamlReader stands for.
YamlNamingPolicy class Determines the naming policy used to convert a string-based name to another format, such as a camel-casing format.
YamlProperty struct Represents a single property for a YAML object.
YamlReaderOptions struct Provides the ability for the user to define custom behavior when reading YAML.
YamlReaderState struct Defines an opaque type that holds and saves all the relevant state information which must be provided to the Utf8YamlReader to continue reading after processing incomplete data. This type is required to support reentrancy when reading incomplete data, and to continue reading once more data is available. Unlike the Utf8YamlReader, which is a ref struct, this type can survive across async/await boundaries and hence this type is required to provide support for reading in more data asynchronously before continuing with a new instance of the Utf8YamlReader.
YamlScalarStyle enum The presentation style of the scalar (or mapping key) that produced the current Utf8YamlReader token.
YamlSchemaKind enum The schema that gives plain scalars in value position their type. Keys, quoted and block scalars, and tagged nodes are not affected.
YamlSerializer class Provides functionality to serialize objects or value types to YAML and deserialize YAML into objects or value types.
YamlSerializerDefaults enum Signifies what default options are used by YamlSerializerOptions.
YamlSerializerOptions class Provides options to be used with YamlSerializer.
YamlTokenType enum This enum defines the various YAML tokens that make up a YAML text and is used by the Utf8YamlReader when moving from one token to the next. The Utf8YamlReader starts at 'None' by default. The 'Comment' enum value is only ever reached in a specific Utf8YamlReader mode and is not reachable by default.
YamlValueKind enum Specifies the data type of a YAML value.
YamlWriterOptions struct Provides the ability for the user to define custom behavior when writing YAML using the Utf8YamlWriter. By default, the YAML is written without any indentation or extra white space. Also, the Utf8YamlWriter will throw an exception if the user attempts to write structurally invalid YAML.
YamlWriterStyle enum The output style of Utf8YamlWriter.

System.Text.Yaml.NodesLink to this heading

Type Kind Description
YamlArray class Represents a mutable YAML array.
YamlNode class The base class that represents a single node within a mutable YAML document.
YamlNodeOptions struct Options to control YamlNode behavior.
YamlObject class Represents a mutable YAML object.
YamlValue class Represents a mutable YAML value.

System.Text.Yaml.SchemaLink to this heading

Type Kind Description
YamlSchemaExporter class Functionality for exporting JSON schema from serialization contracts defined in YamlTypeInfo.
YamlSchemaExporterContext struct Defines the context for the generated JSON schema for a particular node in a type graph.
YamlSchemaExporterOptions class Configures the behavior of the YamlSchemaExporter APIs.

System.Text.Yaml.SerializationLink to this heading

Type Kind Description
IYamlOnDeserialized interface Specifies that the YAML type should have its IYamlOnDeserialized.OnDeserialized method called after deserialization occurs.
IYamlOnDeserializing interface Specifies that the type should have its IYamlOnDeserializing.OnDeserializing method called before deserialization occurs.
IYamlOnSerialized interface Specifies that the type should have its IYamlOnSerialized.OnSerialized method called after serialization occurs.
IYamlOnSerializing interface Specifies that the type should have its IYamlOnSerializing.OnSerializing method called before serialization occurs.
ReferenceHandler class This class defines how the YamlSerializer deals with references on serialization and deserialization.
ReferenceHandler<T> class This class defines how the YamlSerializer deals with references on serialization and deserialization.
ReferenceResolver class This class defines how the YamlSerializer deals with references on serialization and deserialization. Defines the core behavior of preserving references on serialization and deserialization.
YamlAttribute class The base class of serialization attributes.
YamlCommentAttribute class Writes a comment above the member in block style, one # line per line of YamlCommentAttribute.Comment, as YamlDotNet's [YamlMember(Description = …)]. The comment is written for a null member too, and not for a member left out by an ignore condition; it is dropped in JSON-compatible style, and comments are skipped when reading.
YamlConstructorAttribute class When placed on a constructor, indicates that the constructor should be used to create instances of the type on deserialization.
YamlConverter class Converts an object or value to or from YAML.
YamlConverter<T> class Converts an object or value to or from YAML.
YamlConverterAttribute class When placed on a property, field, or type, specifies the converter type to use.
YamlConverterFactory class Supports converting several types by using a factory pattern.
YamlDerivedTypeAttribute class When placed on a type declaration, indicates that the specified subtype should be opted into polymorphic serialization.
YamlExtensionDataAttribute class When placed on a property or field of type YamlObject, IDictionary<T, T2>, or IReadOnlyDictionary<T, T2>, any properties that do not have a matching property or field are added during deserialization and written during serialization.
YamlIgnoreAttribute class Prevents a property or field from being serialized or deserialized. When placed on a type, specifies the default YamlIgnoreCondition for all properties and fields of the type.
YamlIgnoreCondition enum When specified on YamlSerializerOptions.DefaultIgnoreCondition, determines when properties and fields across the type graph are ignored. When specified on YamlIgnoreAttribute.Condition, controls whether a property or field is ignored during serialization and deserialization. This option overrides the setting on YamlSerializerOptions.DefaultIgnoreCondition.
YamlIncludeAttribute class Indicates that the property or field should be included for serialization and deserialization.
YamlKnownNamingPolicy enum The YamlNamingPolicy to be used at run time.
YamlKnownReferenceHandler enum The ReferenceHandler to be used at run time.
YamlMappingOrder enum The order in which the serializer writes an object's members (YamlSerializerOptions.MappingOrder), as SharpYaml's MappingOrder.
YamlNamingPolicyAttribute class When placed on a type, property, or field, indicates what YamlNamingPolicy should be used to convert property names.
YamlNumberEnumConverter<TEnum> class Converter to convert enums to and from numeric values.
YamlNumberHandling enum Determines how YamlSerializer handles numbers when serializing and deserializing. The behavior of YamlNumberHandling.WriteAsString and YamlNumberHandling.AllowNamedFloatingPointLiterals is not defined by the YAML specification. Altering the default number handling can potentially produce YAML that cannot be parsed by other YAML implementations.
YamlNumberHandlingAttribute class When placed on a type, property, or field, indicates what YamlNumberHandling settings should be used when serializing or deserializing numbers.
YamlObjectCreationHandling enum Determines how deserialization will handle object creation for fields or properties.
YamlObjectCreationHandlingAttribute class Determines how deserialization will handle object creation for fields or properties.
YamlPolymorphicAttribute class When placed on a type, indicates that the type should be serialized polymorphically.
YamlPropertyNameAttribute class Specifies the property name that is present in the YAML when serializing and deserializing. This overrides any naming policy specified by YamlNamingPolicy.
YamlPropertyOrderAttribute class Specifies the property order that is present in the YAML when serializing. Lower values are serialized first. If the attribute is not specified, the default value is 0.
YamlRequiredAttribute class Indicates that the annotated member must bind to a YAML property on deserialization.
YamlScalarStyleAttribute class The scalar style in which the member's string value is written in block style, as YamlDotNet's [YamlMember(ScalarStyle = …)].
YamlSerializableAttribute class Instructs the System.Text.Yaml source generator to generate source code to help optimize performance when serializing and deserializing instances of the specified type and types in its object graph.
YamlSerializerContext class Provides metadata about a set of types that is relevant to YAML serialization.
YamlSourceGenerationMode enum The generation mode for the System.Text.Yaml source generator.
YamlSourceGenerationOptionsAttribute class Specifies compile-time source generator configuration when applied to YamlSerializerContext class declarations.
YamlStringEnumConverter class Converter to convert enums to and from strings.
YamlStringEnumConverter<TEnum> class Converter to convert enums to and from strings.
YamlStringEnumMemberNameAttribute class Determines the string value that should be used when serializing an enum member.
YamlTagMappingAttribute class Adds an entry to the source-generated options' YamlSerializerOptions.TagMappings: the YAML tag given first reads and writes the type given second, which the context then also generates.
YamlTypeClassifier delegate A delegate that classifies a YAML payload to determine the concrete type it corresponds to. Used by both union types and polymorphic types with custom type classifiers.
YamlTypeClassifierContext class Provides immutable metadata to a YamlTypeClassifierFactory when creating a YamlTypeClassifier delegate.
YamlTypeClassifierFactory class When implemented in a derived class, creates a YamlTypeClassifier delegate that classifies YAML payloads to determine the target type.
YamlTypeClassifierFactory<T> class Convenience base class for a YamlTypeClassifierFactory that produces type classifiers for a single declaring type T.
YamlTypeClassifierKind enum Identifies the type of metadata being configured for a YamlTypeClassifierFactory.
YamlTypeDiscriminatorStyle enum How a polymorphic type writes which derived type a value is (M5d). Reading accepts the $type property under every style, and a tag under YamlTypeDiscriminatorStyle.Tag and YamlTypeDiscriminatorStyle.Both.
YamlUnionAttribute class Customizes the System.Text.Yaml behavior of a union type.
YamlUnionTypeStructuralClassifier class Classifies YAML payloads into union case types by comparing their YAML value types and, for YAML objects, their property names.
YamlUnknownDerivedTypeHandling enum Defines how objects of a derived runtime type that has not been explicitly declared for polymorphic serialization should be handled.
YamlUnknownTypeHandling enum Defines how deserializing a type declared as an Object is handled during deserialization.
YamlUnmappedMemberHandling enum Determines how YamlSerializer handles YAML properties that cannot be mapped to a specific .NET member when deserializing object types.
YamlUnmappedMemberHandlingAttribute class When placed on a type, determines the YamlUnmappedMemberHandling configuration for the specific type, overriding the global YamlSerializerOptions.UnmappedMemberHandling setting.

System.Text.Yaml.Serialization.MetadataLink to this heading

Type Kind Description
DefaultYamlTypeInfoResolver class Defines the default, reflection-based YAML contract resolver used by System.Text.Yaml.
IYamlTypeInfoResolver interface Used to resolve the YAML serialization contract for requested types.
YamlDerivedType struct Represents a supported derived type defined in the metadata of a polymorphic type.
YamlParameterInfo class Provides YAML serialization-related metadata about a constructor parameter.
YamlPolymorphismOptions class Defines polymorphic configuration for a specified base type.
YamlPropertyInfo class Provides YAML serialization-related metadata about a property or field defined in an object.
YamlTypeInfo class Provides YAML serialization-related metadata about a type.
YamlTypeInfo<T> class Provides YAML serialization-related metadata about a type.
YamlTypeInfoKind enum Determines the kind of contract metadata a given YamlTypeInfo is specifying.
YamlTypeInfoResolver class Contains utilities and combinators acting on IYamlTypeInfoResolver.
YamlUnionCaseInfo class Represents metadata for a single case type within a union type.

Generated from the XML documentation of the libraryBuilt with Douze

Esc to close