story.scheherazade.parameters
Class SCHArguments

java.lang.Object
  extended by story.scheherazade.parameters.SCHArguments
All Implemented Interfaces:
CloneableObject, RenderableObject

public class SCHArguments
extends java.lang.Object
implements RenderableObject, CloneableObject

A Scheherazade-specific vector of objects that are to be interpeted as arguments by an SCHParameterSet


Field Summary
static SCHArguments EMPTY
           
 
Constructor Summary
SCHArguments()
          Constructor with no arguments.
SCHArguments(java.lang.Object argument0)
          Constructor with one argument.
SCHArguments(java.lang.Object argument0, java.lang.Object argument1)
          Constructor with two arguments.
SCHArguments(java.lang.Object argument0, java.lang.Object argument1, java.lang.Object argument2)
          Constructor with three arguments.
SCHArguments(java.lang.Object argument0, java.lang.Object argument1, java.lang.Object argument2, java.lang.Object argument3)
          Constructor with four arguments.
 
Method Summary
 void addArg(java.lang.Object argument)
           
 void append(SCHArguments other)
           
 void checkArgType(java.lang.Object argument)
          Filter the kinds of objects that can go into an SCHArguments to avoid comparatively confusing DBCORE bad-argument errors later on
 boolean containsID(GenericScheherID target)
          Determines if the arguments inlcude a particular GenericScheherID.
 java.util.Enumeration elements()
          Returns an enumeration of the arguments
 java.lang.Object get(int index)
          Returns a particular argument.
 java.util.Vector getVectorCopy()
          Get a copy of the elements in the ArgumentVector as a Vector.
 void insertArg(int index, java.lang.Object argument)
          Insert an argument.
 SCHArguments makeClone()
           
 void remove(int index)
          Remove an argument.
 void removeFirstElements(int elementsToRemove)
          Shift the vector, removing elements at the front.
 java.lang.StringBuffer render()
          Render the argument vector to a StringBuffer.
 java.lang.StringBuffer render(int startIndex)
          Render the argument vector to a StringBuffer starting at a certain element.
 void replaceArg(int index, java.lang.Object argument)
          Replace an argument.
 int size()
          Return the number of arguments
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMPTY

public static final SCHArguments EMPTY
Constructor Detail

SCHArguments

public SCHArguments()
Constructor with no arguments.


SCHArguments

public SCHArguments(java.lang.Object argument0)
             throws Scheherexception
Constructor with one argument.

Throws:
Scheherexception

SCHArguments

public SCHArguments(java.lang.Object argument0,
                    java.lang.Object argument1)
             throws Scheherexception
Constructor with two arguments.

Throws:
Scheherexception

SCHArguments

public SCHArguments(java.lang.Object argument0,
                    java.lang.Object argument1,
                    java.lang.Object argument2)
             throws Scheherexception
Constructor with three arguments.

Throws:
Scheherexception

SCHArguments

public SCHArguments(java.lang.Object argument0,
                    java.lang.Object argument1,
                    java.lang.Object argument2,
                    java.lang.Object argument3)
             throws Scheherexception
Constructor with four arguments.

Throws:
Scheherexception
Method Detail

checkArgType

public void checkArgType(java.lang.Object argument)
                  throws Scheherexception
Filter the kinds of objects that can go into an SCHArguments to avoid comparatively confusing DBCORE bad-argument errors later on

Throws:
Scheherexception

addArg

public void addArg(java.lang.Object argument)
            throws Scheherexception
Throws:
Scheherexception

append

public void append(SCHArguments other)
            throws Scheherexception
Throws:
Scheherexception

makeClone

public SCHArguments makeClone()
                       throws Scheherexception
Specified by:
makeClone in interface CloneableObject
Throws:
Scheherexception

removeFirstElements

public void removeFirstElements(int elementsToRemove)
                         throws Scheherexception
Shift the vector, removing elements at the front.

Throws:
Scheherexception

getVectorCopy

public java.util.Vector getVectorCopy()
Get a copy of the elements in the ArgumentVector as a Vector.


elements

public java.util.Enumeration elements()
Returns an enumeration of the arguments


insertArg

public void insertArg(int index,
                      java.lang.Object argument)
               throws Scheherexception
Insert an argument.

Throws:
Scheherexception

remove

public void remove(int index)
            throws Scheherexception
Remove an argument.

Throws:
Scheherexception

replaceArg

public void replaceArg(int index,
                       java.lang.Object argument)
                throws Scheherexception
Replace an argument.

Throws:
Scheherexception

get

public java.lang.Object get(int index)
                     throws Scheherexception
Returns a particular argument.

Throws:
Scheherexception

render

public java.lang.StringBuffer render()
                              throws Scheherexception
Render the argument vector to a StringBuffer.

Specified by:
render in interface RenderableObject
Throws:
Scheherexception

render

public java.lang.StringBuffer render(int startIndex)
                              throws Scheherexception
Render the argument vector to a StringBuffer starting at a certain element.

Throws:
Scheherexception

size

public int size()
Return the number of arguments


containsID

public boolean containsID(GenericScheherID target)
                   throws Scheherexception
Determines if the arguments inlcude a particular GenericScheherID.

Throws:
Scheherexception


Copyright © 2011 David K. Elson. All Rights Reserved.