edu.mayo.bsi.ngsportal.shared
Class SGEScriptSummary

java.lang.Object
  extended by edu.mayo.bsi.ngsportal.shared.SGEScriptSummary
All Implemented Interfaces:
com.google.gwt.user.client.rpc.IsSerializable

public class SGEScriptSummary
extends Object
implements com.google.gwt.user.client.rpc.IsSerializable

SGEScriptSummary encapsulates information about script usage for RPC data transfer.

Author:
m102772

Constructor Summary
SGEScriptSummary(int size, String name)
          Creates a new SGEScriptSummary of the specified size and name.
SGEScriptSummary(String name, Long value)
          Creates a new SGEScriptSummary holding only one value
 
Method Summary
 String getLabel(int column)
           
 int getLength()
           
 String getScriptName()
           
 Long getValue()
           
 Long getValue(int index)
          Gets the value in the enclosed array of script values
 boolean hasLabels()
           
 void setLabel(int column, String newLabel)
          Sets a label for the value at the position provided
 void setValue(int index, Long value)
          Sets the value at a particular index for script summaries holding multiple values
 void setValue(Long value)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SGEScriptSummary

public SGEScriptSummary(int size,
                        String name)
Creates a new SGEScriptSummary of the specified size and name.

Parameters:
size - how many values to store
name - the title of the script

SGEScriptSummary

public SGEScriptSummary(String name,
                        Long value)
Creates a new SGEScriptSummary holding only one value

Parameters:
name - of this summary
value - Long value to store
Method Detail

getScriptName

public String getScriptName()
Returns:
String containing the name of the script

getValue

public Long getValue()
Returns:
Long the first value stored for this script

setValue

public void setValue(Long value)
Parameters:
value - the value to set

setValue

public void setValue(int index,
                     Long value)
Sets the value at a particular index for script summaries holding multiple values

Parameters:
index -
value -

getValue

public Long getValue(int index)
Gets the value in the enclosed array of script values

Parameters:
index -
Returns:
Long

getLength

public int getLength()
Returns:
int the length of the enclosed array of script values

setLabel

public void setLabel(int column,
                     String newLabel)
Sets a label for the value at the position provided

Parameters:
column - integer index of the enclosed array
newLabel - String description

hasLabels

public boolean hasLabels()
Returns:
true if the enclosed values are labeled

getLabel

public String getLabel(int column)
Parameters:
column - the array index of the enclosed value being queried
Returns:
String label of the provided column