edu.swri.swiftvis.filters
Class MovieFilter

java.lang.Object
  extended by edu.swri.swiftvis.filters.AbstractSingleSourceFilter
      extended by edu.swri.swiftvis.filters.MovieFilter
All Implemented Interfaces:
DataSink, DataSource, Filter, GraphElement, java.io.Serializable

public class MovieFilter
extends AbstractSingleSourceFilter

This filter is designed so that people can easily view many "slices" through a given dimension of a

See Also:
Serialized Form

Nested Class Summary
private  class MovieFilter.SliderFrame
           
 
Field Summary
private  DataFormula groupFormula
           
private  int numElements
           
private  EditableInt numToAdvance
           
private  EditableInt numToTake
           
private  EditableInt pauseLength
           
private static long serialVersionUID
           
private  MovieFilter.SliderFrame sliderFrame
           
private  int startToTake
           
private  EditableBoolean useGroups
           
 
Fields inherited from class edu.swri.swiftvis.filters.AbstractSingleSourceFilter
bounds, changed, dataVect, input, propPanel, sinkVector
 
Constructor Summary
  MovieFilter()
           
private MovieFilter(MovieFilter c, java.util.List<GraphElement> l)
           
 
Method Summary
private  void checkNumToAdvance()
           
private  void checkNumToTake()
           
 MovieFilter copy(java.util.List<GraphElement> l)
           
private  int doGroupSelection(int startIndex, int maxIndex, DataFormula sortFormula)
          Returns the elements after the group that begins at startIndex.
 java.lang.String getDescription()
           
 DataElement getElement(int i)
          Returns the specified data element for this source.
 int getNumElements()
          Returns the number of data elements that this source has in it.
 int getNumParameters()
           
 int getNumValues()
           
 java.lang.String getParameterDescription(int which)
          Tells you what a particular parameter is used for.
 java.lang.String getParameterName(int which, int paramVal)
          Tells you the text that should be used to describe a particular value of a given parameter.
static java.lang.String getTypeDescription()
           
 java.lang.String getValueDescription(int which)
          Tells you what a particular value is used for.
protected  void redoAllElements()
          This method is intended to reprocess all the input elements to redo the output.
protected  void setupSpecificPanelProperties()
          This method should add any tabbed panes to the propPanel that are specific to the given filter.
private  void showSlider()
           
 void sourceAltered(DataSource source)
           
 boolean useParameterNameString(int which)
          If this returns true then the value of a parameter for this type should be listed as the strong value returned by getParameterName.
 
Methods inherited from class edu.swri.swiftvis.filters.AbstractSingleSourceFilter
abstractRedoAllElements, addInput, addOutput, clearData, getBounds, getNumOutputs, getNumSources, getOutput, getOutputInfoPanel, getPaint, getPropertiesPanel, getSource, getSourceInfoPanel, relink, removeInput, removeOutput, setBounds, validInput
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

numToTake

private EditableInt numToTake

numToAdvance

private EditableInt numToAdvance

useGroups

private EditableBoolean useGroups

groupFormula

private DataFormula groupFormula

pauseLength

private EditableInt pauseLength

startToTake

private int startToTake

numElements

private int numElements

sliderFrame

private transient MovieFilter.SliderFrame sliderFrame

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values
Constructor Detail

MovieFilter

public MovieFilter()

MovieFilter

private MovieFilter(MovieFilter c,
                    java.util.List<GraphElement> l)
Method Detail

getDescription

public java.lang.String getDescription()

getTypeDescription

public static java.lang.String getTypeDescription()

sourceAltered

public void sourceAltered(DataSource source)
Specified by:
sourceAltered in interface DataSink
Overrides:
sourceAltered in class AbstractSingleSourceFilter

setupSpecificPanelProperties

protected void setupSpecificPanelProperties()
Description copied from class: AbstractSingleSourceFilter
This method should add any tabbed panes to the propPanel that are specific to the given filter. This is called when the propPanel is created. After it is called, the source and output info panels are added.

Specified by:
setupSpecificPanelProperties in class AbstractSingleSourceFilter

getParameterDescription

public java.lang.String getParameterDescription(int which)
Tells you what a particular parameter is used for.


useParameterNameString

public boolean useParameterNameString(int which)
If this returns true then the value of a parameter for this type should be listed as the strong value returned by getParameterName. Otherwise just the number should be displayed.


getParameterName

public java.lang.String getParameterName(int which,
                                         int paramVal)
Tells you the text that should be used to describe a particular value of a given parameter.


getValueDescription

public java.lang.String getValueDescription(int which)
Tells you what a particular value is used for.


getNumParameters

public int getNumParameters()

getNumValues

public int getNumValues()

getElement

public DataElement getElement(int i)
Description copied from interface: DataSource
Returns the specified data element for this source. I'm using this instead of an iterator because direct access is much more efficient when trying to make tables of data.

Specified by:
getElement in interface DataSource
Overrides:
getElement in class AbstractSingleSourceFilter
Parameters:
i - Which data element to return. Should be between 0 and getNumElements()-1.
Returns:
The selected element.

getNumElements

public int getNumElements()
Returns the number of data elements that this source has in it. I'm using this instead of an iterator because direct access is much more efficient when trying to make tables of data.

Specified by:
getNumElements in interface DataSource
Overrides:
getNumElements in class AbstractSingleSourceFilter
Returns:
The number of data elements in this source.

copy

public MovieFilter copy(java.util.List<GraphElement> l)

redoAllElements

protected void redoAllElements()
Description copied from class: AbstractSingleSourceFilter
This method is intended to reprocess all the input elements to redo the output. It must be properly implemented by all extending classes.

Specified by:
redoAllElements in class AbstractSingleSourceFilter

doGroupSelection

private int doGroupSelection(int startIndex,
                             int maxIndex,
                             DataFormula sortFormula)
Returns the elements after the group that begins at startIndex.

Parameters:
startIndex - The index to start the group at.
Returns:
The index of the first element not in the group.

showSlider

private void showSlider()

checkNumToTake

private void checkNumToTake()

checkNumToAdvance

private void checkNumToAdvance()