Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.novell.nds.dirxml.driver.xds
Class XDSQueryElement

    java.lang.Object
      com.novell.nds.dirxml.driver.xds.ElementImpl
          com.novell.nds.dirxml.driver.xds.XDSQueryElement

All Implemented Interfaces:
  AssociationElementParent, CommandElement, XDSElement

Direct Known Subclasses:
  XDSQueryExElement

public class XDSQueryElement
extends ElementImpl
implements CommandElement, AssociationElementParent

A `<query>` element.

See Also:
  `XDSCommandDocument`, `XDSQueryDocument`

Field Summary
`static Integer` | `UNLIMITED_RESULTS`

Method Summary
`XDSAssociationElement` | `appendAssociationElement(String value)` Appends a child `<association>` element to this element.
`XDSReadAttrElement` | `appendReadAttrElement()` Appends an empty child `<read-attr>` element to this element.
`XDSReadParentElement` | `appendReadParentElement()` Appends an empty, child `<read-parent>` element to this element.
`XDSSearchAttrElement` | `appendSearchAttrElement()` Appends an empty child `<search-attr>` element to this element.
`XDSSearchClassElement` | `appendSearchClassElement()` Appends an empty child `<search-class>` element to this element.
`List` | `childElements()` Returns this element's child elements.
`boolean` | `containsQueryToken()` Always returns `false` since a standard query cannot contain a query token.
`boolean` | `containsReadAttrElements()` Does this query contain `<read-attr>` elements?
`boolean` | `containsSearchAttrElements()` Does this query contain `search-attr` elements?
`boolean` | `containsSearchClassElements()` Does this query contain `search-class` elements?
`XDSAssociationElement` | `extractAssociationElement()` Returns this element's child `<association>` element.
`String` | `extractAssociationText()` Returns the concatenated child text nodes from this element's child `<association>` element.
`XDSQueryTokenElement` | `extractQueryToken()` Always returns `null` since a standard query does not contain a query token.
`String` | `extractQueryTokenText()` Always returns `null` since a standard query does not contain a query token.
`List` | `extractReadAttrElements()` Returns this element's child `<read-attr>` elements.
`XDSReadParentElement` | `extractReadParentElement()` Returns this element's child `<read-parent>` element.
`List` | `extractSearchAttrElements()` Returns this element's child `<search-attr>` elements.
`List` | `extractSearchClassElements()` Returns this element's child `<search-class>` elements.
`String` | `getClassName()` Gets the value of this element's `class-name` attribute.
`String` | `getDestDN()` Gets the value of this element's `dest-dn` attribute.
`String` | `getEventID()` Gets the value of this element's `event-id` attribute.
`int` | `getMaxResultCount()` How may results should be returned for this query?
`String` | `getQualifiedSrcDN()` A method stub for implementing interface `CommandElement`.
`QueryScope` | `getScope()` Gets the value of this element's `scope` attribute.
`String` | `getSrcDN()` A method stub for implementing interface `CommandElement`.
`String` | `getSrcEntryID()` A method stub for implementing interface `CommandElement`.
`boolean` | `hasEntryScope()` Does this query have entry scope?
`boolean` | `hasLimitedResults()` Always returns `false` since a standard query's result set is unlimited in size.
`boolean` | `hasRootBaseObject()` Is the base object of this query the root object in a heirarchical name space or all objects in a flat name space?
`boolean` | `hasSubordinatesScope()` Does this query have subordinates scope?
`boolean` | `hasSubtreeScope()` Does this query have subtree scope?
`boolean` | `hasUnlimitedResults()` Always returns `true` since a standard query's result set is unlimited in size.
`boolean` | `isCancelled()` Always returns `false` since a standard query can't be cancelled.
`boolean` | `isExtended()` Does this query require special result set handling?
`boolean` | `isIdentity()` Is this query an identity query?
`boolean` | `isInitialQuery()` Always returns `true` since a standard query is always the first and last query in a sequence.
`boolean` | `isSubsequentQuery()` Always returns `false` since a standard query is the first and last query in a sequence.
`void` | `setClassName(String someName)` Sets this element's `class-name` attribute to `someName`.
`void` | `setDestDN(String someDN)` Sets this element's `dest-dn` attribute to `someDN`.
`void` | `setDestEntryID(String someID)` Sets this element's `dest-entry-id` attribute to `someID`.
`void` | `setEventID(String someID)` Sets this element's `event-id` attribute to `someID`.
`void` | `setScope(QueryScope someScope)` Sets this element's `scope` attribute to `someScope`.
`boolean` | `shouldReadAttributes()` Should a driver return attribute information for objects that match this queries search criteria?
`boolean` | `shouldReadParent()` Should a driver return parent object information for objects that match this queries search criteria?
`boolean` | `shouldSearchAllClasses()` Should a driver search all application classes?

