public final class

EnvelopedXmlObject

extends DataObjectDesc
java.lang.Object
   ↳ xades4j.properties.DataObjectDesc
     ↳ xades4j.production.EnvelopedXmlObject

Class Overview

Represents content (tipically XML) that will be enveloped in the signature. Each instance of this class will result in a ds:Object in the final XAdES signature, which will contain the data. Also, this Object will be covered by a ds:Reference so that it is actually included in the signature.

If one wants to add content other than XML, a text node can be used.

Summary

Public Constructors
EnvelopedXmlObject(Node content)
Creates a new instance with the given context.
EnvelopedXmlObject(Node content, String mimeType, String encoding)
Creates a new instance with the given content, mime type and encoding.
Public Methods
String getEncoding()
Gets the encoding of the content.
String getMimeType()
Gets the mime type of the content.
[Expand]
Inherited Methods
From class xades4j.properties.DataObjectDesc
From class java.lang.Object

Public Constructors

public EnvelopedXmlObject (Node content)

Creates a new instance with the given context.

Parameters
content the XML content
Throws
NullPointerException if content is null

public EnvelopedXmlObject (Node content, String mimeType, String encoding)

Creates a new instance with the given content, mime type and encoding.

Parameters
content the XML content
mimeType the mime type of the content (may be null)
encoding the encoding of the content (may be null)
Throws
NullPointerException if content is null

Public Methods

public String getEncoding ()

Gets the encoding of the content.

Returns
  • the enconding or null if not specified

public String getMimeType ()

Gets the mime type of the content.

Returns
  • the mime type or null if not specified