Documentation
¶
Index ¶
- Constants
- func CreateCommandInputParameterTypeArray(v interface{}) (cipt_array_ptr *[]CommandInputParameterType, err error)
- func CreateRequirementArray(original interface{}) (new_array_ptr *[]Requirement, err error)
- func CreateWorkflowStepInputArray(original interface{}) (array_ptr *[]WorkflowStepInput, err error)
- func CreateWorkflowStepsArray(original interface{}, collection *CWL_collection) (err error, array_ptr *[]WorkflowStep)
- func EvaluateExpression(collection *CWL_collection, e cwl_types.Expression) string
- func GetMapElement(m map[interface{}]interface{}, key string) (value interface{}, err error)
- func HasCommandInputParameterType(array *[]CommandInputParameterType, search_type string) (ok bool)
- func HasInputParameterType(array *[]InputParameterType, search_type string) (ok bool)
- func NewCommandOutputParameterArray(original interface{}) (copa *[]CommandOutputParameter, err error)
- func NewCommandOutputParameterTypeArray(original interface{}) (copta *[]CommandOutputParameterType, err error)
- func NewInputParameterTypeArray(original interface{}) (array_ptr *[]InputParameterType, err error)
- func NewWorkflowOutputParameterArray(original interface{}) (new_array_ptr *[]WorkflowOutputParameter, err error)
- func NewWorkflowOutputParameterTypeArray(original interface{}) (wopta_ptr *[]WorkflowOutputParameterType, err error)
- func Parse_cwl_document(collection *CWL_collection, yaml_str string) (err error)
- func Unmarshal(data []byte, v interface{}) (err error)
- type Any
- type Boolean
- type CWLType
- type CWLType_Impl
- type CWLVersion
- type CWL_collection
- func (c CWL_collection) Add(obj CWL_object) (err error)
- func (c CWL_collection) Evaluate(raw string) (parsed string)
- func (c CWL_collection) Get(id string) (obj *CWL_object, err error)
- func (c CWL_collection) GetFile(id string) (obj *File, err error)
- func (c CWL_collection) GetInt(id string) (obj *Int, err error)
- func (c CWL_collection) GetString(id string) (obj *String, err error)
- func (c CWL_collection) GetWorkflowStepInput(id string) (obj *WorkflowStepInput, err error)
- type CWL_document_generic
- type CWL_location
- type CWL_minimal
- type CWL_minimal_interface
- type CWL_object
- type CWL_object_generic
- type CommandInputParameter
- type CommandInputParameterType
- type CommandLineBinding
- type CommandLineTool
- type CommandOutputArraySchema
- type CommandOutputBinding
- type CommandOutputEnumSchema
- type CommandOutputParameter
- type CommandOutputParameterType
- type CommandOutputRecordField
- type CommandOutputRecordSchema
- type Directory
- type Empty
- type File
- type InputParameter
- type InputParameterType
- type Int
- type Job_document
- type LinkMergeMethod
- type OutputArraySchema
- type OutputEnumSchema
- type OutputRecordSchema
- type Process
- type ProcessPointer
- type Requirement
- type String
- type Workflow
- type WorkflowOutputParameter
- type WorkflowOutputParameterType
- type WorkflowStep
- type WorkflowStepInput
- type WorkflowStepOutput
Constants ¶
const ( CWL_null = "null" //no value CWL_boolean = "boolean" //a binary value CWL_int = "int" //32-bit signed integer CWL_long = "long" //64-bit signed integer CWL_float = "float" //single precision (32-bit) IEEE 754 floating-point number CWL_double = "double" //double precision (64-bit) IEEE 754 floating-point number CWL_string = "string" //Unicode character sequence CWL_File = "File" //A File object )
http://www.commonwl.org/draft-3/CommandLineTool.html#CWLType
Variables ¶
This section is empty.
Functions ¶
func CreateCommandInputParameterTypeArray ¶ added in v0.9.45
func CreateCommandInputParameterTypeArray(v interface{}) (cipt_array_ptr *[]CommandInputParameterType, err error)
func CreateRequirementArray ¶
func CreateRequirementArray(original interface{}) (new_array_ptr *[]Requirement, err error)
func CreateWorkflowStepInputArray ¶
func CreateWorkflowStepInputArray(original interface{}) (array_ptr *[]WorkflowStepInput, err error)
func CreateWorkflowStepsArray ¶
func CreateWorkflowStepsArray(original interface{}, collection *CWL_collection) (err error, array_ptr *[]WorkflowStep)
CreateWorkflowStepsArray
func EvaluateExpression ¶ added in v0.9.45
func EvaluateExpression(collection *CWL_collection, e cwl_types.Expression) string
func GetMapElement ¶
func HasCommandInputParameterType ¶ added in v0.9.45
func HasCommandInputParameterType(array *[]CommandInputParameterType, search_type string) (ok bool)
func HasInputParameterType ¶ added in v0.9.45
func HasInputParameterType(array *[]InputParameterType, search_type string) (ok bool)
func NewCommandOutputParameterArray ¶ added in v0.9.45
func NewCommandOutputParameterArray(original interface{}) (copa *[]CommandOutputParameter, err error)
func NewCommandOutputParameterTypeArray ¶ added in v0.9.45
func NewCommandOutputParameterTypeArray(original interface{}) (copta *[]CommandOutputParameterType, err error)
func NewInputParameterTypeArray ¶ added in v0.9.45
func NewInputParameterTypeArray(original interface{}) (array_ptr *[]InputParameterType, err error)
func NewWorkflowOutputParameterArray ¶ added in v0.9.45
func NewWorkflowOutputParameterArray(original interface{}) (new_array_ptr *[]WorkflowOutputParameter, err error)
WorkflowOutputParameter
func NewWorkflowOutputParameterTypeArray ¶ added in v0.9.45
func NewWorkflowOutputParameterTypeArray(original interface{}) (wopta_ptr *[]WorkflowOutputParameterType, err error)
func Parse_cwl_document ¶
func Parse_cwl_document(collection *CWL_collection, yaml_str string) (err error)
Types ¶
type Any ¶
type Any interface {
CWL_object
}
type Boolean ¶ added in v0.9.45
type Boolean struct {
CWLType_Impl
Id string `yaml:"id"`
Value bool `yaml:"value"`
}
type CWLType ¶
type CWLType interface {
CWL_object
// contains filtered or unexported methods
}
CWLType - CWL basic types: int, string, boolean, .. etc http://www.commonwl.org/v1.0/CommandLineTool.html#CWLType null, boolean, int, long, float, double, string, File, Directory
func NewCWLType ¶ added in v0.9.45
type CWLType_Impl ¶ added in v0.9.45
type CWLType_Impl struct{}
type CWLVersion ¶
type CWLVersion interface{} // TODO
type CWL_collection ¶
type CWL_collection struct {
Workflows map[string]*Workflow
WorkflowStepInputs map[string]*WorkflowStepInput
CommandLineTools map[string]*CommandLineTool
Files map[string]*File
Strings map[string]*String
Ints map[string]*Int
Booleans map[string]*Boolean
All map[string]*CWL_object
Job_input *Job_document
}
func NewCWL_collection ¶
func NewCWL_collection() (collection CWL_collection)
func (CWL_collection) Add ¶
func (c CWL_collection) Add(obj CWL_object) (err error)
func (CWL_collection) Evaluate ¶
func (c CWL_collection) Evaluate(raw string) (parsed string)
func (CWL_collection) Get ¶
func (c CWL_collection) Get(id string) (obj *CWL_object, err error)
func (CWL_collection) GetString ¶
func (c CWL_collection) GetString(id string) (obj *String, err error)
func (CWL_collection) GetWorkflowStepInput ¶
func (c CWL_collection) GetWorkflowStepInput(id string) (obj *WorkflowStepInput, err error)
type CWL_document_generic ¶
type CWL_document_generic struct {
CwlVersion string `yaml:"cwlVersion"`
Graph []CWL_object_generic `yaml:"graph"`
}
this is used by YAML or JSON library for inital parsing
type CWL_location ¶
type CWL_location interface {
GetLocation() string
}
generic class to represent Files and Directories
type CWL_minimal ¶ added in v0.9.45
type CWL_minimal struct{}
type CWL_minimal_interface ¶ added in v0.9.45
type CWL_minimal_interface interface {
// contains filtered or unexported methods
}
type CWL_object ¶
type CWL_object interface {
CWL_minimal_interface
GetClass() string
GetId() string
SetId(string)
}
type CWL_object_generic ¶
type CWL_object_generic map[string]interface{}
type CommandInputParameter ¶
type CommandInputParameter struct {
Id string `yaml:"id"`
SecondaryFiles []string `yaml:"secondaryFiles"` // TODO string | Expression | array<string | Expression>
Format string `yaml:"format"`
Streamable bool `yaml:"streamable"`
Type []CommandInputParameterType `yaml:"type"` // TODO CWLType | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | string | array<CWLType | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | string>
Label string `yaml:"label"`
Description string `yaml:"description"`
InputBinding CommandLineBinding `yaml:"inputBinding"`
Default *Any `yaml:"default"`
}
func CreateCommandInputArray ¶
func CreateCommandInputArray(original interface{}) (err error, new_array []*CommandInputParameter)
keyname will be converted into 'Id'-field
func NewCommandInputParameter ¶ added in v0.9.45
func NewCommandInputParameter(v interface{}) (input_parameter *CommandInputParameter, err error)
type CommandInputParameterType ¶ added in v0.9.45
type CommandInputParameterType struct {
Type string
}
func NewCommandInputParameterType ¶ added in v0.9.45
func NewCommandInputParameterType(original interface{}) (cipt_ptr *CommandInputParameterType, err error)
type CommandLineBinding ¶
type CommandLineBinding struct {
LoadContents bool `yaml:"loadContents"`
Position int `yaml:"position"`
Prefix string `yaml:"prefix"`
Separate string `yaml:"separate"`
ItemSeparator string `yaml:"itemSeparator"`
ValueFrom string `yaml:"valueFrom"`
ShellQuote bool `yaml:"shellQuote"`
}
http://www.commonwl.org/v1.0/Workflow.html#CommandLineBinding
type CommandLineTool ¶
type CommandLineTool struct {
Id string `yaml:"id"`
BaseCommand string `yaml:"baseCommand"` // TODO also allow []string
Inputs []CommandInputParameter `yaml:"inputs"`
Outputs []CommandOutputParameter `yaml:"outputs"`
Hints []Requirement `yaml:"hints"` // TODO Any
Label string `yaml:"label"`
Description string `yaml:"description"`
CwlVersion CWLVersion `yaml:"cwlVersion"`
Arguments []string `yaml:"arguments"` // TODO support CommandLineBinding
Stdin string `yaml:"stdin"` // TODO support Expression
Stdout string `yaml:"stdout"` // TODO support Expression
SuccessCodes []int `yaml:"successCodes"`
TemporaryFailCodes []int `yaml:"temporaryFailCodes"`
PermanentFailCodes []int `yaml:"permanentFailCodes"`
}
func NewCommandLineTool ¶ added in v0.9.45
func NewCommandLineTool(object CWL_object_generic) (commandLineTool *CommandLineTool, err error)
func (*CommandLineTool) GetClass ¶
func (c *CommandLineTool) GetClass() string
func (*CommandLineTool) GetId ¶
func (c *CommandLineTool) GetId() string
func (*CommandLineTool) SetId ¶
func (c *CommandLineTool) SetId(id string)
type CommandOutputArraySchema ¶ added in v0.9.45
type CommandOutputArraySchema struct {
Items []string `yaml:"items"`
Type string `yaml:"type"` // must be array
Label string `yaml:"label"`
OutputBinding *CommandOutputBinding `yaml:"outputBinding"`
}
func NewCommandOutputArraySchema ¶ added in v0.9.45
func NewCommandOutputArraySchema(original map[interface{}]interface{}) (coas *CommandOutputArraySchema, err error)
type CommandOutputBinding ¶
type CommandOutputBinding struct {
Glob []cwl_types.Expression `yaml:"glob"`
LoadContents bool `yaml:"loadContents"`
OutputEval cwl_types.Expression `yaml:"outputEval"`
}
func NewCommandOutputBinding ¶ added in v0.9.45
func NewCommandOutputBinding(original interface{}) (commandOutputBinding *CommandOutputBinding, err error)
type CommandOutputEnumSchema ¶ added in v0.9.45
type CommandOutputEnumSchema struct {
Symbols []string
Type string // must be enum
Label string
OutputBinding *CommandOutputBinding
}
http://www.commonwl.org/v1.0/CommandLineTool.html#CommandOutputEnumSchema
type CommandOutputParameter ¶
type CommandOutputParameter struct {
Id string `yaml:"id"`
SecondaryFiles []cwl_types.Expression `yaml:"secondaryFiles"` // TODO string | Expression | array<string | Expression>
Format string `yaml:"format"`
Streamable bool `yaml:"streamable"`
Type []CommandOutputParameterType `yaml:"type"` // TODO CWLType | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | string | array<CWLType | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | string>
Label string `yaml:"label"`
Description string `yaml:"description"`
OutputBinding CommandOutputBinding `yaml:"outputBinding"`
}
func NewCommandOutputParameter ¶ added in v0.9.45
func NewCommandOutputParameter(original interface{}) (output_parameter *CommandOutputParameter, err error)
type CommandOutputParameterType ¶ added in v0.9.45
type CommandOutputParameterType struct {
Type string
CommandOutputArraySchema *CommandOutputArraySchema
CommandOutputRecordSchema *CommandOutputRecordSchema
}
func NewCommandOutputParameterType ¶ added in v0.9.45
func NewCommandOutputParameterType(original interface{}) (copt_ptr *CommandOutputParameterType, err error)
type CommandOutputRecordField ¶ added in v0.9.45
type CommandOutputRecordField struct{}
type CommandOutputRecordSchema ¶ added in v0.9.45
type CommandOutputRecordSchema struct {
Type string // Must be record
Fields []CommandOutputRecordField
Label string
}
type Directory ¶
type Directory struct {
Id string `yaml:"id"`
Location string `yaml:"location"`
Path string `yaml:"path"`
Basename string `yaml:"basename"`
Listing []CWL_location `yaml:"basename"`
}
func (Directory) GetLocation ¶
type Empty ¶
type Empty struct {
CWLType_Impl
Id string `yaml:"id"`
Class string `yaml:"class"`
}
this is a generic CWL_object. Its only purpose is to retrieve the value of "class"
type File ¶
type File struct {
CWLType_Impl
Id string `yaml:"id"`
Location string `yaml:"location"` // An IRI that identifies the file resource.
Path string `yaml:"path"` // dirname + '/' + basename == path This field must be set by the implementation.
Basename string `yaml:"basename"` // dirname + '/' + basename == path // if not defined, take from location
Dirname string `yaml:"dirname"` // dirname + '/' + basename == path
Nameroot string `yaml:"nameroot"`
Nameext string `yaml:"nameext"`
Checksum string `yaml:"checksum"`
Size int32 `yaml:"size"`
SecondaryFiles []CWL_location `yaml:"secondaryFiles"`
Format string `yaml:"format"`
Contents string `yaml:"contents"`
// Shock node
Host string
Node string
Bearer string
Token string
}
http://www.commonwl.org/v1.0/Workflow.html#File
func (*File) GetLocation ¶
type InputParameter ¶
type InputParameter struct {
Id string `yaml:"id"`
Label string `yaml:"label"`
SecondaryFiles []string `yaml:"secondaryFiles"` // TODO string | Expression | array<string | Expression>
Format string `yaml:"format"`
Streamable bool `yaml:"streamable"`
Doc string `yaml:"doc"`
InputBinding CommandLineBinding `yaml:"inputBinding"` //TODO
Default Any `yaml:"default"`
Type *[]InputParameterType `yaml:"type"` // TODO CWLType | InputRecordSchema | InputEnumSchema | InputArraySchema | string | array<CWLType | InputRecordSchema | InputEnumSchema | InputArraySchema | string>
}
func NewInputParameter ¶ added in v0.9.45
func NewInputParameter(original interface{}) (input_parameter *InputParameter, err error)
func NewInputParameterArray ¶ added in v0.9.45
func NewInputParameterArray(original interface{}) (err error, new_array []InputParameter)
InputParameter
func (InputParameter) GetClass ¶
func (i InputParameter) GetClass() string
func (InputParameter) GetId ¶
func (i InputParameter) GetId() string
func (InputParameter) SetId ¶
func (i InputParameter) SetId(id string)
type InputParameterType ¶ added in v0.9.45
type InputParameterType struct {
Type string
}
func NewInputParameterType ¶ added in v0.9.45
func NewInputParameterType(original interface{}) (ipt_ptr *InputParameterType, err error)
type Int ¶
type Int struct {
CWLType_Impl
Id string `yaml:"id"`
Value int `yaml:"value"`
}
type Job_document ¶
func NewJob_document ¶ added in v0.9.45
func NewJob_document(original interface{}) (job *Job_document, err error)
func ParseJob ¶
func ParseJob(collection *CWL_collection, job_file string) (job_input *Job_document, err error)
type LinkMergeMethod ¶
type LinkMergeMethod string // merge_nested or merge_flattened
type OutputArraySchema ¶ added in v0.9.45
type OutputArraySchema struct{}
type OutputEnumSchema ¶ added in v0.9.45
type OutputEnumSchema struct{}
type OutputRecordSchema ¶ added in v0.9.45
type OutputRecordSchema struct{}
type Process ¶ added in v0.9.45
type Process interface {
CWL_object
// contains filtered or unexported methods
}
func NewProcess ¶ added in v0.9.45
func NewProcess(original interface{}, collection *CWL_collection) (process Process, err error)
returns CommandLineTool, ExpressionTool or Workflow
type ProcessPointer ¶ added in v0.9.45
func (*ProcessPointer) GetClass ¶ added in v0.9.45
func (p *ProcessPointer) GetClass() string
func (*ProcessPointer) GetId ¶ added in v0.9.45
func (p *ProcessPointer) GetId() string
func (*ProcessPointer) SetId ¶ added in v0.9.45
func (p *ProcessPointer) SetId(string)
type Requirement ¶
type Requirement interface {
GetClass() string
}
func CreateRequirementDEPRECATED ¶ added in v0.9.45
func CreateRequirementDEPRECATED(class string, v interface{}) (requirement Requirement, err error)
create Requirement object from interface type
func NewRequirement ¶
func NewRequirement(class string, obj interface{}) (r Requirement, err error)
type String ¶
type String struct {
CWLType_Impl
Id string `yaml:"id"`
Value string `yaml:"value"`
}
type Workflow ¶
type Workflow struct {
Inputs []InputParameter `yaml:"inputs"`
Outputs []WorkflowOutputParameter `yaml:"outputs"`
Id string `yaml:"id"`
Steps []WorkflowStep `yaml:"steps"`
Requirements []Requirement `yaml:"requirements"`
Hints []Requirement `yaml:"hints"` // TODO Hints may contain non-requirement objects. Give warning in those cases.
Label string `yaml:"label"`
Doc string `yaml:"doc"`
CwlVersion CWLVersion `yaml:"cwlVersion"`
Metadata map[string]interface{} `yaml:"metadata"`
}
func NewWorkflow ¶ added in v0.9.45
func NewWorkflow(object CWL_object_generic, collection *CWL_collection) (workflow Workflow, err error)
type WorkflowOutputParameter ¶
type WorkflowOutputParameter struct {
Id string `yaml:"id"`
Label string `yaml:"label"`
SecondaryFiles []cwl_types.Expression `yaml:"secondaryFiles"` // TODO string | Expression | array<string | Expression>
Format []cwl_types.Expression `yaml:"format"`
Streamable bool `yaml:"streamable"`
Doc string `yaml:"doc"`
OutputBinding CommandOutputBinding `yaml:"outputBinding"` //TODO
OutputSource []string `yaml:"outputSource"`
LinkMerge LinkMergeMethod `yaml:"linkMerge"`
Type []WorkflowOutputParameterType `yaml:"type"` // TODO CWLType | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string | array<CWLType | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string>
}
func NewWorkflowOutputParameter ¶ added in v0.9.45
func NewWorkflowOutputParameter(original interface{}) (wop *WorkflowOutputParameter, err error)
type WorkflowOutputParameterType ¶ added in v0.9.45
type WorkflowOutputParameterType struct {
Type string
OutputRecordSchema *OutputRecordSchema
OutputEnumSchema *OutputEnumSchema
OutputArraySchema *OutputArraySchema
}
func NewWorkflowOutputParameterType ¶ added in v0.9.45
func NewWorkflowOutputParameterType(original interface{}) (wopt_ptr *WorkflowOutputParameterType, err error)
type WorkflowStep ¶
type WorkflowStep struct {
Id string `yaml:"id"`
In []WorkflowStepInput `yaml:"in"` // array<WorkflowStepInput> | map<WorkflowStepInput.id, WorkflowStepInput.source> | map<WorkflowStepInput.id, WorkflowStepInput>
Out []WorkflowStepOutput `yaml:"out"`
Run *Process `yaml:"run"` // Specification unclear: string | CommandLineTool | ExpressionTool | Workflow
Requirements []Requirement `yaml:"requirements"`
Hints []Requirement `yaml:"hints"`
Label string `yaml:"label"`
Doc string `yaml:"doc"`
Scatter string `yaml:"scatter"` // ScatterFeatureRequirement
ScatterMethod string `yaml:"scatterMethod"` // ScatterFeatureRequirement
}
func NewWorkflowStep ¶ added in v0.9.45
func NewWorkflowStep(original interface{}, collection *CWL_collection) (w *WorkflowStep, err error)
func (WorkflowStep) GetOutput ¶
func (w WorkflowStep) GetOutput(id string) (output *WorkflowStepOutput, err error)
type WorkflowStepInput ¶
type WorkflowStepInput struct {
Id string `yaml:"id"`
Source []string `yaml:"source"` // MultipleInputFeatureRequirement
LinkMerge LinkMergeMethod `yaml:"linkMerge"`
Default Any `yaml:"default"` // type Any does not make sense
ValueFrom cwl_types.Expression `yaml:"valueFrom"` // StepInputExpressionRequirement
}
http://www.commonwl.org/v1.0/Workflow.html#WorkflowStepInput
func NewWorkflowStepInput ¶ added in v0.9.45
func NewWorkflowStepInput(original interface{}) (input_parameter_ptr *WorkflowStepInput, err error)
func (WorkflowStepInput) GetClass ¶
func (w WorkflowStepInput) GetClass() string
func (WorkflowStepInput) GetId ¶
func (w WorkflowStepInput) GetId() string
func (WorkflowStepInput) GetObject ¶
func (input WorkflowStepInput) GetObject(c *CWL_collection) (obj *CWL_object, err error)
func (WorkflowStepInput) SetId ¶
func (w WorkflowStepInput) SetId(id string)
type WorkflowStepOutput ¶
type WorkflowStepOutput struct {
Id string `yaml:"id"`
}
func CreateWorkflowStepOutputArray ¶
func CreateWorkflowStepOutputArray(original interface{}) (new_array []WorkflowStepOutput, err error)
Source Files
¶
- any.go
- boolean.go
- collection.go
- commandInputParameter.go
- commandInputParameterType.go
- commandLineTool.go
- commandOutputBinding.go
- commandOutputParameter.go
- commandOutputParameterType.go
- cwl.go
- cwl_object.go
- cwl_type.go
- empty.go
- expression.go
- file.go
- inputParameter.go
- inputParameterType.go
- int.go
- job.go
- process.go
- requirements.go
- string.go
- workflow.go
- workflowOutputParameter.go
- workflowOutputParameterType.go
- workflowStep.go
- workflowStepInput.go
- workflowStepOutput.go