Methods inherited from class com.novell.nds.dirxml.driver.xds.ElementImpl
`attributeValueGet, attributeValueGet, attributeValueSet, documentImpl, domDocument, domElement, localName, namespaceName, position, tagName`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface com.novell.nds.dirxml.driver.xds.XDSElement
`attributeValueGet, attributeValueGet, attributeValueSet, domDocument, domElement, localName, namespaceName, position, tagName`

Field Detail

### UNLIMITED_RESULTS

    public static final Integer UNLIMITED_RESULTS

Method Detail

### getSrcDN

    public String getSrcDN()

  A method stub for implementing interface `CommandElement`.

  Invocation Context:
    READ

  Specified by:
    `getSrcDN` in interface `CommandElement`
  Returns:
    always returns `null`; will not return `""`

### getQualifiedSrcDN

    public String getQualifiedSrcDN()

  A method stub for implementing interface `CommandElement`.

  Invocation Context:
    READ

  Specified by:
    `getQualifiedSrcDN` in interface `CommandElement`
  Returns:
    always returns `null`; will not return `""`

### getSrcEntryID

    public String getSrcEntryID()

  A method stub for implementing interface `CommandElement`.

  Invocation Context:
    READ

  Specified by:
    `getSrcEntryID` in interface `CommandElement`
  Returns:
    always returns `null`; will not return `""`

### getScope

    public QueryScope getScope()

  Gets the value of this element's `scope` attribute.

  Invocation Context:
    READ

  Returns:
    will not return `null`

### isIdentity

    public boolean isIdentity()

  Is this query an identity query?

  An identity query is used to identify a driver to the DirXML engine. A query is considered an identity query if either it has an `event-id` attribute value of `"query-driver-ident"` or it contains a `<search-class>` element with a `class-name` attribute value of `"__driver_identification_class__"`.

  Invocation Context:
    READ

  Returns:
    `true`:
      if this query is an identity query
    `false`:
      if this query is not an identity query

### hasEntryScope

    public boolean hasEntryScope()

  Does this query have entry scope?

  Invocation Context:
    READ

  Returns:
    `true`:
      if this query's `scope` attribute value equals `"entry"`
    `false`:
      if this query's `scope` attribute value does not equals `"entry"`

### hasSubordinatesScope

    public boolean hasSubordinatesScope()

  Does this query have subordinates scope?

  Invocation Context:
    READ

  Returns:
    `true`:
      if this query's `scope` attribute value equals `"subordinates"`
    `false`:
      if this query's `scope` attribute value does not equals `"subordinates"`

### hasSubtreeScope

    public boolean hasSubtreeScope()

  Does this query have subtree scope?

  Invocation Context:
    READ

  Returns:
    `true`:
      if this query's `scope` attribute value equals `"subtree"` or `""`
    `false`:
      if this query's `scope` attribute value does not equal `"subtree"` or `""`

### childElements

    public List childElements()

  Returns this element's child elements.

  Usage Notes:
    The types of objects returned by this method may be extended in the future. Thus, callers should be able to handle object types other than those listed in the returns field below.
  Invocation Context:
    READ

  Specified by:
    `childElements` in interface `XDSElement`
  Overrides:
    `childElements` in class `ElementImpl`
  Returns:
    `Collections.EMPTY_LIST` or a list of `XDSAssociationElement`, `XDSSearchClassElement`, `XDSSearchAttrElement`, `XDSReadAttrElement`, `XDSReadParentElement`, and `NonXDSElement` objects; will not return `null`

### extractAssociationElement

    public XDSAssociationElement extractAssociationElement()

  Returns this element's child `<association>` element.

  Invocation Context:
    READ

  Specified by:
    `extractAssociationElement` in interface `AssociationElementParent`
  Returns:
    may return `null`

### extractAssociationText

    public String extractAssociationText()

  Returns the concatenated child text nodes from this element's child `<association>` element.

  Invocation Context:
    READ

  Specified by:
    `extractAssociationText` in interface `AssociationElementParent`
  Returns:
    may return `null`; will not return `""`

