|
|||||||||
| Home >> All >> com >> hexidec >> ekit >> component >> [ parser overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
com.hexidec.ekit.component.parser
Class ContentModel

java.lang.Objectcom.hexidec.ekit.component.parser.ContentModel
- All Implemented Interfaces:
- java.io.Serializable
- public final class ContentModel
- extends java.lang.Object
- implements java.io.Serializable
- extends java.lang.Object
A representation of a content model. A content model is basically a restricted BNF expression. It is restricted in the sense that it must be deterministic. This means that you don't have to represent it as a finite state automata.
See Annex H on page 556 of the SGML handbook for more information.
- Version:
- 1.8,12/03/01
| Field Summary | |
java.lang.Object |
content
The content. |
ContentModel |
next
The next content model (in a ',', '|' or '&' expression). |
int |
type
Type. |
private boolean[] |
val
|
private boolean[] |
valSet
|
| Constructor Summary | |
ContentModel()
|
|
ContentModel(Element content)
Create a content model for an element. |
|
ContentModel(int type,
ContentModel content)
Create a content model of a particular type. |
|
ContentModel(int type,
java.lang.Object content,
ContentModel next)
Create a content model of a particular type. |
|
| Method Summary | |
boolean |
empty()
Return true if the content model could match an empty input stream. |
Element |
first()
Return the element that must be next. |
boolean |
first(java.lang.Object token)
Return true if the token could potentially be the first token in the input stream. |
void |
getElements(java.util.Vector elemVec)
Update elemVec with the list of elements that are part of the this contentModel. |
java.lang.String |
toString()
Convert to a string. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
type
public int type
- Type. Either '*', '?', '+', ',', '|', '&'.
content
public java.lang.Object content
- The content. Either an Element or a ContentModel.
next
public ContentModel next
- The next content model (in a ',', '|' or '&' expression).
valSet
private boolean[] valSet
val
private boolean[] val
| Constructor Detail |
ContentModel
public ContentModel()
ContentModel
public ContentModel(Element content)
- Create a content model for an element.
ContentModel
public ContentModel(int type,
ContentModel content)
- Create a content model of a particular type.
ContentModel
public ContentModel(int type,
java.lang.Object content,
ContentModel next)
- Create a content model of a particular type.
| Method Detail |
empty
public boolean empty()
- Return true if the content model could
match an empty input stream.
getElements
public void getElements(java.util.Vector elemVec)
- Update elemVec with the list of elements that are
part of the this contentModel.
first
public boolean first(java.lang.Object token)
- Return true if the token could potentially be the
first token in the input stream.
first
public Element first()
- Return the element that must be next.
toString
public java.lang.String toString()
- Convert to a string.
|
|||||||||
| Home >> All >> com >> hexidec >> ekit >> component >> [ parser overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
com.hexidec.ekit.component.parser.ContentModel