Class XmpPacketWrapper

Class XmpPacketWrapper

Namespace: Aspose.Imaging.Xmp
Assembly: Aspose.Imaging.dll (25.2.0)

Contains serialized xmp package including header and trailer.

[JsonObject(MemberSerialization.OptIn)]
public class XmpPacketWrapper : IXmlValue

Inheritance

objectXmpPacketWrapper

Implements

IXmlValue

Inherited Members

object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Remarks

A wrapper consisting of a pair of XML processing instructions (PIs) may be placed around the rdf:RDF element.

Constructors

XmpPacketWrapper(XmpHeaderPi, XmpTrailerPi, XmpMeta)

Initializes a new instance of the Aspose.Imaging.Xmp.XmpPacketWrapper class.

public XmpPacketWrapper(XmpHeaderPi header, XmpTrailerPi trailer, XmpMeta xmpMeta)

Parameters

header XmpHeaderPi

The XMP header of processing instruction.

trailer XmpTrailerPi

The XMP trailer of processing instruction.

xmpMeta XmpMeta

The XMP metadata.

XmpPacketWrapper()

Initializes a new instance of the Aspose.Imaging.Xmp.XmpPacketWrapper class.

public XmpPacketWrapper()

Properties

HeaderPi

Gets the header processing instruction.

[JsonProperty]
public XmpHeaderPi HeaderPi { get; }

Property Value

XmpHeaderPi

Meta

Gets the XMP meta. Optional.

[JsonProperty]
public XmpMeta Meta { get; set; }

Property Value

XmpMeta

Packages

Gets array of Aspose.Imaging.Xmp.XmpPackage inside XMP.

public XmpPackage[] Packages { get; }

Property Value

XmpPackage[]

PackagesCount

Gets amount of packages inside XMP structure.

public int PackagesCount { get; }

Property Value

int

TrailerPi

Gets the trailer processing instruction.

[JsonProperty]
public XmpTrailerPi TrailerPi { get; }

Property Value

XmpTrailerPi

Methods

AddPackage(XmpPackage)

Adds the package.

public void AddPackage(XmpPackage package)

Parameters

package XmpPackage

The package.

ClearPackages()

Removes all Aspose.Imaging.Xmp.XmpPackage inside XMP.

public void ClearPackages()

ContainsPackage(string)

Determines whethere package is exist in xmp wrapper.

public bool ContainsPackage(string namespaceUri)

Parameters

namespaceUri string

Package schema uri.

Returns

bool

Returns true if package with specified namespace Uri exist in XMP wrapper.

GetPackage(string)

Gets package by namespace URI.

public XmpPackage GetPackage(string namespaceUri)

Parameters

namespaceUri string

The package schema URI.

Returns

XmpPackage

Returns the XMP package for specified namespace URI.

Exceptions

ArgumentNullException

namespaceUri

GetXmlValue()

Converts XMP value to the XML representation.

public string GetXmlValue()

Returns

string

Returns converted XMP value to XML.

RemovePackage(XmpPackage)

Removes the XMP package.

public void RemovePackage(XmpPackage package)

Parameters

package XmpPackage

The package.

ToString()

Returns an XML string that represents the current object.

public override string ToString()

Returns

string

An XML string that represents the current object.