org.xanot.dtd
Class DtdAttList

java.lang.Object
  extended by org.xanot.dtd.DtdAttList

public class DtdAttList
extends java.lang.Object

DtdAttList model file. This model represent ATTLIST data inside DTD.

Author:
Ferdinand Neman (newm4n_at_gmail.com)

Field Summary
static java.lang.String ATTLIST
          Pattern for attlist : ATTLIST
static java.lang.String ATTLIST_PATTERN
          Pattern for complete attlist pattern
static java.util.regex.Pattern attlistPattern
          Patter object compiled from ATTLIST_PATTERN
static java.lang.String ATTRIBUTE_NAME
          Attribute Name regex pattern : (\w([\w\-]*\w)*)
static java.lang.String ATTRIBUTE_TYPE
          Attribute types pattern : (CDATA|ID|IDREF|IDREFS|NMTOKEN|NMTOKENS|ENTITY|ENTITIES|NOTATION|"+TYPE_ENUM+")
static java.lang.String CDATA
          CDATA pattern : CDATA
static java.lang.String DEVAULT_VALUE
          Pattern for AttList for default value : (\"[\s\S]+\"|#REQUIRED|#IMPLIED|#FIXED\s \"[\s\S]+\")
static java.lang.String ENTITIES
          ENTITIES pattern : ENTITIES
static java.lang.String ENTITY
          ENTITY pattern : ENTITY
static java.lang.String FIXED_VALUE
          Pattern for AttList which is fixed : #FIXED\s \"[\s\S]+\"
static java.lang.String ID
          ID pattern : ID
static java.lang.String IDREF
          IDREF pattern : IDREF
static java.lang.String IDREFS
          IDREFS pattern : IDREFS
static java.lang.String IMPLIED_VALUE
          Pattern for AttList which is implied : #IMPLIED
static java.lang.String NAME_WITH_SPACE
          An attribute list name pattern : ([\S&&[^\|\(\)]]{1,2}|[\S&&[^\|\(\)]][\s\S&&[^\|\(\)]]+[\S&&[^\|\(\)]])
static java.lang.String NMTOKEN
          NMTOKEN pattern : NMTOKEN
static java.lang.String NMTOKENS
          NMTOKENS pattern : NMTOKENS
static java.lang.String NOTATION
          NOTATION pattern : NOTATION
static java.lang.String OPEN_VALUE
          Pattern for AttList which is an "open value" : \"[\s\S]+\"
static java.lang.String REQUIRED_VALUE
          Pattern for AttList which is required : #REQUIRED
static java.lang.String TYPE_ENUM
          AttList types enum regex pattern : \(\s*"+NAME_WITH_SPACE+"(\s*\|\s*"+NAME_WITH_SPACE+")*\s*\)
 
Constructor Summary
DtdAttList(java.lang.String str)
          Create new instance of DtdAttLIst.
 
Method Summary
 java.lang.String getAttributeDefaultValue()
          Get the attribute default value.
 java.lang.String getAttributeName()
          Get the attribute name of AttList.
 java.lang.String getAttributeType()
          Get the attribute type.
 java.lang.String getElementName()
          Get the element name.
 boolean isTypeCDATA()
          Check wether attlist type is an CDATA type.
 boolean isTypeENTITIES()
          Check wether attlist type is an ENTITIES type.
 boolean isTypeENTITY()
          Check wether attlist type is an ENTITY type.
 boolean isTypeENUM()
          Check wether attlist type is an enum
 boolean isTypeID()
          Check wether attlist type is an ID type.
 boolean isTypeIDREF()
          Check wether attlist type is an IDREF type.
 boolean isTypeIDREFS()
          Check wether attlist type is an IDREFS type.
 boolean isTypeNMTOKEN()
          Check wether attlist type is an NMTOKEN type.
 boolean isTypeNMTOKENS()
          Check wether attlist type is an NMTOKENS type.
 boolean isTypeNOTATION()
          Check wether attlist type is an IDREF type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ATTRIBUTE_NAME

public static java.lang.String ATTRIBUTE_NAME
Attribute Name regex pattern : (\w([\w\-]*\w)*)


NAME_WITH_SPACE

public static java.lang.String NAME_WITH_SPACE
An attribute list name pattern : ([\S&&[^\|\(\)]]{1,2}|[\S&&[^\|\(\)]][\s\S&&[^\|\(\)]]+[\S&&[^\|\(\)]])


TYPE_ENUM

public static java.lang.String TYPE_ENUM
AttList types enum regex pattern : \(\s*"+NAME_WITH_SPACE+"(\s*\|\s*"+NAME_WITH_SPACE+")*\s*\)


CDATA

public static java.lang.String CDATA
CDATA pattern : CDATA


ID

public static java.lang.String ID
ID pattern : ID


IDREF

public static java.lang.String IDREF
IDREF pattern : IDREF


IDREFS

public static java.lang.String IDREFS
IDREFS pattern : IDREFS


NMTOKEN

public static java.lang.String NMTOKEN
NMTOKEN pattern : NMTOKEN


NMTOKENS

public static java.lang.String NMTOKENS
NMTOKENS pattern : NMTOKENS


ENTITY

public static java.lang.String ENTITY
ENTITY pattern : ENTITY


ENTITIES

public static java.lang.String ENTITIES
ENTITIES pattern : ENTITIES


NOTATION

public static java.lang.String NOTATION
NOTATION pattern : NOTATION


ATTRIBUTE_TYPE

public static java.lang.String ATTRIBUTE_TYPE
Attribute types pattern : (CDATA|ID|IDREF|IDREFS|NMTOKEN|NMTOKENS|ENTITY|ENTITIES|NOTATION|"+TYPE_ENUM+")


OPEN_VALUE

public static java.lang.String OPEN_VALUE
Pattern for AttList which is an "open value" : \"[\s\S]+\"


FIXED_VALUE

public static java.lang.String FIXED_VALUE
Pattern for AttList which is fixed : #FIXED\s \"[\s\S]+\"


REQUIRED_VALUE

public static java.lang.String REQUIRED_VALUE
Pattern for AttList which is required : #REQUIRED


IMPLIED_VALUE

public static java.lang.String IMPLIED_VALUE
Pattern for AttList which is implied : #IMPLIED


DEVAULT_VALUE

public static java.lang.String DEVAULT_VALUE
Pattern for AttList for default value : (\"[\s\S]+\"|#REQUIRED|#IMPLIED|#FIXED\s \"[\s\S]+\")


ATTLIST

public static java.lang.String ATTLIST
Pattern for attlist : ATTLIST


ATTLIST_PATTERN

public static java.lang.String ATTLIST_PATTERN
Pattern for complete attlist pattern


attlistPattern

public static java.util.regex.Pattern attlistPattern
Patter object compiled from ATTLIST_PATTERN

Constructor Detail

DtdAttList

public DtdAttList(java.lang.String str)
Create new instance of DtdAttLIst.

Parameters:
str - String part of dtd data that is a AttList data.
Method Detail

isTypeID

public boolean isTypeID()
Check wether attlist type is an ID type.

Returns:
true or false

isTypeIDREF

public boolean isTypeIDREF()
Check wether attlist type is an IDREF type.

Returns:
true or false

isTypeIDREFS

public boolean isTypeIDREFS()
Check wether attlist type is an IDREFS type.

Returns:
true or false

isTypeNMTOKEN

public boolean isTypeNMTOKEN()
Check wether attlist type is an NMTOKEN type.

Returns:
true or false

isTypeNMTOKENS

public boolean isTypeNMTOKENS()
Check wether attlist type is an NMTOKENS type.

Returns:
true or false

isTypeENTITY

public boolean isTypeENTITY()
Check wether attlist type is an ENTITY type.

Returns:
true or false

isTypeENTITIES

public boolean isTypeENTITIES()
Check wether attlist type is an ENTITIES type.

Returns:
true or false

isTypeNOTATION

public boolean isTypeNOTATION()
Check wether attlist type is an IDREF type.

Returns:
true or false

isTypeCDATA

public boolean isTypeCDATA()
Check wether attlist type is an CDATA type.

Returns:
true or false

isTypeENUM

public boolean isTypeENUM()
Check wether attlist type is an enum

Returns:
true or false

getAttributeName

public java.lang.String getAttributeName()
Get the attribute name of AttList.

Returns:
Attribute name

getElementName

public java.lang.String getElementName()
Get the element name.

Returns:
element name

getAttributeType

public java.lang.String getAttributeType()
Get the attribute type.

Returns:
attribute type.

getAttributeDefaultValue

public java.lang.String getAttributeDefaultValue()
Get the attribute default value.

Returns:
attribute's default value.


Copyright 2006 null. All Rights Reserved.