### getClassName

    public String getClassName()

  Gets the value of this element's `class-name` attribute.

  This value should not be used to limit the scope of classes searched.

  Invocation Context:
    READ

  Specified by:
    `getClassName` in interface `CommandElement`
  Returns:
    may return `null`; will not return `""`
  See Also:
    `extractSearchClassElements()`

### getDestDN

    public String getDestDN()

  Gets the value of this element's `dest-dn` attribute.

  Invocation Context:
    READ

  Returns:
    may return `null`; will not return `""`

### getEventID

    public String getEventID()

  Description copied from interface: `CommandElement`
  Gets the value of this element's `event-id` attribute.

  Invocation Context:
    READ

  Specified by:
    `getEventID` in interface `CommandElement`
  Returns:
    may return `null`; will not return `""`

### shouldSearchAllClasses

    public boolean shouldSearchAllClasses()

  Should a driver search all application classes?

  Invocation Context:
    READ

  Returns:
    `true`:
      if all classes should be searched
    `false`:
      if all classes should not be searched

### shouldReadAttributes

    public boolean shouldReadAttributes()

  Should a driver return attribute information for objects that match this queries search criteria?

  Invocation Context:
    READ

  Returns:
    `true`:
      if attributes should be read
    `false`:
      if attributes should not be read

### hasRootBaseObject

    public boolean hasRootBaseObject()

  Is the base object of this query the root object in a heirarchical name space or all objects in a flat name space?

  The base object of a query is specified by either the `dest-dn` attribute or child `<association>` element. If neither are present, the base object defaults to the root object in a hierarchical name space or all ojects in a non-hierarchical name space.

  Invocation Context:
    READ

  Returns:
    `true`:
      if the base object of this query is root
    `false`:
      if the base object of this query is not root

### containsSearchAttrElements

    public boolean containsSearchAttrElements()

  Does this query contain `search-attr` elements?

  Invocation Context:
    READ

  Returns:
    `true` if this query contains `search-attr` elements, `false` otherwise

### containsReadAttrElements

    public boolean containsReadAttrElements()

  Does this query contain `<read-attr>` elements?

  NOTE: returns `false` if this query contains a `<read-attr>` element without an `attr-name` attribute value

  Invocation Context:
    READ

  Returns:
    `true` if this query contains `read-attr` elements with `attr-name` attribute values, `false` otherwise

### containsSearchClassElements

    public boolean containsSearchClassElements()

  Does this query contain `search-class` elements?

  Invocation Context:
    READ

  Returns:
    `true` if this query contains `search-class` elements, `false` otherwise

### extractSearchClassElements

    public List extractSearchClassElements()

  Returns this element's child `<search-class>` elements.

  Invocation Context:
    READ

  Returns:
    `java.util.Collections.EMPTY_LIST` or a list of `XDSSearchClassElement` objects; will not return `null`

### extractSearchAttrElements

    public List extractSearchAttrElements()

  Returns this element's child `<search-attr>` elements.

  Invocation Context:
    READ

  Returns:
    `java.util.Collections.EMPTY_LIST` or a list of `XDSSearchAttrElement` objects; will not return `null`

### extractReadAttrElements

    public List extractReadAttrElements()

  Returns this element's child `<read-attr>` elements.

  NOTE: returns `Collections.EMPTY_LIST` if this query contains a `<read-attr>` element without an `attr-name` attribute value

  Invocation Context:
    READ

  Returns:
    `java.util.Collections.EMPTY_LIST` or a list of `XDSReadAttrElement` objects; will not return `null`

### shouldReadParent

    public boolean shouldReadParent()

  Should a driver return parent object information for objects that match this queries search criteria?

  Invocation Context:
    READ

  Returns:
    `true`:
      if query should return parent object information
    `false`:
      if query should not return parent object information

### extractReadParentElement

    public XDSReadParentElement extractReadParentElement()

  Returns this element's child `<read-parent>` element.

  Invocation Context:
    READ

  Returns:
    may return `null`

### getMaxResultCount

    public int getMaxResultCount()

  How may results should be returned for this query?

  Invocation Context:
    READ

  Returns:
    always returns `java.lang.Integer.MAX_VALUE`
  See Also:
    `Integer.MAX_VALUE`

