|
SMILA (incubation) API documentation | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.eclipse.smila.datamodel.id.dom.IdBuilder
public class IdBuilder
A utility class to create DOM representations of SMILA record Ids.
| Field Summary | |
|---|---|
static java.lang.String |
ATTRIBUTE_NAME
attribute name of key name attribtue: "name". |
static java.lang.String |
ATTRIBUTE_VERSION
attribute name of key name attribtue: "verson". |
static java.lang.String |
ATTRIBUTE_XMLNSID
attribute "xmlns:id" for specification if SMILA Id XML namespace URI. |
static java.lang.String |
NAMESPACE_ID
SMILA Id XML namespace URI, "http://www.eclipse.org/smila/id". |
static java.lang.String |
PREFIX_ID
namespace prefix "id:" for Id XML elements. |
static java.lang.String |
SCHEMA_VERSION_ID
version of Id XMLs created by this builder: "1.0". |
static java.lang.String |
TAG_ELEMENT
qualified tag name of container element elements: "id:Element". |
static java.lang.String |
TAG_FRAGMENT
qualified tag name of fragment elements: "id:Fragment". |
static java.lang.String |
TAG_ID
qualified tag name of Id elements: "id:Id". |
static java.lang.String |
TAG_IDLIST
qualified tag name of Id list elements: "id:IdList". |
static java.lang.String |
TAG_KEY
qualified tag name of key elements: "id:Key". |
static java.lang.String |
TAG_SOURCE
qualified tag name of source elements: "id:Source". |
| Constructor Summary | |
|---|---|
IdBuilder()
create new IdBuilder. |
|
IdBuilder(boolean printPretty)
create new IdBuilder with custom printPretty flag. |
|
| Method Summary | |
|---|---|
org.w3c.dom.Element |
appendId(org.w3c.dom.Document document,
Id id)
Append id. |
org.w3c.dom.Element |
appendId(org.w3c.dom.Element element,
Id id)
add an Id element for the given element as the final child. |
org.w3c.dom.Element |
appendIdList(org.w3c.dom.Element element,
Id[] idList)
add an IdList element containing Id elements for the Ids in the given list to the given element as the final child. |
org.w3c.dom.Element |
appendIdList(org.w3c.dom.Element element,
java.lang.Iterable<Id> idList)
add an IdList element containing Id elements for the Ids in the given list to the given element as the final child. |
java.lang.String |
idToString(Id id)
Creates an xml string representation of the given id. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String NAMESPACE_ID
public static final java.lang.String ATTRIBUTE_XMLNSID
public static final java.lang.String PREFIX_ID
public static final java.lang.String TAG_ID
public static final java.lang.String TAG_IDLIST
public static final java.lang.String TAG_SOURCE
public static final java.lang.String TAG_KEY
public static final java.lang.String TAG_ELEMENT
public static final java.lang.String TAG_FRAGMENT
public static final java.lang.String ATTRIBUTE_VERSION
public static final java.lang.String ATTRIBUTE_NAME
public static final java.lang.String SCHEMA_VERSION_ID
| Constructor Detail |
|---|
public IdBuilder()
public IdBuilder(boolean printPretty)
printPretty - printPretty flag| Method Detail |
|---|
public org.w3c.dom.Element appendId(org.w3c.dom.Element element,
Id id)
element - DOM element to add the Id toid - The record Id to add.
public org.w3c.dom.Element appendId(org.w3c.dom.Document document,
Id id)
id - the iddocument - the document
public org.w3c.dom.Element appendIdList(org.w3c.dom.Element element,
java.lang.Iterable<Id> idList)
element - DOM element to add the Id list toidList - The record Ids to add.
public org.w3c.dom.Element appendIdList(org.w3c.dom.Element element,
Id[] idList)
element - DOM element to add the Id list toidList - The record Ids to add.
public java.lang.String idToString(Id id)
throws javax.xml.parsers.ParserConfigurationException,
java.io.IOException
id - the Id
javax.xml.parsers.ParserConfigurationException - if any error occurs
java.io.IOException - if any error occurs
|
SMILA (incubation) API documentation | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||