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
Implements
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
Meta
Gets the XMP meta. Optional.
[JsonProperty]
public XmpMeta Meta { get; set; }
Property Value
Packages
Gets array of Aspose.Imaging.Xmp.XmpPackage inside XMP.
public XmpPackage[] Packages { get; }
Property Value
PackagesCount
Gets amount of packages inside XMP structure.
public int PackagesCount { get; }
Property Value
TrailerPi
Gets the trailer processing instruction.
[JsonProperty]
public XmpTrailerPi TrailerPi { get; }
Property Value
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
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
Returns the XMP package for specified namespace URI.
Exceptions
namespaceUri
GetXmlValue()
Converts XMP value to the XML representation.
public string GetXmlValue()
Returns
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
An XML string that represents the current object.