org.joone.io
Class XLSOutputSynapse
- java.lang.Object
-
- org.joone.engine.Synapse
-
- org.joone.io.StreamOutputSynapse
-
- org.joone.io.XLSOutputSynapse
-
- All Implemented Interfaces:
- java.io.Serializable, InputPatternListener, Learnable, LearnableSynapse, NeuralElement, OutputPatternListener, Inspectable, PlugInListener
public class XLSOutputSynapse extends StreamOutputSynapse
This class allows data to be read from an Excel XLS formatted file. The class requires the specification of a file name and a worksheet name is optional.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description XLSOutputSynapse()The default constructor for this XLSOutputSynapse.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.util.TreeSetcheck()Checks and returns any problems found with the settings of this synapse.voidflush()Write any remaining data to the XLS file.java.lang.String[]getAvailableSheetList()Obtains a list of available sheet names from the XLS file.java.lang.StringgetFileName()Returns the XLS file name used by this synapse.java.lang.StringgetSheetName()Gets the name of sheet within the XLS file that data should be written to.intgetStartCol(int startCol)Gets the starting col (0 based) of the XLS sheet.intgetStartRow(int startRow)Gets the starting row (0 based) of the XLS sheet.voidsetFileName(java.lang.String fn)Sets the XLS file name that this synapse should output data to.voidsetSheetName(java.lang.String sheetName)Sets the sheet name within the XLS file that this synapse should write data to.voidsetStartCol(int startCol)Set the starting col (0 based) of the XLS sheet.voidsetStartRow(int startRow)Set the starting row (0 based) of the XLS sheet.voidwrite(Pattern pattern)Writes a Pattern to the XLS file.-
Methods inherited from class org.joone.io.StreamOutputSynapse
addPlugIn, dataChanged, fwdPut, getPlugIn, getSeparator, isBuffered, removeAllPlugIns, revGet, setBuffered, setPlugIn, setSeparator
-
Methods inherited from class org.joone.engine.Synapse
addNoise, canCountSteps, fwdGet, getIgnoreBefore, getInputDimension, getLearner, getLearningRate, getMomentum, getMonitor, getName, getOutputDimension, getWeights, init, initLearner, InspectableTitle, Inspections, isEnabled, isInputFull, isLoopBack, isOutputFull, randomize, reset, revPut, setEnabled, setIgnoreBefore, setInputDimension, setInputFull, setLearningRate, setLoopBack, setMomentum, setMonitor, setName, setOutputDimension, setOutputFull, setWeights
-
-
-
-
Constructor Detail
-
XLSOutputSynapse
public XLSOutputSynapse()
The default constructor for this XLSOutputSynapse.
-
-
Method Detail
-
flush
public void flush()
Write any remaining data to the XLS file.
-
write
public void write(Pattern pattern)
Writes a Pattern to the XLS file.- Specified by:
writein classStreamOutputSynapse- Parameters:
pattern- The Pattern to write to the XLS file.
-
getFileName
public java.lang.String getFileName()
Returns the XLS file name used by this synapse.- Returns:
- The XLS file name used by this synapse to output data to.
-
setFileName
public void setFileName(java.lang.String fn)
Sets the XLS file name that this synapse should output data to.- Parameters:
fn- The XLS file name that this synapse should output data to.
-
setSheetName
public void setSheetName(java.lang.String sheetName)
Sets the sheet name within the XLS file that this synapse should write data to.- Parameters:
sheetName- The sheet name within the XLS file that this synapse should write data to.
-
getAvailableSheetList
public java.lang.String[] getAvailableSheetList()
Obtains a list of available sheet names from the XLS file.- Returns:
- An array of sheet names found with in the XLS file or null if the file has not been read yet.
-
getSheetName
public java.lang.String getSheetName()
Gets the name of sheet within the XLS file that data should be written to.- Returns:
- The name of sheet within the XLS file that data should be written to.
-
check
public java.util.TreeSet check()
Checks and returns any problems found with the settings of this synapse.- Specified by:
checkin interfaceNeuralElement- Overrides:
checkin classStreamOutputSynapse- Returns:
- A TreeSet of problems or errors found with this synapse.
- See Also:
InputPaternListener,OutputPaternListener
-
getStartRow
public int getStartRow(int startRow)
Gets the starting row (0 based) of the XLS sheet.- Returns:
- Starting row (0 based) of the XLS sheet.
-
getStartCol
public int getStartCol(int startCol)
Gets the starting col (0 based) of the XLS sheet.- Returns:
- Starting col (0 based) of the XLS sheet.
-
setStartRow
public void setStartRow(int startRow)
Set the starting row (0 based) of the XLS sheet.
-
setStartCol
public void setStartCol(int startCol)
Set the starting col (0 based) of the XLS sheet.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG