Top Description Fields Methods
org.apache.xerces.xpointer

public Interface XPointerPart

Known Direct Implementers
org.apache.xerces.xpointer.ElementSchemePointer, org.apache.xerces.xpointer.ShortHandPointer
Imports
org.apache.xerces.xni.Augmentations, .QName, .XMLAttributes, .XNIException

Used for scheme specific parsing and evaluation of an XPointer expression. This interface applies to both ShortHand and SchemeBased XPointer expressions.

Version
$Id: XPointerPart.java 603808 2007-12-13 03:44:48Z mrglavas $

Field Summary

Modifier and TypeField and Description
public static final int
public static final int
public static final int

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

A String containing the scheme data of the PointerPart.
getSchemeData
()

Returns a String containing the scheme data of the PointerPart.

public String

Returns:

A String containing the scheme name of the PointerPart.
getSchemeName
()

Returns a String containing the scheme name of the PointerPart or the name of the ShortHand Pointer.

public boolean

Returns:

True if the XPointer expression resolves to a non-element child of the current resource fragment.
isChildFragmentResolved
()

Returns true if the XPointer expression resolves to a non-element child of the current resource fragment.

public boolean

Returns:

True if the xpointer expression matches a fragment in the resource else returns false.
isFragmentResolved
()

Returns true if the XPointer expression resolves to a resource fragment specified as input else returns false.

public void
parseXPointer(String
A String representing the PointerPart or ShortHandPointer.
part
)

Provides scheme specific parsing of a XPointer expression i.e. the PointerPart or ShortHandPointer.

public boolean
resolveXPointer(QName
- The name of the element.
element
,
XMLAttributes
- The element attributes.
attributes
,
Augmentations
- Additional information that may include infoset augmentations
augs
,
int
- An integer indicating 0 - The start of an element 1 - The end of an element 2 - An empty element call
event
)

Evaluates an XML resource with respect to an XPointer expressions by checking if it's element and attributes parameters match the criteria specified in the xpointer expression.

public void
setSchemeData(String
A String containing the scheme data of the PointerPart.
schemeData
)

Sets the scheme data of the PointerPart.

public void
setSchemeName(String
A String containing the scheme name of the PointerPart.
schemeName
)

Sets the scheme name of the PointerPart or the ShortHand Pointer name.

Field Detail

EVENT_ELEMENT_EMPTYback to summary
public static final int EVENT_ELEMENT_EMPTY
EVENT_ELEMENT_ENDback to summary
public static final int EVENT_ELEMENT_END
EVENT_ELEMENT_STARTback to summary
public static final int EVENT_ELEMENT_START

Method Detail

getSchemeDataback to summary
public String getSchemeData()

Returns a String containing the scheme data of the PointerPart.

Returns:String

A String containing the scheme data of the PointerPart.

getSchemeNameback to summary
public String getSchemeName()

Returns a String containing the scheme name of the PointerPart or the name of the ShortHand Pointer.

Returns:String

A String containing the scheme name of the PointerPart.

isChildFragmentResolvedback to summary
public boolean isChildFragmentResolved() throws XNIException

Returns true if the XPointer expression resolves to a non-element child of the current resource fragment.

Returns:boolean

True if the XPointer expression resolves to a non-element child of the current resource fragment.

Exceptions
XNIException:
Thrown to signal an error
isFragmentResolvedback to summary
public boolean isFragmentResolved() throws XNIException

Returns true if the XPointer expression resolves to a resource fragment specified as input else returns false.

Returns:boolean

True if the xpointer expression matches a fragment in the resource else returns false.

Exceptions
XNIException:
Thrown to signal an error
parseXPointerback to summary
public void parseXPointer(String part) throws XNIException

Provides scheme specific parsing of a XPointer expression i.e. the PointerPart or ShortHandPointer.

Parameters
part:String

A String representing the PointerPart or ShortHandPointer.

Exceptions
XNIException:
Thrown if the PointerPart string does not conform to the syntax defined by its scheme.
resolveXPointerback to summary
public boolean resolveXPointer(QName element, XMLAttributes attributes, Augmentations augs, int event) throws XNIException

Evaluates an XML resource with respect to an XPointer expressions by checking if it's element and attributes parameters match the criteria specified in the xpointer expression.

Parameters
element:QName

- The name of the element.

attributes:XMLAttributes

- The element attributes.

augs:Augmentations

- Additional information that may include infoset augmentations

event:int

- An integer indicating 0 - The start of an element 1 - The end of an element 2 - An empty element call

Exceptions
XNIException:
Thrown to signal an error
setSchemeDataback to summary
public void setSchemeData(String schemeData)

Sets the scheme data of the PointerPart.

Parameters
schemeData:String

A String containing the scheme data of the PointerPart.

setSchemeNameback to summary
public void setSchemeName(String schemeName)

Sets the scheme name of the PointerPart or the ShortHand Pointer name.

Parameters
schemeName:String

A String containing the scheme name of the PointerPart.