|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.rapidminer.tools.AbstractObservable<ProcessContext>
com.rapidminer.ProcessContext
public class ProcessContext
The process context holds some data controlling the execution of a Process
.
This includes connections of the input and output ports of the root operator
to repository locations as well as the definition of macros.
The fact that this data is defined outside the process itself is particularly useful if this process is offered as a service, so it can be adapted easily. Furthermore, this saves the process designer from defining data reading and storing operators at the beginning and at the end of the process.
Note: A ProcessContext is not necessarily associate with a Process
. E.g., if a process
is run remotely, it does not necessarily exist on the machine that prepares the context.
Since this class acts merely as a data container, it has public getter and setter methods which return references to the actual data (as opposed to immutable views). In order to trigger an update, call a setter method rather than adding to the lists, which is invisible to the process context.
The data is saved as strings rather than, e.g. using RepositoryLocation
s.
Since this class is saved as a Lob with the ProcessExecutionParameters entity, serializability must
be ensured. This is guaranteed by the fact that this class only contains List
s of
strings or Pair
s of strings, where Pair
is serializable.
Constructor Summary | |
---|---|
ProcessContext()
|
Method Summary | |
---|---|
void |
addInputLocation(java.lang.String location)
|
void |
addMacro(Pair<java.lang.String,java.lang.String> macro)
Adds a macro to the list or sets an existing one. |
void |
addOperatorLibrary(OperatorLibrary library,
java.lang.String location)
|
void |
addOutputLocation(java.lang.String location)
|
java.util.List<java.lang.String> |
getInputRepositoryLocations()
|
java.util.List<Pair<java.lang.String,java.lang.String>> |
getMacros()
|
java.util.List<OperatorLibrary> |
getOperatorLibraries()
This returns all loaded OperatorLibries that should be used within this process. |
java.util.List<java.lang.String> |
getOutputRepositoryLocations()
|
void |
removeInputLocation(int rowIndex)
|
void |
removeOutputLocation(int rowIndex)
|
void |
setInputRepositoryLocation(int index,
java.lang.String location)
|
void |
setInputRepositoryLocations(java.util.List<java.lang.String> inputRepositoryLocations)
|
void |
setMacros(java.util.List<Pair<java.lang.String,java.lang.String>> macros)
|
void |
setOutputRepositoryLocation(int index,
java.lang.String location)
|
void |
setOutputRepositoryLocations(java.util.List<java.lang.String> outputRepositoryLocations)
|
void |
superimpose(ProcessContext other)
Merges the current context with the given one. |
java.lang.String |
toString()
|
Methods inherited from class com.rapidminer.tools.AbstractObservable |
---|
addObserver, addObserverAsFirst, fireUpdate, fireUpdate, removeObserver |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ProcessContext()
Method Detail |
---|
public java.util.List<java.lang.String> getInputRepositoryLocations()
public void setInputRepositoryLocations(java.util.List<java.lang.String> inputRepositoryLocations)
public java.util.List<java.lang.String> getOutputRepositoryLocations()
public void setOutputRepositoryLocations(java.util.List<java.lang.String> outputRepositoryLocations)
public java.util.List<Pair<java.lang.String,java.lang.String>> getMacros()
public void addMacro(Pair<java.lang.String,java.lang.String> macro)
public void setMacros(java.util.List<Pair<java.lang.String,java.lang.String>> macros)
public void setOutputRepositoryLocation(int index, java.lang.String location)
public void setInputRepositoryLocation(int index, java.lang.String location)
public void removeOutputLocation(int rowIndex)
public void removeInputLocation(int rowIndex)
public void addOutputLocation(java.lang.String location)
public void addInputLocation(java.lang.String location)
public void superimpose(ProcessContext other)
public java.lang.String toString()
toString
in class java.lang.Object
public java.util.List<OperatorLibrary> getOperatorLibraries()
public void addOperatorLibrary(OperatorLibrary library, java.lang.String location)
|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |