public class CMDTDElementDeclaration extends org.apache.xerces.impl.dtd.XMLElementDecl implements CMElementDeclaration
contentModelValidator, name, scope, simpleType, type, TYPE_ANY, TYPE_CHILDREN, TYPE_EMPTY, TYPE_MIXED, TYPE_SIMPLE
ANY_ELEMENT_DECLARATIONS
Constructor and Description |
---|
CMDTDElementDeclaration(CMDTDDocument document,
int index) |
Modifier and Type | Method and Description |
---|---|
CMAttributeDeclaration |
findCMAttribute(String attributeName,
String namespace)
Returns the declared attribute which match the given name and null otherwise.
|
CMElementDeclaration |
findCMElement(String tag,
String namespace)
Returns the declared element which matches the given XML tag name / namespace
and null otherwise.
|
Collection<CMAttributeDeclaration> |
getAttributes()
Returns the attributes of this declared element.
|
String |
getDocumentation(ISharedSettingsRequest settings)
Returns formatted documentation of the declared element, according to
settings defined in
request . |
String |
getDocumentation(String attrName) |
String |
getDocumentURI()
Returns the owner document URI where the element is declared.
|
Collection<CMElementDeclaration> |
getElements()
Returns the children declared element of this declared element.
|
Collection<String> |
getEnumerationValues()
Return the enumeration values.
|
int |
getIndex() |
String |
getLocalName()
Returns the declared element local name.
|
String |
getNamespace()
Returns the target namespace and null otherwise.
|
Collection<CMElementDeclaration> |
getPossibleElements(DOMElement parentElement,
int offset)
Returns the possible declared elements at the given offset of the given
parent element.
|
String |
getPrefix(String namespaceURI)
Returns the xmlns prefix from the given namespace URI and null otherwise.
|
String |
getTextDocumentation(String value,
ISharedSettingsRequest request)
Returns the documentation for the given enumeration value and null otherwise.
|
boolean |
isEmpty()
Returns true if the element cannot contains element children or text content
and false otherwise.
|
boolean |
isMixedContent()
Returns true if the element can contains text and element both and false
otherwise.
|
boolean |
isNillable()
Returns true if the element can have an explicit null value assigned to it.
|
boolean |
isOptional(String childElementName)
Returns true if the child element name is optional and false otherwise.
|
boolean |
isStringType()
Returns true if the element is a string type (ex : xs:string) and false
otherwise.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
findCMAttribute, getName
public CMDTDElementDeclaration(CMDTDDocument document, int index)
public String getLocalName()
CMElementDeclaration
getLocalName
in interface CMElementDeclaration
public String getNamespace()
CMElementDeclaration
getNamespace
in interface CMElementDeclaration
public String getPrefix(String namespaceURI)
CMElementDeclaration
getPrefix
in interface CMElementDeclaration
namespaceURI
- the namespacepublic Collection<CMAttributeDeclaration> getAttributes()
CMElementDeclaration
getAttributes
in interface CMElementDeclaration
public Collection<CMElementDeclaration> getElements()
CMElementDeclaration
getElements
in interface CMElementDeclaration
public Collection<CMElementDeclaration> getPossibleElements(DOMElement parentElement, int offset)
CMElementDeclaration
getPossibleElements
in interface CMElementDeclaration
parentElement
- the parent elementoffset
- the offsetpublic CMElementDeclaration findCMElement(String tag, String namespace)
CMElementDeclaration
findCMElement
in interface CMElementDeclaration
public CMAttributeDeclaration findCMAttribute(String attributeName, String namespace)
CMElementDeclaration
findCMAttribute
in interface CMElementDeclaration
attributeName
- the attribute name.namespace
- the attribute namespace and null otherwise.public String getDocumentation(ISharedSettingsRequest settings)
CMElementDeclaration
request
.getDocumentation
in interface CMElementDeclaration
settings
- the request containing settingsrequest
.public boolean isEmpty()
CMElementDeclaration
isEmpty
in interface CMElementDeclaration
public boolean isNillable()
CMElementDeclaration
isNillable
in interface CMElementDeclaration
public Collection<String> getEnumerationValues()
CMElementDeclaration
getEnumerationValues
in interface CMElementDeclaration
public String getTextDocumentation(String value, ISharedSettingsRequest request)
CMElementDeclaration
getTextDocumentation
in interface CMElementDeclaration
value
- the enumeration value.request
- the shared settings.public int getIndex()
public String getDocumentURI()
CMElementDeclaration
getDocumentURI
in interface CMElementDeclaration
public boolean isStringType()
CMElementDeclaration
isStringType
in interface CMElementDeclaration
public boolean isMixedContent()
CMElementDeclaration
isMixedContent
in interface CMElementDeclaration
public boolean isOptional(String childElementName)
CMElementDeclaration
isOptional
in interface CMElementDeclaration
Copyright © 2022. All rights reserved.