10079: ajax to display child component details; not working yet.
[arvados.git] / apps / workbench / app / models / work_unit.rb
1 class WorkUnit
2   # This is an abstract class that documents the WorkUnit interface
3
4   def label
5     # returns the label that was assigned when creating the work unit
6   end
7
8   def proxied
9     # returns the proxied object of this work unit
10   end
11
12   def uuid
13     # returns the arvados UUID of the underlying object
14   end
15
16   def children
17     # returns an array of child work units
18   end
19
20   def modified_by_user_uuid
21     # returns uuid of the user who modified this work unit most recently
22   end
23
24   def owner_uuid
25     # returns uuid of the owner of this work unit
26   end
27
28   def created_at
29     # returns created_at timestamp
30   end
31
32   def modified_at
33     # returns modified_at timestamp
34   end
35
36   def started_at
37     # returns started_at timestamp for this work unit
38   end
39
40   def finished_at
41     # returns finished_at timestamp
42   end
43
44   def state_label
45     # returns a string representing state of the work unit
46   end
47
48   def exit_code
49     # returns the work unit's execution exit code
50   end
51
52   def state_bootstrap_class
53     # returns a class like "danger", "success", or "warning" that a view can use directly to make a display class
54   end
55
56   def success?
57     # returns true if the work unit finished successfully,
58     # false if it has a permanent failure,
59     # and nil if the final state is not determined.
60   end
61
62   def progress
63     # returns a number between 0 and 1
64   end
65
66   def log_collection
67     # returns uuid or pdh with saved log data, if any
68   end
69
70   def parameters
71     # returns work unit parameters, if any
72   end
73
74   def script
75     # returns script for this work unit, if any
76   end
77
78   def repository
79     # returns this work unit's script repository, if any
80   end
81
82   def script_version
83     # returns this work unit's script_version, if any
84   end
85
86   def supplied_script_version
87     # returns this work unit's supplied_script_version, if any
88   end
89
90   def docker_image
91     # returns this work unit's docker_image, if any
92   end
93
94   def runtime_constraints
95     # returns this work unit's runtime_constraints, if any
96   end
97
98   def priority
99     # returns this work unit's priority, if any
100   end
101
102   def nondeterministic
103     # returns if this is nondeterministic
104   end
105
106   def outputs
107     # returns array containing uuid or pdh of output data
108   end
109
110   def child_summary
111     # summary status of any children of this work unit
112   end
113
114   def child_summary_str
115     # textual representation of child summary
116   end
117
118   def can_cancel?
119     # returns true if this work unit can be canceled
120   end
121
122   def uri
123     # returns the uri for this work unit
124   end
125
126   def title
127     # title for the work unit
128   end
129
130   def has_unreadable_children
131     # accept it if you can't understand your own children
132   end
133
134   # view helper methods
135   def walltime
136     # return walltime for a running or completed work unit
137   end
138
139   def cputime
140     # return cputime for a running or completed work unit
141   end
142
143   def queuedtime
144     # return queued time if the work unit is queued
145   end
146
147   def is_running?
148     # is the work unit in running state?
149   end
150
151   def is_paused?
152     # is the work unit in paused state?
153   end
154
155   def is_finished?
156     # is the work unit in finished state?
157   end
158
159   def is_failed?
160     # is this work unit in failed state?
161   end
162
163   def command
164     # command to execute
165   end
166
167   def cwd
168     # initial workind directory
169   end
170
171   def environment
172     # environment variables
173   end
174
175   def mounts
176     # mounts
177   end
178
179   def output_path
180     # path to a directory or file to save output
181   end
182
183   def container_uuid
184     # container_uuid of a container_request
185   end
186
187   def log_object_uuids
188     # object uuids for live log
189   end
190
191   def live_log_lines(limit)
192     # fetch log entries from logs table for @proxied
193   end
194
195   def render_log
196     # return partial and locals to be rendered
197   end
198
199   def template_uuid
200     # return the uuid of this work unit's template, if one exists
201   end
202 end