Oracle Secure Global Desktop Web Services API Documentation
Release 4.7

E21396-02

com.tarantella.tta.webservices.parser
Interface IResponse

All Superinterfaces:
java.io.Serializable

public interface IResponse
extends java.io.Serializable

The interface defines the nodes of parse trees created from XML returned by Secure Global Desktop (SGD) web services.

Each node may have a name, some attributes and children, which also implement IResponse.

IResponse nodes are created by factories that implement IResponseFactory.


Method Summary
 void addChild(IResponse node)
          Adds a child to a node.
 IResponse clone(boolean cloneChildren, IResponseFactory factory)
          Clones a node.
 java.lang.String[] getAttribute(java.lang.String name)
          Gets the values for a named attribute in the node.
 java.util.Enumeration getAttributeNames()
          Gets an enumeration of attribute names in the node.
 java.util.Enumeration getAttributeValues()
          Gets an enumeration of attribute values in the node.
 int getChildCount()
          Gets the number of children on the node.
 java.util.Enumeration getChildren()
          Gets an enumeration of children.
 java.lang.String getElementName()
          Gets the element name of the node.
 int getLevel()
          Gets the node's level (depth) in the parse tree.
 IResponse getParent()
          Gets the parent of a node.
 void removeChild(IResponse node)
          Removes a child from a node.
 void setAttribute(java.lang.String name, java.lang.String[] values)
          Sets the values for a named attribute in the node.
 void setParent(IResponse parent)
          Sets the parent of a node.
 

Method Detail

getAttribute

java.lang.String[] getAttribute(java.lang.String name)
Gets the values for a named attribute in the node.

Parameters:
name - Attribute name.
Returns:
Array of attributes values. If there are no values, returns an array of length 1 containing a null value.
Since:
1.0

setAttribute

void setAttribute(java.lang.String name,
                  java.lang.String[] values)
Sets the values for a named attribute in the node.

Parameters:
name - Attribute name.
values - Attribute values. If null, the attribute is removed.
Since:
1.0

getAttributeNames

java.util.Enumeration getAttributeNames()
Gets an enumeration of attribute names in the node.

Returns:
Enumeration of attribute names.
Since:
1.0

getAttributeValues

java.util.Enumeration getAttributeValues()
Gets an enumeration of attribute values in the node.

Returns:
Enumeration of attribute values.
Since:
1.0

getLevel

int getLevel()
Gets the node's level (depth) in the parse tree.

Returns:
Level in the parse tree, indexing from 0.
Since:
1.0

getChildCount

int getChildCount()
Gets the number of children on the node. The count only includes direct children and not grandchildren, etc.

Returns:
Number of children.
Since:
1.0

getElementName

java.lang.String getElementName()
Gets the element name of the node.

Returns:
Element name.
Since:
1.0

getChildren

java.util.Enumeration getChildren()
Gets an enumeration of children.

Returns:
Enumeration of children.
Since:
1.0

addChild

void addChild(IResponse node)
Adds a child to a node.

Parameters:
node - Child node.
Since:
1.0

removeChild

void removeChild(IResponse node)
Removes a child from a node.

Parameters:
node - Child node.
Since:
1.0

getParent

IResponse getParent()
Gets the parent of a node.

Returns:
Parent node.
Since:
1.0

setParent

void setParent(IResponse parent)
Sets the parent of a node.

Parameters:
parent - Parent node.
Since:
1.0

clone

IResponse clone(boolean cloneChildren,
                IResponseFactory factory)
Clones a node.

Parameters:
cloneChildren - Flag indicating if children are also cloned.
factory - Factory for creating new IResponse nodes.
Returns:
A cloned node.
Since:
1.0

Oracle Secure Global Desktop Web Services API Documentation
Release 4.7

E21396-02

Copyright © 2012, 2013, Oracle and/or its affiliates. All rights reserved.