File: program.rnc

package info (click to toggle)
mobyle 1.5.5%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 8,284 kB
  • ctags: 2,783
  • sloc: python: 22,709; sh: 33; makefile: 31; ansic: 10; xml: 6
file content (65 lines) | stat: -rw-r--r-- 1,771 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
include "common.rnc"

start |= Program

Program = element program {
	Service
}

InvocationHead &=		(
		 ## executable name
		 element command {
			## custom path	
			attribute path { text }?&
			text
			}?&
		 ## environment variable for program invocation
		 element env { 
			## name
			attribute name { text }&
			## value
			text 
			}*
		 )?&
		 ## progress report output for the program
		 # displayed even before the program completes
		 element progressReport {
		    ## prompt to "label" the progress report
		    attribute prompt { text }?&
		    text
		 }?

InvocationParagraph &= Argpos?

InvocationParameterElements &=
	(
	(
	 ## command parameter
	 # iscommand : if true& this parameter specify the line of command to run the program  used when the command line is more complicated.
	 attribute iscommand { xsd:boolean }?|
	 ## parameter file
	 element paramfile { text }?
	)&
	## command line chunk evaluation code 
	Format?&
	## command line chunk position index
	Argpos?&
	## result file(s) mask(s) 
	# this element is relevant only for output parameters, it is used to find the files in which the results are stored
	# each code must have ONLY ONE file unix mask 
	element filenames { Code+ }?
	)

Argpos =
	## command line chunk position index 
	# in parameter: specifies the position of this parameter on the command line
	# in paragraph: specifies the position on the command line for all parameters of this paragraph
	# by convention the argpos of command must be 0. if we want args before command we could get negative argpos.
	element argpos { xsd:integer }
	
Format =
	## command line chunk construction code
	# a code which will be evaluated to form the command line
	element format { Code+ }
	
InterfaceType &= ("form"|"job_input"|"job_output")