Class XmlSerializerRepository
- Namespace
- DocuWare.Services.Http.Client
- Assembly
- DocuWare.RestClient.dll
A repository for managing XML serializers.
public class XmlSerializerRepository
- Inheritance
-
XmlSerializerRepository
- Inherited Members
-
Methods
GetSerializer(Type)
public XmlSerializer GetSerializer(Type type)
Parameters
| Type | Name | Description |
| Type | type | The type.
|
Returns
GetSerializer<T>()
public XmlSerializer GetSerializer<T>()
where T : class
Returns
Type Parameters
ParseFromXmlString<T>(Byte[])
Parses from the specified compressed XML string.
public static T ParseFromXmlString<T>(byte[] compressedXml)
where T : class
Parameters
| Type | Name | Description |
| Byte[] | compressedXml | The gzip compressed XML.
|
Returns
Type Parameters
ParseFromXmlString<T>(String)
Parses from the specified XML string.
public static T ParseFromXmlString<T>(string xml)
where T : class
Parameters
| Type | Name | Description |
| String | xml | The XML.
|
Returns
Type Parameters
ReadFromStream<T>(Stream)
public static T ReadFromStream<T>(Stream xml)
where T : class
Parameters
| Type | Name | Description |
| Stream | xml | The XML.
|
Returns
Type Parameters
ToCompressedXmlString<T>(T)
Converts an object to an compressed XML string.
public static byte[] ToCompressedXmlString<T>(T item)
where T : class
Parameters
| Type | Name | Description |
| T | item | The object to convert.
|
Returns
| Type | Description |
| Byte[] | The array containing the compressed version of the XML string representing the presented item.
|
Type Parameters
ToXmlString<T>(T, Boolean)
Converts an object to an XML string.
public static string ToXmlString<T>(T item, bool encodeWithUtf16 = false)
where T : class
Parameters
| Type | Name | Description |
| T | item | The object to convert.
|
| Boolean | encodeWithUtf16 | if set to true [encode with UTF16].
|
Returns
Type Parameters
Write<T>(T, Stream)
Serializes the specified item as XML to the target stream.
public static void Write<T>(T item, Stream target)
where T : class
Parameters
| Type | Name | Description |
| T | item | The item.
|
| Stream | target | The target.
|
Type Parameters