Reference

public class Reference extends ExtensionElementImpl

A Reference inside a Manifest

Author:cyng

Fields

ATTRIBUTE_HREF

static final String ATTRIBUTE_HREF

Name of the required href attribute in Reference specifying the URI of the payload.

ATTRIBUTE_LOCATION

static final String ATTRIBUTE_LOCATION

Name of the required Location attribute of the Schema element.

ATTRIBUTE_ROLE

static final String ATTRIBUTE_ROLE

Name of the optional role attribute in Reference specifying the URI of the payload.

ATTRIBUTE_TYPE

static final String ATTRIBUTE_TYPE

Name of the type attribute in Reference specifying the type of XLINK link.

ELEMENT_SCHEMA

static final String ELEMENT_SCHEMA

Name of the Schema element

HREF_PREFIX

public static final String HREF_PREFIX

The prefix of “href” attribute of this Reference.

REFERENCE

static final String REFERENCE

Reference element name

Constructors

Reference

Reference(SOAPEnvelope soapEnvelope, SOAPElement soapElement)

Parse the given SOAPElement to reconstruct a Reference object with SOAPEnvelope as the parent.

Parameters:
  • soapEnvelopeSOAPEnvelope object into which the Reference object is added.
  • soapElementSOAPElement object to be parsed to reconstruct the Reference object.
Throws:
  • SOAPException

Methods

addDescription

public void addDescription(String description)

Add element with default xml:lang

Parameters:
  • description – Description to be added to the Reference.
Throws:
  • SOAPException

addDescription

public void addDescription(String description, String lang)

Add element with specified xml:lang

Parameters:
Throws:
  • SOAPException

addSchema

public void addSchema(String location, String version)

Create a Schema object using the given location and version, and add it to the Reference object.

Parameters:
  • location – URI of the schema.
  • version – Version identifier of the schema.
Throws:
  • SOAPException

getDescriptionCount

public int getDescriptionCount()

Gets the number of Description elements in this Reference.

Returns:The number of Description elements.

getDescriptions

public Iterator getDescriptions()

Get the descriptions in the Reference element.

Returns:An iterator pointing to a list of descriptions of type Description.

getHref

public String getHref()

Get href attribute of the Reference element.

Returns:Href attribute.

getId

public String getId()

Get ID attribute of the Reference element.

Returns:ID attribute.

getRole

public String getRole()

getSchemas

public Iterator getSchemas()

Get the schemas in the Reference element.

Returns:An iterator pointing to a list of schemas of type Schema.

setHref

void setHref(String href)

setId

void setId(String id)

setRole

public void setRole(String role)