Show / Hide Table of Contents

    Class XmlSerializerRepository

    A repository for managing XML serializers.

    Inheritance
    System.Object
    XmlSerializerRepository
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: DocuWare.Services.Http.Client
    Assembly: DocuWare.RestClient.dll
    Syntax
    public class XmlSerializerRepository

    Methods

    GetSerializer(Type)

    Gets the serializer.

    Declaration
    public XmlSerializer GetSerializer(Type type)
    Parameters
    Type Name Description
    System.Type type

    The type.

    Returns
    Type Description
    System.Xml.Serialization.XmlSerializer

    GetSerializer<T>()

    Gets the serializer.

    Declaration
    public XmlSerializer GetSerializer<T>()
    
        where T : class
    Returns
    Type Description
    System.Xml.Serialization.XmlSerializer
    Type Parameters
    Name Description
    T

    ParseFromXmlString<T>(Byte[])

    Parses from the specified compressed XML string.

    Declaration
    public static T ParseFromXmlString<T>(byte[] compressedXml)
    
        where T : class
    Parameters
    Type Name Description
    System.Byte[] compressedXml

    The gzip compressed XML.

    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    ParseFromXmlString<T>(String)

    Parses from the specified XML string.

    Declaration
    public static T ParseFromXmlString<T>(string xml)
    
        where T : class
    Parameters
    Type Name Description
    System.String xml

    The XML.

    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    ReadFromStream<T>(Stream)

    Reads from stream.

    Declaration
    public static T ReadFromStream<T>(Stream xml)
    
        where T : class
    Parameters
    Type Name Description
    System.IO.Stream xml

    The XML.

    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    ToCompressedXmlString<T>(T)

    Converts an object to an compressed XML string.

    Declaration
    public static byte[] ToCompressedXmlString<T>(T item)
    
        where T : class
    Parameters
    Type Name Description
    T item

    The object to convert.

    Returns
    Type Description
    System.Byte[]

    The array containing the compressed version of the XML string representing the presented item.

    Type Parameters
    Name Description
    T

    ToXmlString<T>(T, Boolean)

    Converts an object to an XML string.

    Declaration
    public static string ToXmlString<T>(T item, bool encodeWithUtf16 = false)
    
        where T : class
    Parameters
    Type Name Description
    T item

    The object to convert.

    System.Boolean encodeWithUtf16

    if set to true [encode with UTF16].

    Returns
    Type Description
    System.String
    Type Parameters
    Name Description
    T

    Write<T>(T, Stream)

    Serializes the specified item as XML to the target stream.

    Declaration
    public static void Write<T>(T item, Stream target)
    
        where T : class
    Parameters
    Type Name Description
    T item

    The item.

    System.IO.Stream target

    The target.

    Type Parameters
    Name Description
    T
    About Us Contact Imprint Terms Data privacy
    © 2024 DocuWare Corporation powered by DocFX Back to top