Class SerializeOptions
public sealed class SerializeOptions : Options
- Inheritance
-
SerializeOptions
- Inherited Members
Constructors
SerializeOptions()
Default constructor.
public SerializeOptions()
SerializeOptions(int)
Constructor using inital options
public SerializeOptions(int options)
Parameters
options
intthe inital options
Fields
ENCODE_UTF16BE
UTF16BE encoding
public const int ENCODE_UTF16BE = 2
Field Value
ENCODE_UTF16LE
UTF16LE encoding
public const int ENCODE_UTF16LE = 3
Field Value
ENCODE_UTF8
UTF8 encoding; this is the default
public const int ENCODE_UTF8 = 0
Field Value
EXACT_PACKET_LENGTH
The padding parameter provides the overall packet length.
public const int EXACT_PACKET_LENGTH = 512
Field Value
Remarks
The padding parameter provides the overall packet length. The actual amount of padding is computed. An exception is thrown if the packet exceeds this length with no padding.
INCLUDE_THUMBNAIL_PAD
Include a padding allowance for a thumbnail image.
public const int INCLUDE_THUMBNAIL_PAD = 256
Field Value
Remarks
Include a padding allowance for a thumbnail image. If no xmp:Thumbnails property is present, the typical space for a JPEG thumbnail is used.
OMIT_PACKET_WRAPPER
Omit the XML packet wrapper.
public const int OMIT_PACKET_WRAPPER = 16
Field Value
OMIT_XMPMETA_ELEMENT
Omit the <x:xmpmeta>-tag
public const int OMIT_XMPMETA_ELEMENT = 4096
Field Value
READONLY_PACKET
Mark packet as read-only.
public const int READONLY_PACKET = 32
Field Value
Remarks
Mark packet as read-only. Default is a writeable packet.
SORT
Sort the struct properties and qualifier before serializing
public const int SORT = 8192
Field Value
USE_CANONICAL_FORMAT
Use the canonical form of RDF if set.
public const int USE_CANONICAL_FORMAT = 128
Field Value
Remarks
Use the canonical form of RDF if set. By default the compact form is used
USE_COMPACT_FORMAT
Use a compact form of RDF.
public const int USE_COMPACT_FORMAT = 64
Field Value
Remarks
Use a compact form of RDF. The compact form is the default serialization format (this flag is technically ignored). To serialize to the canonical form, set the flag USE_CANONICAL_FORMAT. If both flags "compact" and "canonical" are set, canonical is used.
Methods
Clone()
public object Clone()
Returns
- object
Returns clone of this SerializeOptions-object with the same options set.
DefineOptionName(int)
protected override string DefineOptionName(int option)
Parameters
option
int
Returns
- See Also
GetBaseIndent()
public int GetBaseIndent()
Returns
- int
Returns the baseIndent.
GetEncodeUTF16BE()
public bool GetEncodeUTF16BE()
Returns
- bool
Returns the option.
GetEncodeUTF16LE()
public bool GetEncodeUTF16LE()
Returns
- bool
Returns the option.
GetEncoding()
public string GetEncoding()
Returns
- string
Returns the encoding as Java encoding String.
GetExactPacketLength()
public bool GetExactPacketLength()
Returns
- bool
Returns the option.
GetIncludeThumbnailPad()
public bool GetIncludeThumbnailPad()
Returns
- bool
Returns the option.
GetIndent()
public string GetIndent()
Returns
- string
Returns the indent.
GetNewline()
public string GetNewline()
Returns
- string
Returns the newline.
GetOmitPacketWrapper()
public bool GetOmitPacketWrapper()
Returns
- bool
Returns the option.
GetOmitVersionAttribute()
public bool GetOmitVersionAttribute()
Returns
- bool
Returns whether the Toolkit version attribute shall be omitted. Note: This options can only be set by unit tests.
GetOmitXmpMetaElement()
public bool GetOmitXmpMetaElement()
Returns
- bool
Returns the option.
GetPadding()
public int GetPadding()
Returns
- int
Returns the padding.
GetReadOnlyPacket()
public bool GetReadOnlyPacket()
Returns
- bool
Returns the option.
GetSort()
public bool GetSort()
Returns
- bool
Returns the option.
GetUseCanonicalFormat()
public bool GetUseCanonicalFormat()
Returns
- bool
Returns the option.
GetUseCompactFormat()
public bool GetUseCompactFormat()
Returns
- bool
Returns the option.
GetValidOptions()
protected override int GetValidOptions()
Returns
- See Also
SetBaseIndent(int)
public SerializeOptions SetBaseIndent(int baseIndent)
Parameters
baseIndent
intThe baseIndent to set.
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetEncodeUTF16BE(bool)
public SerializeOptions SetEncodeUTF16BE(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetEncodeUTF16LE(bool)
public SerializeOptions SetEncodeUTF16LE(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetExactPacketLength(bool)
public SerializeOptions SetExactPacketLength(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetIncludeThumbnailPad(bool)
public SerializeOptions SetIncludeThumbnailPad(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetIndent(string)
public SerializeOptions SetIndent(string indent)
Parameters
indent
stringThe indent to set.
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetNewline(string)
public SerializeOptions SetNewline(string newline)
Parameters
newline
stringThe newline to set.
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetOmitPacketWrapper(bool)
public SerializeOptions SetOmitPacketWrapper(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetOmitXmpMetaElement(bool)
public SerializeOptions SetOmitXmpMetaElement(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetPadding(int)
public SerializeOptions SetPadding(int padding)
Parameters
padding
intThe padding to set.
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetReadOnlyPacket(bool)
public SerializeOptions SetReadOnlyPacket(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetSort(bool)
public SerializeOptions SetSort(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetUseCanonicalFormat(bool)
public SerializeOptions SetUseCanonicalFormat(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.
SetUseCompactFormat(bool)
public SerializeOptions SetUseCompactFormat(bool value)
Parameters
value
boolthe value to set
Returns
- SerializeOptions
Returns the instance to call more set-methods.