|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.jhu.ece.iacl.jist.pipeline.PipePort<T> edu.jhu.ece.iacl.jist.pipeline.parameter.ParamModel<java.util.List> edu.jhu.ece.iacl.jist.pipeline.parameter.ParamFileCollection
public class ParamFileCollection
File collection stores a collection of files. The restrictions on the files are set to be the same as the collection.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class edu.jhu.ece.iacl.jist.pipeline.PipePort |
---|
PipePort.PortListener, PipePort.type |
Field Summary | |
---|---|
protected FileExtensionFilter |
extensionFilter
The extension filter. |
protected java.util.Vector<ParamFile> |
fileParams
The file params. |
protected boolean |
mandatory
The mandatory. |
protected FileReaderWriter |
readerWriter
The reader writer. |
Fields inherited from class edu.jhu.ece.iacl.jist.pipeline.parameter.ParamModel |
---|
cliTag, description, factory, hidden, label, loadAndSaveOnValidate, shortLabel |
Fields inherited from class edu.jhu.ece.iacl.jist.pipeline.PipePort |
---|
connectible, gport, incomingConnectors, listeners, maxIncoming, maxOutgoing, outgoingConnectors, owner, portType, useWire |
Constructor Summary | |
---|---|
ParamFileCollection()
Default constructor. |
|
ParamFileCollection(java.lang.String name)
Default constructor. |
|
ParamFileCollection(java.lang.String name,
FileExtensionFilter filter)
Constructor. |
|
ParamFileCollection(java.lang.String name,
FileReaderWriter readerWriter)
Constructor. |
Method Summary | |
---|---|
void |
add(java.io.File val)
Add file to collection. |
ParamFile |
add(java.lang.Object value)
Add a new value to the collection. |
void |
clean()
Clean resources that maybe out-of-date with the system |
void |
clear()
Remove all files from collection. |
ParamFileCollection |
clone()
Clone object. |
int |
compareTo(ParamModel model)
Compare restriction of one file collection to another. |
protected ParamFile |
create(java.lang.Object value)
Create a new ParamFile with the same restrictions as the collection and the specified value. |
FileExtensionFilter |
getExtensionFilter()
Get extension filter. |
java.lang.String |
getHumanReadableDataType()
|
java.util.List<ParamFile> |
getParameters()
Get list of parameter files. |
FileReaderWriter |
getReaderWriter()
Get File reader writer. |
java.util.List<java.io.File> |
getValue()
Get the value stored in the parameter. |
java.io.File |
getValue(int i)
Get value at specified index. |
java.lang.String |
getXMLValue()
|
void |
init()
Initialize parameter. |
boolean |
isCompatible(PipePort model)
Returns true if port is compatible with this parameter's extension filter. |
boolean |
isMandatory()
File field is mandatory. |
java.lang.String |
probeDefaultValue()
|
void |
replacePath(java.io.File originalPath,
java.io.File replacePath)
Replace path in all file type objects with this path. |
void |
set(int i,
java.io.File val)
Set item value in list |
ParamFile |
set(int i,
java.lang.Object value)
|
void |
setCollection(int index,
ObjectCollection src)
Set item value in list to the first element of the colleciton. |
void |
setExtensionFilter(FileExtensionFilter filter)
Set extension filter. |
void |
setMandatory(boolean mandatory)
Set the mandatory field. |
void |
setReaderWriter(FileReaderWriter readerWriter)
Set extension filter. |
void |
setValue(java.util.List value)
Set the file collection. |
void |
setXMLValue(java.lang.String arg)
|
int |
size()
Returns size of collection. |
java.lang.String |
toString()
Get description of volumes. |
void |
validate()
Validate that the files meet all restrictions. |
Methods inherited from class edu.jhu.ece.iacl.jist.pipeline.parameter.ParamModel |
---|
createMipavParameter, createTreeNode, dispose, equals, getCliTag, getDescription, getFactory, getInputView, getLabel, getName, getOutputView, getShortLabel, getView, hide, importMipavParameter, importParameter, isConnectible, isHidden, loadResources, loadResources, read, read, saveResources, setCliTag, setDescription, setFactory, setHidden, setInputView, setLabel, setLoadAndSaveOnValidate, setName, setOutputView, setShortLabel, toXML, write, write, writeAndFreeNow |
Methods inherited from class edu.jhu.ece.iacl.jist.pipeline.PipePort |
---|
addListener, disconnect, disconnect, disconnect, disconnect, getGraphPort, getIncomingConnector, getIncomingConnectors, getIncomingPorts, getListeners, getMaxIncoming, getMaxOutgoing, getOutgoingConnector, getOutgoingConnectors, getOutgoingPorts, getOwner, getPortType, isConnected, isConnectedTo, isInputPort, isOutputPort, notifyListenersOfConnection, notifyListenersOfDisconnection, removeAllListeners, removeListener, setConnectable, setGraphPort, setMaxIncoming, setMaxOutgoing, setOwner, setPortType, setUseConnector, usingConnector |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.util.Vector<ParamFile> fileParams
protected FileReaderWriter readerWriter
protected boolean mandatory
protected FileExtensionFilter extensionFilter
Constructor Detail |
---|
public ParamFileCollection()
public ParamFileCollection(java.lang.String name)
name
- collection namepublic ParamFileCollection(java.lang.String name, FileExtensionFilter filter)
name
- namefilter
- extension filterpublic ParamFileCollection(java.lang.String name, FileReaderWriter readerWriter)
name
- namereaderWriter
- the reader writerMethod Detail |
---|
public void add(java.io.File val)
add
in interface ObjectCollection<java.io.File>
val
- the valpublic void set(int i, java.io.File val)
ObjectCollection
set
in interface ObjectCollection<java.io.File>
i
- the indexval
- the valpublic void setCollection(int index, ObjectCollection src)
ObjectCollection
setCollection
in interface ObjectCollection<java.io.File>
public ParamFile set(int i, java.lang.Object value)
public ParamFile add(java.lang.Object value)
value
- the value
public void clear()
clear
in interface ObjectCollection<java.io.File>
public ParamFileCollection clone()
clone
in class ParamModel<java.util.List>
public int compareTo(ParamModel model)
compareTo
in interface java.lang.Comparable<ParamModel>
compareTo
in class ParamModel<java.util.List>
model
- the model
protected ParamFile create(java.lang.Object value)
value
- the value
public FileExtensionFilter getExtensionFilter()
public java.util.List<ParamFile> getParameters()
public FileReaderWriter getReaderWriter()
public java.util.List<java.io.File> getValue()
ParamModel
getValue
in class ParamModel<java.util.List>
public java.io.File getValue(int i)
ObjectCollection
getValue
in interface ObjectCollection<java.io.File>
i
- index
public void init()
init
in class PipePort<java.util.List>
public boolean isCompatible(PipePort model)
isCompatible
in class ParamModel<java.util.List>
model
- the model
public boolean isMandatory()
isMandatory
in class ParamModel<java.util.List>
public void setExtensionFilter(FileExtensionFilter filter)
filter
- filterpublic void setMandatory(boolean mandatory)
setMandatory
in class ParamModel<java.util.List>
mandatory
- the mandatorypublic void setReaderWriter(FileReaderWriter readerWriter)
readerWriter
- the reader writerpublic void setValue(java.util.List value)
setValue
in class ParamModel<java.util.List>
value
- parameter valuepublic int size()
ObjectCollection
size
in interface ObjectCollection<java.io.File>
public java.lang.String toString()
toString
in class ParamModel<java.util.List>
public void validate() throws InvalidParameterException
validate
in class ParamModel<java.util.List>
InvalidParameterException
- parameter does not meet value restrictionspublic void clean()
ParamModel
clean
in class ParamModel<java.util.List>
public void replacePath(java.io.File originalPath, java.io.File replacePath)
ParamModel
replacePath
in class ParamModel<java.util.List>
public java.lang.String getHumanReadableDataType()
getHumanReadableDataType
in class ParamModel<java.util.List>
public java.lang.String getXMLValue()
getXMLValue
in class ParamModel<java.util.List>
public void setXMLValue(java.lang.String arg)
setXMLValue
in class ParamModel<java.util.List>
public java.lang.String probeDefaultValue()
probeDefaultValue
in class ParamModel<java.util.List>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |