org.xmlcml.cml
Class StringArrayImpl

java.lang.Object
  |
  +--org.apache.xerces.dom.NodeImpl
        |
        +--org.apache.xerces.dom.ChildNode
              |
              +--org.apache.xerces.dom.ChildAndParentNode
                    |
                    +--org.apache.xerces.dom.ElementImpl
                          |
                          +--uk.co.demon.ursus.dom.AbstractElementImpl
                                |
                                +--uk.co.demon.ursus.dom.PMRElementImpl
                                      |
                                      +--org.xmlcml.cml.CMLBaseImpl
                                            |
                                            +--org.xmlcml.cml.AbstractStringValImpl
                                                  |
                                                  +--org.xmlcml.cml.StringValImpl
                                                        |
                                                        +--org.xmlcml.cml.StringArrayImpl

public class StringArrayImpl
extends StringValImpl
implements StringArray

See Also:
Serialized Form

Field Summary
protected  java.lang.String delimiter
           
protected  java.util.Vector stringVector
           
 
Fields inherited from class org.xmlcml.cml.AbstractStringValImpl
builtin, dataType, stringValue
 
Fields inherited from class org.xmlcml.cml.CMLBaseImpl
conventionName, conventionTable, dictRef, id, title, validity
 
Fields inherited from class uk.co.demon.ursus.dom.PMRElementImpl
CLASSNAME, processFlag
 
Fields inherited from class uk.co.demon.ursus.dom.AbstractElementImpl
CLASSNAME
 
Fields inherited from class org.apache.xerces.dom.ElementImpl
attributes, name
 
Fields inherited from class org.apache.xerces.dom.ChildAndParentNode
changes, firstChild, nodeListIndex, nodeListLength, nodeListNode, ownerDocument
 
Fields inherited from class org.apache.xerces.dom.ChildNode
nextSibling, previousSibling
 
Fields inherited from class org.apache.xerces.dom.NodeImpl
ELEMENT_DEFINITION_NODE, FIRSTCHILD, flags, IGNORABLEWS, MUTATION_AGGREGATE, MUTATION_ALL, MUTATION_LOCAL, MUTATION_NONE, MUTATIONEVENTS, OWNED, ownerNode, READONLY, SETVALUE, SPECIFIED, SYNCCHILDREN, SYNCDATA
 
Fields inherited from interface org.xmlcml.cml.StringArray
DELIM
 
Fields inherited from interface org.xmlcml.cml.CMLBase
ANGLE, ATOM, ATOMARRAY, BOND, BONDARRAY, BUILTIN, CML, CRYSTAL, ELECTRON, ELEMENT_COUNT, ELEMENT_NAMES, EXECUTE, FEATURE, FLOAT, FLOAT_TYPE, FLOATARRAY, FLOATMATRIX, FORMULA, INTEGER, INTEGER_TYPE, INTEGERARRAY, LINK, LIST, MOLECULE, PACKAGE_NAME, REACTION, SEQUENCE, STRING, STRING_TYPE, STRINGARRAY, TORSION, UNK, UNK_ELEM, UNKNOWN
 
Fields inherited from interface uk.co.demon.ursus.dom.PMRElement
CLASSNAME, LOCAL, QUALIFIED, UNIVERSAL
 
Fields inherited from interface org.xmlcml.cml.HasTitle
TITLE
 
Fields inherited from interface org.xmlcml.cml.HasDictRef
DICTREF
 
Fields inherited from interface org.xmlcml.cml.HasId
ID
 
Fields inherited from interface org.xmlcml.cml.HasConvention
CONVENTION
 
Fields inherited from interface uk.co.demon.ursus.dom.PMRNode
ATTRIBUTES, CONTENT, ELEMENTNAME, IDLIST, NESTED, NESTEDATTS, PACKAGENAME, PRETTY, SPLITFILES, STYLE, TAGGED, UNTAGGED, WHITESPACE, XMLCONTENT
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Constructor Summary
StringArrayImpl()
           
StringArrayImpl(org.w3c.dom.Document document)
          new StringArray in context
StringArrayImpl(org.w3c.dom.Element element)
           
 
Method Summary
 void addElement(java.lang.String s)
           
 void addElement(StringVal s)
          add the StringVal.
static java.util.Vector createStringVector(StringVal stringVal)
           
 void deleteElement(java.lang.String s)
           
 StringVal elementAt(int i)
          this will return an element of appropriate subclass
 java.lang.String getDelimiter()
           
 int getSize()
           
 java.lang.String getString(int i)
           
 java.util.Vector getStringVector()
           
 void processDOM()
          carries out class-specific processing for subclasses of PMRElement.
 void setDelimiter(java.lang.String delimiter)
           
 void setElementAt(java.lang.String s, int i)
           
 
Methods inherited from class org.xmlcml.cml.StringValImpl
init, process, updateDOM
 
Methods inherited from class org.xmlcml.cml.AbstractStringValImpl
getBuiltin, getDataType, getStringValue, processString, setBuiltin, setDataType, setStringValue
 
Methods inherited from class org.xmlcml.cml.CMLBaseImpl
addValidity, convertToSubclass, debug, getConventionName, getDictRef, getId, getSubClassedElement, getTitle, getValidity, help, isValid, main, setConventionName, setDictRef, setId, setTitle, showElementNames, test1, updateDOMHasConvention, updateDOMHasConvention, updateDOMHasCount, updateDOMHasDictRef, updateDOMHasDictRef, updateDOMHasId, updateDOMHasId, updateDOMHasTitle, updateDOMHasTitle, updateDOMHasUnits
 
Methods inherited from class uk.co.demon.ursus.dom.PMRElementImpl
appendTo, initialise, processDescendants, setProcessFlag
 
Methods inherited from class uk.co.demon.ursus.dom.AbstractElementImpl
setTagName
 
Methods inherited from class org.apache.xerces.dom.ElementImpl
cloneNode, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getElementsByTagName, getElementsByTagNameNS, getNodeName, getNodeType, getTagName, hasAttribute, hasAttributeNS, normalize, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setReadOnly, setupDefaultAttributes, synchronizeData
 
Methods inherited from class org.apache.xerces.dom.ChildAndParentNode
changed, changes, getChildNodes, getFirstChild, getLastChild, getLength, getOwnerDocument, hasChildNodes, insertBefore, item, removeChild, replaceChild, synchronizeChildren, synchronizeChildren
 
Methods inherited from class org.apache.xerces.dom.ChildNode
getNextSibling, getParentNode, getPreviousSibling
 
Methods inherited from class org.apache.xerces.dom.NodeImpl
addEventListener, appendChild, dispatchEvent, finalize, getLocalName, getNamespaceURI, getNodeValue, getPrefix, getReadOnly, getUserData, removeEventListener, setNodeValue, setPrefix, setUserData, supports, toString
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

stringVector

protected java.util.Vector stringVector

delimiter

protected java.lang.String delimiter
Constructor Detail

StringArrayImpl

public StringArrayImpl()

StringArrayImpl

public StringArrayImpl(org.w3c.dom.Element element)

StringArrayImpl

public StringArrayImpl(org.w3c.dom.Document document)
new StringArray in context
Method Detail

getSize

public int getSize()
Specified by:
getSize in interface StringArray

setDelimiter

public void setDelimiter(java.lang.String delimiter)
Specified by:
setDelimiter in interface StringArray

getDelimiter

public java.lang.String getDelimiter()
Specified by:
getDelimiter in interface StringArray

elementAt

public StringVal elementAt(int i)
Description copied from interface: HasSize
this will return an element of appropriate subclass
Specified by:
elementAt in interface StringArray

getString

public java.lang.String getString(int i)
Specified by:
getString in interface StringArray

setElementAt

public void setElementAt(java.lang.String s,
                         int i)
Specified by:
setElementAt in interface StringArray

addElement

public void addElement(StringVal s)
add the StringVal. If it is the first to be added, copy the StringVal attributes as well as the value
Specified by:
addElement in interface StringArray

addElement

public void addElement(java.lang.String s)
Specified by:
addElement in interface StringArray

deleteElement

public void deleteElement(java.lang.String s)
Specified by:
deleteElement in interface StringArray

getStringVector

public java.util.Vector getStringVector()
Specified by:
getStringVector in interface StringArray

processDOM

public void processDOM()
                throws CMLException
Description copied from interface: PMRElement
carries out class-specific processing for subclasses of PMRElement. The default for a generic PMRElement is no-op. Often creates an internal model
Overrides:
processDOM in class AbstractStringValImpl
Tags copied from class: PMRElementImpl
Throws:
java.lang.Exception - these can be of many kinds and may include class-specific ones

createStringVector

public static java.util.Vector createStringVector(StringVal stringVal)