JSampler
v0.8a

org.jsampler
Class LscpNode

java.lang.Object
  extended by org.jsampler.LscpNode

public class LscpNode
extends java.lang.Object


Constructor Summary
LscpNode(java.lang.String name)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, boolean endOfACommand)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, boolean endOfACommand, boolean hasParameters)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, LscpNode child)
          Creates a new instance of LscpNode with the specified child wich is not an end of a command.
LscpNode(java.lang.String name, LscpNode[] children)
          Creates a new instance of LscpNode with the specified children which are not end of a command.
LscpNode(java.lang.String name, LscpNode[] children, boolean endOfACommand)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, LscpNode[] children, boolean endOfACommand, boolean hasParameters)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, LscpNode child, boolean endOfACommand)
          Creates a new instance of LscpNode.
LscpNode(java.lang.String name, LscpNode child, boolean endOfACommand, boolean hasParameters)
          Creates a new instance of LscpNode.
 
Method Summary
 LscpNode[] getChildren()
          Gets the children nodes of this node.
 java.lang.String getName()
          Gets the name of this node.
 boolean hasParameters()
          Determines whether the command represented by this path has one or more parameters.
 boolean isEndOfACommand()
          Determines whether this node is last keyword of a command.
 void setChildren(LscpNode[] children)
          Sets the children nodes of this node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LscpNode

public LscpNode(java.lang.String name)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.

LscpNode

public LscpNode(java.lang.String name,
                boolean endOfACommand)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
endOfACommand - Determines whether this node can be an end of a command.

LscpNode

public LscpNode(java.lang.String name,
                boolean endOfACommand,
                boolean hasParameters)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
endOfACommand - Determines whether this node can be an end of a command.
hasParameters - When the node is an end of a command, determines whether the command has one or more parameters.

LscpNode

public LscpNode(java.lang.String name,
                LscpNode[] children)
Creates a new instance of LscpNode with the specified children which are not end of a command.

Parameters:
name - The name of the node.
children - The children nodes of this node.

LscpNode

public LscpNode(java.lang.String name,
                LscpNode[] children,
                boolean endOfACommand)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
children - The children nodes of this node.
endOfACommand - Determines whether this node can be an end of a command.

LscpNode

public LscpNode(java.lang.String name,
                LscpNode[] children,
                boolean endOfACommand,
                boolean hasParameters)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
children - The children nodes of this node.
endOfACommand - Determines whether this node can be an end of a command.
hasParameters - When the node is an end of a command, determines whether the command has one or more parameters.
See Also:
isEndOfACommand()

LscpNode

public LscpNode(java.lang.String name,
                LscpNode child)
Creates a new instance of LscpNode with the specified child wich is not an end of a command.

Parameters:
name - The name of the node.
child - The child node of this node.

LscpNode

public LscpNode(java.lang.String name,
                LscpNode child,
                boolean endOfACommand)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
child - The child node of this node.
endOfACommand - Determines whether this node can be an end of a command.

LscpNode

public LscpNode(java.lang.String name,
                LscpNode child,
                boolean endOfACommand,
                boolean hasParameters)
Creates a new instance of LscpNode.

Parameters:
name - The name of the node.
child - The child node of this node.
endOfACommand - Determines whether this node can be an end of a command.
hasParameters - When the node is an end of a command, determines whether the command has one or more parameters.
Method Detail

getName

public java.lang.String getName()
Gets the name of this node.

Returns:
The name of this node.

getChildren

public LscpNode[] getChildren()
Gets the children nodes of this node.

Returns:
The children nodes of this node.

setChildren

public void setChildren(LscpNode[] children)
Sets the children nodes of this node.

Parameters:
children - The new children nodes of this node.

isEndOfACommand

public boolean isEndOfACommand()
Determines whether this node is last keyword of a command. Note that this method doesn't determine whether this node is a leaf (example: RESET and RESET CHANNEL commands).

Returns:
true if this node can be an end of a command, false otherwise.

hasParameters

public boolean hasParameters()
Determines whether the command represented by this path has one or more parameters. Do not trust this method when this node is not an end of a command.

See Also:
isEndOfACommand()

JSampler
v0.8a

Copyright © 2007 Grigor Iliev. All rights reserved.