org.apache.xerces.validators.common
Class Grammar
java.lang.Object
|
+--org.apache.xerces.validators.common.Grammar
- Direct Known Subclasses:
- DTDGrammar, SchemaGrammar
- public class Grammar
- extends java.lang.Object
- implements XMLContentSpec.Provider
- Version:
- $Id: Grammar.java,v 1.14 2000/09/11 18:21:13 ericye Exp $
Method Summary |
protected int |
createAttributeDecl()
|
protected int |
createContentSpec()
|
protected int |
createElementDecl()
|
boolean |
getAttributeDecl(int attributeDeclIndex,
XMLAttributeDecl attributeDecl)
|
boolean |
getContentSpec(int contentSpecIndex,
XMLContentSpec contentSpec)
Fills in the provided content spec structure with content spec
information for a unique identifier. |
XMLContentModel |
getElementContentModel(int elementDeclIndex)
|
boolean |
getElementDecl(int elementDeclIndex,
XMLElementDecl elementDecl)
|
int |
getElementDeclIndex(int localpartIndex,
int scopeIndex)
|
int |
getElementDeclIndex(int uriIndex,
int localpartIndex,
int scopeIndex)
|
int |
getElementDeclIndex(QName element,
int scopeIndex)
|
int |
getFirstAttributeDeclIndex(int elementDeclIndex)
|
Document |
getGrammarDocument()
|
int |
getNextAttributeDeclIndex(int attributeDeclIndex)
|
protected boolean |
isDTD()
|
void |
printAttributes(int elementDeclIndex)
|
void |
printElements(StringPool pool)
|
protected void |
putElementNameMapping(QName name,
int scope,
int elementDeclIndex)
|
protected void |
setAttributeDecl(int elementDeclIndex,
int attributeDeclIndex,
XMLAttributeDecl attributeDecl)
|
protected void |
setContentSpec(int contentSpecIndex,
XMLContentSpec contentSpec)
|
protected void |
setElementDecl(int elementDeclIndex,
XMLElementDecl elementDecl)
|
protected void |
setFirstAttributeDeclIndex(int elementDeclIndex,
int newFirstAttrIndex)
|
protected void |
setGrammarDocument(Document grammarDocument)
|
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Grammar
public Grammar()
getGrammarDocument
public Document getGrammarDocument()
getElementDeclIndex
public int getElementDeclIndex(int localpartIndex,
int scopeIndex)
getElementDeclIndex
public int getElementDeclIndex(int uriIndex,
int localpartIndex,
int scopeIndex)
getElementDeclIndex
public int getElementDeclIndex(QName element,
int scopeIndex)
getElementDecl
public boolean getElementDecl(int elementDeclIndex,
XMLElementDecl elementDecl)
getFirstAttributeDeclIndex
public int getFirstAttributeDeclIndex(int elementDeclIndex)
getNextAttributeDeclIndex
public int getNextAttributeDeclIndex(int attributeDeclIndex)
getContentSpec
public boolean getContentSpec(int contentSpecIndex,
XMLContentSpec contentSpec)
- Description copied from interface: XMLContentSpec.Provider
- Fills in the provided content spec structure with content spec
information for a unique identifier.
- Specified by:
- getContentSpec in interface XMLContentSpec.Provider
- Tags copied from interface: XMLContentSpec.Provider
- Parameters:
contentSpecIndex
- The content spec identifier. All content
spec "nodes" have a unique identifier.contentSpec
- The content spec struct to fill in with
the information.- Returns:
- Returns true if the contentSpecIndex was found.
getElementContentModel
public XMLContentModel getElementContentModel(int elementDeclIndex)
throws CMException
getAttributeDecl
public boolean getAttributeDecl(int attributeDeclIndex,
XMLAttributeDecl attributeDecl)
setGrammarDocument
protected void setGrammarDocument(Document grammarDocument)
createElementDecl
protected int createElementDecl()
setElementDecl
protected void setElementDecl(int elementDeclIndex,
XMLElementDecl elementDecl)
putElementNameMapping
protected void putElementNameMapping(QName name,
int scope,
int elementDeclIndex)
setFirstAttributeDeclIndex
protected void setFirstAttributeDeclIndex(int elementDeclIndex,
int newFirstAttrIndex)
createContentSpec
protected int createContentSpec()
setContentSpec
protected void setContentSpec(int contentSpecIndex,
XMLContentSpec contentSpec)
createAttributeDecl
protected int createAttributeDecl()
setAttributeDecl
protected void setAttributeDecl(int elementDeclIndex,
int attributeDeclIndex,
XMLAttributeDecl attributeDecl)
isDTD
protected boolean isDTD()
printElements
public void printElements(StringPool pool)
printAttributes
public void printAttributes(int elementDeclIndex)
Copyright © 1999-2000 Apache XML Project. All Rights Reserved.