Search Results for

    Show / Hide Table of Contents

    Class SetSerializer<TSet, TMember>

    A generic set serializer.

    Inheritance
    object
    SimpleTypeSerializer<TSet>
    SetSerializer<TSet, TMember>
    Implements
    ITypeSerializer
    Inherited Members
    SimpleTypeSerializer<TSet>.DataType
    SimpleTypeSerializer<TSet>.WriteAsync(object, Stream, GraphBinaryWriter, CancellationToken)
    SimpleTypeSerializer<TSet>.WriteNullableValueAsync(object, Stream, GraphBinaryWriter, CancellationToken)
    SimpleTypeSerializer<TSet>.WriteNonNullableValueAsync(object, Stream, GraphBinaryWriter, CancellationToken)
    SimpleTypeSerializer<TSet>.ReadAsync(Stream, GraphBinaryReader, CancellationToken)
    SimpleTypeSerializer<TSet>.ReadNullableValueAsync(Stream, GraphBinaryReader, CancellationToken)
    SimpleTypeSerializer<TSet>.ReadNonNullableValueAsync(Stream, GraphBinaryReader, CancellationToken)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Gremlin.Net.Structure.IO.GraphBinary.Types
    Assembly: Gremlin.Net.dll
    Syntax
    public class SetSerializer<TSet, TMember> : SimpleTypeSerializer<TSet>, ITypeSerializer where TSet : ISet<TMember?>, new()
    Type Parameters
    Name Description
    TSet

    The type of the set to serialize.

    TMember

    The type of elements in the set.

    Constructors

    SetSerializer()

    Initializes a new instance of the SetSerializer<TSet, TMember> class.

    Declaration
    public SetSerializer()

    Methods

    ReadValueAsync(Stream, GraphBinaryReader, CancellationToken)

    Reads a non-nullable value according to the type format.

    Declaration
    protected override Task<TSet> ReadValueAsync(Stream stream, GraphBinaryReader reader, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    Stream stream

    The GraphBinary data to parse.

    GraphBinaryReader reader

    A GraphBinaryReader.

    CancellationToken cancellationToken

    The token to cancel the operation. The default value is None.

    Returns
    Type Description
    Task<TSet>

    The read value.

    Overrides
    SimpleTypeSerializer<TSet>.ReadValueAsync(Stream, GraphBinaryReader, CancellationToken)

    WriteValueAsync(TSet, Stream, GraphBinaryWriter, CancellationToken)

    Writes a non-nullable value into a stream.

    Declaration
    protected override Task WriteValueAsync(TSet value, Stream stream, GraphBinaryWriter writer, CancellationToken cancellationToken = default)
    Parameters
    Type Name Description
    TSet value

    The value to write.

    Stream stream

    The stream to write to.

    GraphBinaryWriter writer

    A GraphBinaryWriter.

    CancellationToken cancellationToken

    The token to cancel the operation. The default value is None.

    Returns
    Type Description
    Task

    A task that represents the asynchronous write operation.

    Overrides
    SimpleTypeSerializer<TSet>.WriteValueAsync(TSet, Stream, GraphBinaryWriter, CancellationToken)

    Implements

    ITypeSerializer
    In this article
    Back to top Copyright © 2018 The Apache Software Foundation