Top Description Fields Constructors Methods
com.sun.org.apache.xerces.internal.impl.xs.identity

public abstract Class IdentityConstraint

extends Object
implements XSIDCDefinition
Class Inheritance
All Implemented Interfaces
com.sun.org.apache.xerces.internal.xs.XSIDCDefinition, com.sun.org.apache.xerces.internal.xs.XSObject
Known Direct Subclasses
com.sun.org.apache.xerces.internal.impl.xs.identity.KeyRef, com.sun.org.apache.xerces.internal.impl.xs.identity.UniqueOrKey
Imports
com.sun.org.apache.xerces.internal.xs.XSIDCDefinition, .StringList, .XSNamespaceItem, .XSObjectList, .XSConstants, com.sun.org.apache.xerces.internal.impl.xs.util.StringListImpl, .XSObjectListImpl, com.sun.org.apache.xerces.internal.impl.xs.XSAnnotationImpl

Base class of Schema identity constraint.
Author
Andy Clark, IBM

Field Summary

Modifier and TypeField and Description
protected XSAnnotationImpl[]
protected String
fElementName

name of owning element

protected int
fFieldCount

Field count.

protected Field[]
fFields

Fields.

protected String
fIdentityConstraintName

Identity constraint name.

protected String
fNamespace

target namespace

protected int
protected Selector
fSelector

Selector.

protected short
type

type

Constructor Summary

AccessConstructor and Description
protected
IdentityConstraint(String namespace, String identityConstraintName, String elemName)

Default constructor.

Method Summary

Modifier and TypeMethod and Description
public void
public void
addField(Field field)

Adds a field.

public boolean
public XSObjectList
public short
getCategory()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getCategory.

{identity-constraint category} One of key, keyref or unique.

public String
public Field
getFieldAt(int index)

Returns the field at the specified index.

public int
getFieldCount()

Returns the field count.

public StringList
getFieldStrs()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getFieldStrs.

{fields} A non-empty list of restricted XPath ([XPath]) expressions.

public String
getIdentityConstraintName()

Returns the identity constraint name.

public String
getName()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getName.

The name of this XSObject depending on the XSObject type.

public String
getNamespace()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getNamespace.

The namespace URI of this node, or null if it is unspecified.

public XSNamespaceItem
getNamespaceItem()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getNamespaceItem.

A namespace schema information item corresponding to the target namespace of the component, if it is globally declared; or null otherwise.

public XSIDCDefinition
getRefKey()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getRefKey.

{referenced key} Required if {identity-constraint category} is keyref, forbidden otherwise.

public Selector
getSelector()

Returns the selector.

public String
getSelectorStr()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getSelectorStr.

{selector} A restricted XPath ([XPath]) expression

public short
getType()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getType.

Get the type of the object, i.e ELEMENT_DECLARATION.

pack-priv static final Field[]
resize(Field[] oldArray, int newSize)

public void
setSelector(Selector selector)

Sets the selector.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of this object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

fAnnotationsback to summary
protected XSAnnotationImpl[] fAnnotations
fElementNameback to summary
protected String fElementName

name of owning element

fFieldCountback to summary
protected int fFieldCount

Field count.

fFieldsback to summary
protected Field[] fFields

Fields.

fIdentityConstraintNameback to summary
protected String fIdentityConstraintName

Identity constraint name.

fNamespaceback to summary
protected String fNamespace

target namespace

fNumAnnotationsback to summary
protected int fNumAnnotations
fSelectorback to summary
protected Selector fSelector

Selector.

typeback to summary
protected short type

type

Constructor Detail

IdentityConstraintback to summary
protected IdentityConstraint(String namespace, String identityConstraintName, String elemName)

Default constructor.

Method Detail

addAnnotationback to summary
public void addAnnotation(XSAnnotationImpl annotation)
addFieldback to summary
public void addField(Field field)

Adds a field.

equalsback to summary
public boolean equals(IdentityConstraint id)
getAnnotationsback to summary
public XSObjectList getAnnotations()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getAnnotations.

Optional. Annotation.

getCategoryback to summary
public short getCategory()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getCategory.

{identity-constraint category} One of key, keyref or unique.

getElementNameback to summary
public String getElementName()
getFieldAtback to summary
public Field getFieldAt(int index)

Returns the field at the specified index.

getFieldCountback to summary
public int getFieldCount()

Returns the field count.

getFieldStrsback to summary
public StringList getFieldStrs()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getFieldStrs.

{fields} A non-empty list of restricted XPath ([XPath]) expressions.

getIdentityConstraintNameback to summary
public String getIdentityConstraintName()

Returns the identity constraint name.

getNameback to summary
public String getName()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getName.

The name of this XSObject depending on the XSObject type.

getNamespaceback to summary
public String getNamespace()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getNamespace.

The namespace URI of this node, or null if it is unspecified. defines how a namespace URI is attached to schema components.

getNamespaceItemback to summary
public XSNamespaceItem getNamespaceItem()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getNamespaceItem.

Doc from com.sun.org.apache.xerces.internal.xs.XSObject.getNamespaceItem.

A namespace schema information item corresponding to the target namespace of the component, if it is globally declared; or null otherwise.

See Also
com.sun.org.apache.xerces.internal.xs.XSObject#getNamespaceItem()
getRefKeyback to summary
public XSIDCDefinition getRefKey()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getRefKey.

{referenced key} Required if {identity-constraint category} is keyref, forbidden otherwise. An identity-constraint definition with {identity-constraint category} equal to key or unique.

getSelectorback to summary
public Selector getSelector()

Returns the selector.

getSelectorStrback to summary
public String getSelectorStr()

Implements com.sun.org.apache.xerces.internal.xs.XSIDCDefinition.getSelectorStr.

{selector} A restricted XPath ([XPath]) expression

getTypeback to summary
public short getType()

Implements com.sun.org.apache.xerces.internal.xs.XSObject.getType.

Get the type of the object, i.e ELEMENT_DECLARATION.

resizeback to summary
pack-priv static final Field[] resize(Field[] oldArray, int newSize)
setSelectorback to summary
public void setSelector(Selector selector)

Sets the selector.

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Returns a string representation of this object.

Returns:String

Doc from java.lang.Object.toString.

a string representation of the object