Yaml output of the instantiated CommandLineTool Object
pgrosu opened this issue · comments
Paul Grosu commented
@mr-c I just did the following (thought I had to use snakeyaml-1.19-android.jar
rather than the normal jar - the Program_Context is an instance of CommandLineTool:
DumperOptions Yaml_Formatter = new DumperOptions();
Yaml_Formatter.setDefaultFlowStyle(DumperOptions.FlowStyle.FLOW);
Yaml_Formatter.setPrettyFlow(true);
Yaml yaml = new Yaml( Yaml_Formatter );
String YAML_Program_Context = yaml.dump( Program_Context );
System.out.println( YAML_Program_Context );
Below is the output:
!!org.commonwl.lang.CommandLineTool {
arguments: null,
baseCommand: wc,
class_value: null,
cwlVersion: null,
doc: null,
hints: null,
id: null,
inputs: [
{
default_value: null,
doc: null,
format: null,
id: example_string,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 0,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: string
},
{
default_value: null,
doc: null,
format: null,
id: file2,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 1,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: File
},
{
default_value: null,
doc: null,
format: null,
id: file1,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 2,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: File
}]
,
label: null,
outputs: [
{
doc: null,
format: null,
id: output,
label: null,
outputBinding: {
glob: output,
loadContents: null,
outputEval: null
},
secondaryFiles: null,
streamable: null,
type: File
}]
,
permanentFailCodes: null,
requirements: null,
stderr: null,
stdin: whale.txt,
stdout: output,
successCodes: null,
temporaryFailCodes: null
}
Michael R. Crusoe commented
Interesting, so this will need updating to match the official syntax
Pe 18 ian. 2018 22:25, "Paul Grosu" <notifications@github.com> a scris:
… @mr-c <https://github.com/mr-c> I just did the following (thought I had
to use snakeyaml-1.19-android.jar rather than the normal jar - the
Program_Context is an instance of CommandLineTool:
DumperOptions Yaml_Formatter = new DumperOptions();
Yaml_Formatter.setDefaultFlowStyle(DumperOptions.FlowStyle.FLOW);
Yaml_Formatter.setPrettyFlow(true);
Yaml yaml = new Yaml( Yaml_Formatter );
String YAML_Program_Context = yaml.dump( Program_Context );
System.out.println( YAML_Program_Context );
Below is the output:
!!org.commonwl.lang.CommandLineTool {
arguments: null,
baseCommand: wc,
class_value: null,
cwlVersion: null,
doc: null,
hints: null,
id: null,
inputs: [
{
default_value: null,
doc: null,
format: null,
id: example_string,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 0,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: string
},
{
default_value: null,
doc: null,
format: null,
id: file2,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 1,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: File
},
{
default_value: null,
doc: null,
format: null,
id: file1,
inputBinding: {
itemSeparator: null,
loadContents: null,
position: 2,
prefix: null,
separate: null,
shellQuote: null,
valueFrom: null
},
label: null,
secondaryFiles: null,
streamable: null,
type: File
}]
,
label: null,
outputs: [
{
doc: null,
format: null,
id: output,
label: null,
outputBinding: {
glob: output,
loadContents: null,
outputEval: null
},
secondaryFiles: null,
streamable: null,
type: File
}]
,
permanentFailCodes: null,
requirements: null,
stderr: null,
stdin: whale.txt,
stdout: output,
successCodes: null,
temporaryFailCodes: null
}
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#21>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABROCMvmF78vViDJLpcJ396HxMnJxi_Yks5tMAtAgaJpZM4Rj75Q>
.