anl.aida.data
Class DataFrameBuilder

java.lang.Object
  extended by anl.aida.data.DataFrameBuilder

public class DataFrameBuilder
extends java.lang.Object

Builds a DataFrame from the pieces added in the add methods.

Version:
$Revision$ $Date$

Nested Class Summary
static class DataFrameBuilder.AxesBuilder
           
private static class DataFrameBuilder.BuilderDataFrame
           
 
Field Summary
private  DataFrameBuilder.AxesBuilder axesBuilder
           
private  DataFrameBuilder.BuilderDataFrame frame
           
private  java.util.Set<Dataset> sets
           
 
Constructor Summary
DataFrameBuilder()
           
 
Method Summary
 DataFrameBuilder addAxis(DataFrameAxis axis)
          Adds a DataFrameAxis to the frame that this builder is creating.
 DataFrameBuilder addDataset(java.util.Collection<Dataset> sets)
          Adds the specified Datasets to the frame that this builder is creating.
 DataFrameBuilder addDataset(Dataset set)
          Adds a Dataset to the frame that this builder is creating.
 DataFrame createDataFrame()
          Creates a DataFrame from the Datasets, Array and so forth that have been set or added to this DataFrameBuilder.
 void reset()
          Resets this DataFrameBuilder clearing any previously added Datasets and so forth.
 DataFrameBuilder setArray(ucar.ma2.Array array)
          Sets the Array contained by the DataFrame that this builder will create.
 DataFrameBuilder setVariable(Variable var)
          Sets the Variable contained by the DataFrame that this builder will create.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

frame

private DataFrameBuilder.BuilderDataFrame frame

axesBuilder

private DataFrameBuilder.AxesBuilder axesBuilder

sets

private java.util.Set<Dataset> sets
Constructor Detail

DataFrameBuilder

public DataFrameBuilder()
Method Detail

addDataset

public DataFrameBuilder addDataset(Dataset set)
Adds a Dataset to the frame that this builder is creating.

Parameters:
set - the DataSet to add.
Returns:
this DataFrameBuilder

addDataset

public DataFrameBuilder addDataset(java.util.Collection<Dataset> sets)
Adds the specified Datasets to the frame that this builder is creating.

Parameters:
sets - the DataSets to add.
Returns:
this DataFrameBuilder

setArray

public DataFrameBuilder setArray(ucar.ma2.Array array)
Sets the Array contained by the DataFrame that this builder will create.

Parameters:
array - the array for the DataFrame
Returns:
this DataFrameBuilder

setVariable

public DataFrameBuilder setVariable(Variable var)
Sets the Variable contained by the DataFrame that this builder will create.

Parameters:
var - the Variable for the DataFrame
Returns:
this DataFrameBuilder

addAxis

public DataFrameBuilder addAxis(DataFrameAxis axis)
Adds a DataFrameAxis to the frame that this builder is creating.

Parameters:
axis - the axis to add.
Returns:
this DataFrameBuilder

createDataFrame

public DataFrame createDataFrame()
Creates a DataFrame from the Datasets, Array and so forth that have been set or added to this DataFrameBuilder.

Returns:
the created DataFrame.

reset

public void reset()
Resets this DataFrameBuilder clearing any previously added Datasets and so forth.