taverna-t2flow 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
data/ChangeLog.rdoc CHANGED
@@ -1,8 +1,6 @@
1
- = Version 0.1.1
2
- Released:: Wednesday, September 16, 2009
1
+ = Version 0.1.4
2
+ Released:: Monday, July 26, 2010
3
3
 
4
4
  == Added Functionality
5
- - Retrieval of Taverna local workers.
6
-
7
- === New instance method in T2Flow::Model
8
- local_workers
5
+ - Bug fixes in the parser.
6
+ - Added Dataflow#name
data/README.rdoc CHANGED
@@ -1,7 +1,7 @@
1
1
  = Taverna[http://taverna.sourceforge.net] 2 Interaction Gem
2
2
 
3
3
  Authors:: Mannie Tagarira, David Withers
4
- Version:: 0.1.2
4
+ Version:: 0.1.4
5
5
  Contact:: mailto:mannie@mygrid.org.uk
6
6
  URL:: http://taverna.sourceforge.net/
7
7
  Licence:: LGPL 3 (See LICENCE or http://www.gnu.org/licenses/lgpl.html)
data/lib/t2flow/model.rb CHANGED
@@ -189,6 +189,10 @@ module T2Flow # :nodoc:
189
189
  @coordinations = []
190
190
  end
191
191
 
192
+ def name
193
+ @annotations.name
194
+ end
195
+
192
196
  # Retrieve beanshell processors specific to this dataflow.
193
197
  def beanshells
194
198
  @processors.select { |x| x.type == "beanshell" }
data/lib/t2flow/parser.rb CHANGED
@@ -41,6 +41,8 @@ module T2Flow
41
41
  end
42
42
 
43
43
  element.each do |dataflow|
44
+ next if dataflow["id"].nil? || dataflow["id"].chomp.strip.empty?
45
+
44
46
  dataflow_obj = Dataflow.new
45
47
  dataflow_obj.dataflow_id = dataflow["id"]
46
48
 
@@ -76,14 +78,16 @@ module T2Flow
76
78
  end
77
79
 
78
80
  def add_source(dataflow, port) # :nodoc:
81
+ return if port.nil? || port.content.chomp.strip.empty?
82
+
79
83
  source = Source.new
80
-
84
+
81
85
  port.each do |elt|
82
86
  case elt.name
83
87
  when "name": source.name = elt.content
84
88
  when "annotations"
85
89
  elt.each do |ann|
86
- next if ann.nil? || ann.empty?
90
+ next if ann.nil? || ann.content.chomp.strip.empty?
87
91
 
88
92
  node = LibXML::XML::Parser.string("#{ann}").parse
89
93
  content_node = node.find_first("//annotationBean")
@@ -105,6 +109,8 @@ module T2Flow
105
109
  end
106
110
 
107
111
  def add_sink(dataflow, port) # :nodoc:
112
+ return if port.nil? || port.content.chomp.strip.empty?
113
+
108
114
  sink = Sink.new
109
115
 
110
116
  port.each do |elt|
@@ -112,7 +118,7 @@ module T2Flow
112
118
  when "name": sink.name = elt.content
113
119
  when "annotations"
114
120
  elt.each do |ann|
115
- next if ann.nil? || ann.empty?
121
+ next if ann.nil? || ann.content.chomp.strip.empty?
116
122
 
117
123
  node = LibXML::XML::Parser.string("#{ann}").parse
118
124
  content_node = node.find_first("//annotationBean")
@@ -134,6 +140,8 @@ module T2Flow
134
140
  end
135
141
 
136
142
  def add_processor(dataflow, element) # :nodoc:
143
+ return if element.nil? || element.content.chomp.strip.empty?
144
+
137
145
  processor = Processor.new
138
146
 
139
147
  temp_inputs = []
@@ -208,6 +216,8 @@ module T2Flow
208
216
  end
209
217
 
210
218
  def add_link(dataflow, link) # :nodoc:
219
+ return if link.nil? || link.content.chomp.strip.empty?
220
+
211
221
  datalink = Datalink.new
212
222
 
213
223
  link.each do |sink_source|
@@ -225,6 +235,8 @@ module T2Flow
225
235
  end
226
236
 
227
237
  def add_coordination(dataflow, condition) # :nodoc:
238
+ return if coordination.nil? || coordination.content.chomp.strip.empty?
239
+
228
240
  coordination = Coordination.new
229
241
 
230
242
  coordination.control = condition["control"]
metadata CHANGED
@@ -1,7 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: taverna-t2flow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ hash: 19
5
+ prerelease: false
6
+ segments:
7
+ - 0
8
+ - 1
9
+ - 4
10
+ version: 0.1.4
5
11
  platform: ruby
6
12
  authors:
7
13
  - Mannie Tagarira
@@ -14,14 +20,20 @@ default_executable:
14
20
  dependencies:
15
21
  - !ruby/object:Gem::Dependency
16
22
  name: libxml-ruby
17
- type: :runtime
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
20
26
  requirements:
21
27
  - - ">="
22
28
  - !ruby/object:Gem::Version
29
+ hash: 21
30
+ segments:
31
+ - 1
32
+ - 1
33
+ - 3
23
34
  version: 1.1.3
24
- version:
35
+ type: :runtime
36
+ version_requirements: *id001
25
37
  description: This a gem developed by myGrid for the purpose of interacting with Taverna 2 workflows. An example use would be the image genaration for the model representing Taverna 2 workflows as used in myExperiment.
26
38
  email: mannie@mygrid.org.uk
27
39
  executables: []
@@ -33,7 +45,6 @@ extra_rdoc_files:
33
45
  - LICENCE
34
46
  - ChangeLog.rdoc
35
47
  files:
36
- - lib/t2flow
37
48
  - lib/t2flow/dot.rb
38
49
  - lib/t2flow/model.rb
39
50
  - lib/t2flow/parser.rb
@@ -42,6 +53,8 @@ files:
42
53
  - ChangeLog.rdoc
43
54
  has_rdoc: true
44
55
  homepage: http://www.mygrid.org.uk/
56
+ licenses: []
57
+
45
58
  post_install_message:
46
59
  rdoc_options:
47
60
  - -N
@@ -51,21 +64,29 @@ rdoc_options:
51
64
  require_paths:
52
65
  - lib
53
66
  required_ruby_version: !ruby/object:Gem::Requirement
67
+ none: false
54
68
  requirements:
55
69
  - - ">="
56
70
  - !ruby/object:Gem::Version
71
+ hash: 21
72
+ segments:
73
+ - 1
74
+ - 0
75
+ - 1
57
76
  version: 1.0.1
58
- version:
59
77
  required_rubygems_version: !ruby/object:Gem::Requirement
78
+ none: false
60
79
  requirements:
61
80
  - - ">="
62
81
  - !ruby/object:Gem::Version
82
+ hash: 3
83
+ segments:
84
+ - 0
63
85
  version: "0"
64
- version:
65
86
  requirements: []
66
87
 
67
88
  rubyforge_project:
68
- rubygems_version: 1.3.1
89
+ rubygems_version: 1.3.7
69
90
  signing_key:
70
91
  specification_version: 1
71
92
  summary: Support for interacting with the Taverna 2 workflow system (T2Flow).