### containsQueryToken

    public boolean containsQueryToken()

  Always returns `false` since a standard query cannot contain a query token.

  Invocation Context:
    READ

  Returns:
    always returns `false`

### extractQueryToken

    public XDSQueryTokenElement extractQueryToken()

  Always returns `null` since a standard query does not contain a query token.

  Invocation Context:
    READ

  Returns:
    always returns `null`

### extractQueryTokenText

    public String extractQueryTokenText()

  Always returns `null` since a standard query does not contain a query token.

  Invocation Context:
    READ

  Returns:
    always returns `null`

### hasUnlimitedResults

    public boolean hasUnlimitedResults()

  Always returns `true` since a standard query's result set is unlimited in size.

  Invocation Context:
    READ

  Returns:
    always returns `true`

### hasLimitedResults

    public boolean hasLimitedResults()

  Always returns `false` since a standard query's result set is unlimited in size.

  Invocation Context:
    READ

  Returns:
    always returns `false`

### isCancelled

    public boolean isCancelled()

  Always returns `false` since a standard query can't be cancelled.

  Invocation Context:
    READ

  Returns:
    always returns `false`

### isExtended

    public boolean isExtended()

  Does this query require special result set handling?

  This method always returns `false` since a standard query is, by definition, not an extended query (that is, cannot limit the size of a result set).

  Invocation Context:
    READ

  Returns:
    always returns `false`

### isInitialQuery

    public boolean isInitialQuery()

  Always returns `true` since a standard query is always the first and last query in a sequence.

  Invocation Context:
    READ

  Returns:
    always returns `false`

### isSubsequentQuery

    public boolean isSubsequentQuery()

  Always returns `false` since a standard query is the first and last query in a sequence.

  Invocation Context:
    READ

  Returns:
    always returns `false`

### setDestDN

    public void setDestDN(String someDN)

  Sets this element's `dest-dn` attribute to `someDN`.

  Invocation Context:
    WRITE

  Parameters:
    `someDN` - if `null` or `""`, no action is taken

### setClassName

    public void setClassName(String someName)

  Sets this element's `class-name` attribute to `someName`.

  Invocation Context:
    WRITE

  Parameters:
    `someName` - if `null` or `""`, no action is taken

### setEventID

    public void setEventID(String someID)

  Description copied from interface: `CommandElement`
  Sets this element's `event-id` attribute to `someID`.

  Invocation Context:
    WRITE

  Specified by:
    `setEventID` in interface `CommandElement`
  Parameters:
    `someID` - if `null` or `""`, no action is taken

### setDestEntryID

    public void setDestEntryID(String someID)

  Sets this element's `dest-entry-id` attribute to `someID`.

  Invocation Context:
    WRITE

  Parameters:
    `someID` - if `null` or `""`, no action is taken

### setScope

    public void setScope(QueryScope someScope)

  Sets this element's `scope` attribute to `someScope`.

  Invocation Context:
    WRITE

  Parameters:
    `someScope` - if `null`, no action is taken

### appendAssociationElement

    public XDSAssociationElement appendAssociationElement(String value)

  Description copied from interface: `AssociationElementParent`
  Appends a child `<association>` element to this element. The `<association>` element contains the text `someText`.

  Invocation Context:
    WRITE

  Specified by:
    `appendAssociationElement` in interface `AssociationElementParent`
  Parameters:
    `value` - the association value; if `null` or `""`, an empty, child `<association>` element is appended
  Returns:
    will not return `null`

### appendSearchClassElement

    public XDSSearchClassElement appendSearchClassElement()

  Appends an empty child `<search-class>` element to this element.

  Invocation Context:
    WRITE

  Returns:
    will not return `null`

### appendSearchAttrElement

    public XDSSearchAttrElement appendSearchAttrElement()

  Appends an empty child `<search-attr>` element to this element.

  Invocation Context:
    WRITE

  Returns:
    will not return `null`

### appendReadAttrElement

    public XDSReadAttrElement appendReadAttrElement()

  Appends an empty child `<read-attr>` element to this element.

  Invocation Context:
    WRITE

  Returns:
    will not return `null`

### appendReadParentElement

    public XDSReadParentElement appendReadParentElement()

  Appends an empty, child `<read-parent>` element to this element. When called multiple times, no action is taken and the first `<read-parent>` element is returned.

  Invocation Context:
    WRITE

  Returns:
    will not return `null`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD