|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.Observable
ncsa.d2k.core.modules.RootModule
ncsa.d2k.core.modules.ConfigurableModule
ncsa.d2k.core.modules.EmbeddedPipeModule
ncsa.d2k.core.modules.ExecModule
ncsa.d2k.core.modules.IOModule
ncsa.d2k.core.modules.InputModule
org.imirsel.m2k.io.InputSignalArrays
Reads in one or more files or directories of files and outputs them as Signal objects. This module has support for the streaming out of mutiple directories, directory recursion and can set classname metadata in the Signal objects with classnames calculated from the directory names, the top-level directories of a directory structure or classnames set manually. This module can also read its settings in from a file and and can save anual settings ot to a file.
| Field Summary |
| Fields inherited from class ncsa.d2k.core.modules.ConfigurableModule |
addedInputInfo, addedInputNames, addedInputTypes, addedOutputInfo, addedOutputNames, addedOutputTypes, addPortListeners |
| Fields inherited from class ncsa.d2k.core.modules.RootModule |
alias, children, DEBUG_LEVEL, EMPTY_INPUT, ERROR_LEVEL, executionManager, FATAL_LEVEL, HAVE_INPUT, INFO_LEVEL, iPipes, iPipesIndex, iTriggers, oPipes, oPipesIndex, oTriggers, parents, pipesFullManager, stats, triggerChildren, triggerParents, WARN_LEVEL |
| Fields inherited from interface ncsa.d2k.core.modules.SystemModule |
BLOCKED_STATE, IDLE_STATE, MEDIUM, MEDIUM_RARE, MEDIUM_WELL, RARE, READY_STATE, WELL, WORKING_STATE |
| Constructor Summary | |
InputSignalArrays()
Initialise InputSignals module |
|
| Method Summary | |
void |
addToVectors(java.lang.String filename,
java.lang.String className,
boolean recurseSubDirs,
java.lang.String substringFileFilter,
java.lang.String excludeFileFilter,
java.lang.String getNamesFrom)
Adds a full set of file input data (one record) to the storage vectors, ready to produce the list of files to output. |
void |
beginExecution()
Performs operations at the beginning of itinerary execution. |
void |
doit()
Reads in one or more files or directories of files and outputs them as Signal objects. |
void |
endExecution()
Performs operations at the end of itinerary execution. |
java.lang.String |
getInputInfo(int i)
Returns a text description for the indicated input. |
java.lang.String[] |
getInputTypes()
Returns an array of strings containing the Java data types of the input. |
java.lang.String |
getModuleInfo()
Returns information about the module. |
java.lang.String |
getModuleName()
Returns the name of the module. |
java.lang.String |
getOutputInfo(int i)
Returns a text description for the given output. |
java.lang.String |
getOutputName(int i)
Returns a text name for the given output. |
java.lang.String[] |
getOutputTypes()
Returns an array of strings containing the Java data types of the outputs. |
ncsa.d2k.core.modules.PropertyDescription[] |
getPropertiesDescriptions()
Returns an array of description objects for each property of the Module. |
java.lang.String |
getPropertiesFile()
Returns the value of myStringParameter |
ncsa.d2k.core.modules.CustomModuleEditor |
getPropertyEditor()
Return the custom property editor. |
boolean |
getUsePropertiesFile()
Returns the value of myStringParameter |
boolean |
isReady()
Returns a boolean indicating if the module is ready to execute or not. |
void |
readParameterFile(java.io.File pFile)
Read input file parameter settings from a file. |
void |
removeFromVectors(int i)
Removes a full set of file input data (one record) from the storage vectors. |
void |
setPropertiesFile(java.lang.String value)
Sets the value of myStringParameter |
void |
setUsePropertiesFile(boolean value)
Sets the value of myStringParameter |
void |
writePropertiesFile(java.lang.String fileName)
Write the current settings to an ascii property file |
| Methods inherited from class ncsa.d2k.core.modules.ExecModule |
execute, setExecutionManager |
| Methods inherited from class ncsa.d2k.core.modules.ConfigurableModule |
addAddPortListener, addInput, addInputTrigger, addOutput, addOutputTrigger, getAddedInputTypes, getAddedOutputTypes, getAddPortListeners, insertInput, insertOutput, removeAddPortListener, removeInput, removeInputTrigger, removeOutput, removeOutputTrigger, setAddedInputTypes, setInputType, setOutputType |
| Methods inherited from class ncsa.d2k.core.modules.RootModule |
activateTriggers, begin, canRun, clone, debug, debug, disconnectInputPipe, disconnectInputTriggers, disconnectOutputPipe, disconnectOutputTriggers, end, error, error, fatal, fatal, fetchInputs, getAlias, getChildIndex, getChildMux, getChildren, getExecutionManager, getFile, getFlags, getFullPipeManager, getGuiComponent, getImage, getInputName, getInputPipes, getInputPipeSize, getInputTriggers, getModuleStatistics, getNumInputs, getNumOutputs, getOutputCounts, getOutputPipes, getOutputPipeSize, getOutputTriggers, getParentIndex, getParentMux, getParents, getPipesFull, getPriority, getResource, getRootName, getState, info, info, initModule, isAborting, isHead, isInputPipeConnected, isOutputPipeConnected, pullInput, pushOutput, resetInputs, setAlias, setBlocked, setD2KModulesLoggingLevel, setFlags, setFullPipeManager, setIdle, setInputPipe, setLogLevel, setModuleStatistics, setModuleStatisticsByMachine, setOutputCounts, setOutputPipe, setPipesFull, setReady, setResource, setState, setThePriority, setWorking, trigger, triggersActivated, warn, warn |
| Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public InputSignalArrays()
| Method Detail |
public void addToVectors(java.lang.String filename,
java.lang.String className,
boolean recurseSubDirs,
java.lang.String substringFileFilter,
java.lang.String excludeFileFilter,
java.lang.String getNamesFrom)
filename - File or directory path to addclassName - If using manual classnames, the classname to be used, otherwise should be empty StringrecurseSubDirs - boolean flag indicating whether a directory should be recursed for files or
whether only the toplevel files should be returned.substringFileFilter - Require this substring to be in returned filenamesexcludeFileFilter - exclude fileames with this substringgetNamesFrom - String flag indicating where classnames should come from. Set to "dir", if the
directory name is to be used, "topLevelDirs" if the top-level of a directory
structure is to be used or "manual" if a manually set classname is to be used.public void removeFromVectors(int i)
i - The index of the record to remove.
public void writePropertiesFile(java.lang.String fileName)
throws java.io.IOException
fileName - The filename to write the file to
java.io.IOException - Thrown if an IO error occurs while writing to file, indicates file writing was
unsuccessful.public void readParameterFile(java.io.File pFile)
pFile - The file to read the settings frompublic void setPropertiesFile(java.lang.String value)
value - the value which myStringParameter is set topublic java.lang.String getPropertiesFile()
public void setUsePropertiesFile(boolean value)
value - the value which myStringParameter is set topublic boolean getUsePropertiesFile()
public ncsa.d2k.core.modules.PropertyDescription[] getPropertiesDescriptions()
public java.lang.String getModuleName()
public java.lang.String getModuleInfo()
public java.lang.String[] getInputTypes()
public java.lang.String getInputInfo(int i)
i - the index of the input
public java.lang.String getOutputName(int i)
i - the index of the output
public java.lang.String getOutputInfo(int i)
i - the index of the output
public java.lang.String[] getOutputTypes()
public void beginExecution()
endExecution()public void endExecution()
beginExecution()public boolean isReady()
public ncsa.d2k.core.modules.CustomModuleEditor getPropertyEditor()
public void doit()
throws java.io.IOException,
noMetadataException
java.io.IOException - Thrown if there is a problem reading from disk, may occur if it tries to read a
properties file that does not exist.
noMetadataException - Thrown if class metadata wasn't set correctly, shouldn't occur
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||