| org.griphyn.vdl.classes.VDL org.griphyn.vdl.classes.Call
Call | public class Call extends VDL implements HasPass,Serializable(Code) | | Call is an implementation of an anonymous
Derivation . A call describes the mutable part
concerning input, processing, and output (IPO). Calls can
only be part of a CompoundTransformation .
A call parametrizes the template provided by a
Transformation with actual values. Think of a call
as something akin to a C function call. The call provides the
actual parameter to a job. The immutable parts are hidden in a
Transformation .
FIXME: A Call is essentially an anonymous
Derivation that occurs within a
CompoundTransformation . Thus, the first two should
share code. Also, the latter two already share code. Therefore,
the class hierarchies need to be re-designed, and attribute groups
should be out-sourced.
author: Jens-S. Vöckler author: Yong Zhao version: $Revision $ See Also: Definition See Also: Definitions See Also: Transformation See Also: See Also: Derivation See Also: |
Constructor Summary | |
public | Call() ctor. | public | Call(String uses) | public | Call(String uses, String min, String max) Convenience ctor: Supplies the used Transformation
as well as the permissable version range. |
Method Summary | |
public void | addPass(Pass vPass) Accessor: Adds an actual argument to the bag of arguments. | public boolean | containsLFN(String filename, int linkage) Determines if the list contains an LFN of the specified linkage.
The logic uses short-circuit evaluation, thus finding things is
faster than not finding things. | public Enumeration | enumeratePass() Accessor: Provides an iterator for the bag of actual arguments. | public java.util.List | getLFNList(int linkage) Determines all LFN instances of a given scalar that match the
specified linkage. | public String | getMaxIncludeVersion() Accessor: Obtains the maximum inclusive version permissable for
binding to a
Transformation . | public String | getMinIncludeVersion() Accessor: Obtains the minimum inclusive version permissable for
binding to a
Transformation . | public Pass | getPass(String name) Accessor: Obtains an actual argument identified by the bound variable.
Parameters: name - is the binding name. | public Pass[] | getPass() Accessor: Obtains the bag of actual arguments as array. | public int | getPassCount() Accessor: Counts the number of actual arguments. | public java.util.List | getPassList() Accessor: Gets an array of all values that constitute the current
content. | public java.util.Map | getPassMap() Accessor: Obtains all actual arguments. | public java.lang.String | getUses() Accessor: Obtains the name of the logical
Transformation
that this call refers to. | public java.lang.String | getUsesspace() Accessor: Obtains the namespace of the logical
Transformation
that this call refers to. | public String | identify() | public Iterator | iteratePass() Accessor: Provides an iterator for the bag of actual arguments. | public boolean | match(String version) Instance method for matching an external version against the inclusive
version range.
Parameters: version - is an externally supplied version to be checked,if it is within the inclusive interval of min and max. | public void | removeAllPass() Accessor: Removes all actual arguments. | public Pass | removePass(String name) Accessor: Removes a specific actual argument. | public void | setMaxIncludeVersion(String miv) Accessor: Sets the maximum inclusive permissable version of
a logical transformation to run with. | public void | setMinIncludeVersion(String miv) Accessor: Sets the minimum inclusive permissable version of
a logical transformation to run with. | public void | setPass(Pass vPass) Accessor: Adds a new or overwrites an existing actual argument. | public void | setPass(Pass[] passArray) Accessor: Replaces the bag of actual argument with new arguments. | public void | setPass(Collection passes) Accessor: Replaces the bag of actual argument with a bag of
new arguments. | public void | setPass(Map passes) Accessor: Replaces the bag of actual argument with a map of
new arguments. | public void | setUses(String uses) Accessor: Sets a new name for a logical Transformation
to call. | public void | setUsesspace(String usesspace) Accessor: Sets a new namespace identifier for a logical
Transformation to call. | public String | shortID() Generates a pseudo id for this Call. | public void | toString(Writer stream) Dumps the content of the given element into a string. | public void | toXML(Writer stream, String indent, String namespace) Dump the state of the current element as XML output. |
Call | public Call(String uses)(Code) | | Convenience ctor: Names the used Transformation
Parameters: uses - is the name of the Transformation See Also: Transformation |
Call | public Call(String uses, String min, String max)(Code) | | Convenience ctor: Supplies the used Transformation
as well as the permissable version range.
Parameters: uses - is the name of the Transformation . Parameters: min - is the minimum inclusive permissable version. Parameters: max - is the maximum inclusive permissable version. See Also: Transformation |
addPass | public void addPass(Pass vPass)(Code) | | Accessor: Adds an actual argument to the bag of arguments.
Parameters: vPass - is the new actual argument to add. See Also: Pass |
containsLFN | public boolean containsLFN(String filename, int linkage)(Code) | | Determines if the list contains an LFN of the specified linkage.
The logic uses short-circuit evaluation, thus finding things is
faster than not finding things. Searching a list is a potentially
expensive method.
Parameters: filename - is the name of the LFN Parameters: linkage - is the linkage to check for, -1 for any linkage type. true if the LFN is contained in the scalar, false otherwise. See Also: Value.containsLFN(Stringint) See Also: LFN |
getLFNList | public java.util.List getLFNList(int linkage)(Code) | | Determines all LFN instances of a given scalar that match the
specified linkage. This is a higher-level method employing the
given API. Note that also linkage of NONE will not be found in
wildcard search mode.
Parameters: linkage - is the linkage to check for, -1 for any linkage. a set of all logical filenames that match the linkage andwere part of the scalar. The result may be an empty set, if no suchresult were to be found. For a linkage of -1, complete LFNs will bereturned, for any other linkage, just the filename will bereturned. See Also: Value.getLFNList(int) See Also: LFN |
getPass | public Pass getPass(String name)(Code) | | Accessor: Obtains an actual argument identified by the bound variable.
Parameters: name - is the binding name. the bound value to the given name. See Also: Pass |
getPass | public Pass[] getPass()(Code) | | Accessor: Obtains the bag of actual arguments as array. Note that the
order is arbitrary.
an array containing all bound variables. See Also: Pass |
getPassCount | public int getPassCount()(Code) | | Accessor: Counts the number of actual arguments.
the number of actual arguments in the internal bag. |
getPassList | public java.util.List getPassList()(Code) | | Accessor: Gets an array of all values that constitute the current
content. This list is read-only.
an array with Pass elements. See Also: Pass |
getPassMap | public java.util.Map getPassMap()(Code) | | Accessor: Obtains all actual arguments. The map is a read-only
map to avoid modifications outside the API.
a map will all actual arguments. See Also: Pass |
identify | public String identify()(Code) | | Since calls are anonymous derivations, this function can only
construct the mapped transformation
a string describing the call |
iteratePass | public Iterator iteratePass()(Code) | | Accessor: Provides an iterator for the bag of actual arguments.
an iterator to walk the Pass list with. See Also: Pass |
match | public boolean match(String version)(Code) | | Instance method for matching an external version against the inclusive
version range.
Parameters: version - is an externally supplied version to be checked,if it is within the inclusive interval of min and max. true, if the version is in range, false otherwise. See Also: Derivation.match(StringStringString) |
removeAllPass | public void removeAllPass()(Code) | | Accessor: Removes all actual arguments. Effectively empties the bag.
|
removePass | public Pass removePass(String name)(Code) | | Accessor: Removes a specific actual argument.
Parameters: name - is the bound variable name of the argument to remove. the object that was removed, or null, if not found. See Also: Pass |
setMaxIncludeVersion | public void setMaxIncludeVersion(String miv)(Code) | | Accessor: Sets the maximum inclusive permissable version of
a logical transformation to run with.
Parameters: miv - is the (new) maximum inclusive version. See Also: Call.getMaxIncludeVersion() |
setMinIncludeVersion | public void setMinIncludeVersion(String miv)(Code) | | Accessor: Sets the minimum inclusive permissable version of
a logical transformation to run with.
Parameters: miv - is the (new) minimum inclusive version. See Also: Call.getMinIncludeVersion() |
setPass | public void setPass(Pass vPass)(Code) | | Accessor: Adds a new or overwrites an existing actual argument.
Parameters: vPass - is a new actual argument with bound name and value. See Also: Pass |
setPass | public void setPass(Pass[] passArray)(Code) | | Accessor: Replaces the bag of actual argument with new arguments.
Parameters: passArray - is the new actual argument list. See Also: Pass |
setPass | public void setPass(Collection passes)(Code) | | Accessor: Replaces the bag of actual argument with a bag of
new arguments.
Parameters: passes - is the new actual argument collection. See Also: Pass |
setPass | public void setPass(Map passes)(Code) | | Accessor: Replaces the bag of actual argument with a map of
new arguments.
Parameters: passes - is the new actual argument map. See Also: Pass |
setUses | public void setUses(String uses)(Code) | | Accessor: Sets a new name for a logical Transformation
to call.
Parameters: uses - is the new name of the Transformation to use. See Also: Call.getUses() See Also: Transformation |
setUsesspace | public void setUsesspace(String usesspace)(Code) | | Accessor: Sets a new namespace identifier for a logical
Transformation to call.
Parameters: usesspace - is the new namespace of theTransformation . See Also: Call.getUsesspace() See Also: Transformation |
shortID | public String shortID()(Code) | | Generates a pseudo id for this Call.
FIXME: With the advent of a database, we'll need to fix this to
something like the primary key.
|
toString | public void toString(Writer stream) throws IOException(Code) | | Dumps the content of the given element into a string. This function
traverses all sibling classes as necessary and converts the
data into textual output. Note that order of the actual arguments
is not preserved.
Parameters: stream - is a stream opened and ready for writing. This can alsobe a string stream for efficient output. exception: IOException - if something fishy happens to the stream. |
toXML | public void toXML(Writer stream, String indent, String namespace) throws IOException(Code) | | Dump the state of the current element as XML output. This function
traverses all sibling classes as necessary, and converts the data
into pretty-printed XML output. The stream interface should be able
to handle large output efficiently, if you use a buffered writer.
Parameters: stream - is a stream opened and ready for writing. This can alsobe a string stream for efficient output. Parameters: indent - is a String of spaces used for prettyprinting. The initial amount of spaces should be an empty string.The parameter is used internally for the recursive traversal.If a null value is specified, no indentation norlinefeeds will be generated. Parameters: namespace - is the XML schema namespace prefix. If neitherempty nor null, each element will be prefixed with this prefix,and the root element will map the XML namespace. See Also: org.griphyn.vdl.Chimera.writeAttribute(WriterStringString) exception: IOException - if something fishy happens to the stream. |
|
|