teamforge 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,241 @@
1
+
2
+ module TeamForge
3
+ module TrackerApp
4
+
5
+ ######################
6
+ # TrackerApp Messages
7
+ ######################
8
+ AddDateField = Struct.new(:session_id, :tracker_id, :field_name, :is_required, :is_disabled, :is_hidden_on_create, :help_text) do
9
+ def send (server=nil, proxy=nil)
10
+ TeamForge.request(self, server, proxy)
11
+ end
12
+ end
13
+ AddMultiSelectField = Struct.new(:session_id, :tracker_id, :field_name, :display_lines, :is_required, :is_disabled, :is_hidden_on_create, :field_values, :default_values, :help_text) do
14
+ def send (server=nil, proxy=nil)
15
+ TeamForge.request(self, server, proxy)
16
+ end
17
+ end
18
+ AddSeparator = Struct.new(:session_id, :tracker_id, :separator_type, :separator_label) do
19
+ def send (server=nil, proxy=nil)
20
+ TeamForge.request(self, server, proxy)
21
+ end
22
+ end
23
+ AddSingleSelectChildField = Struct.new(:session_id, :tracker_id, :field_name, :field_values, :parent_field_id, :parent_child_field_value_map, :help_text) do
24
+ def send (server=nil, proxy=nil)
25
+ TeamForge.request(self, server, proxy)
26
+ end
27
+ end
28
+ AddSingleSelectField = Struct.new(:session_id, :tracker_id, :field_name, :is_required, :is_disabled, :is_hidden_on_create, :field_values, :default_value, :help_text) do
29
+ def send (server=nil, proxy=nil)
30
+ TeamForge.request(self, server, proxy)
31
+ end
32
+ end
33
+ AddTextField = Struct.new(:session_id, :tracker_id, :field_name, :display_columns, :display_lines, :is_required, :is_disabled, :is_hidden_on_create, :default_value, :help_text, :pattern) do
34
+ def send (server=nil, proxy=nil)
35
+ TeamForge.request(self, server, proxy)
36
+ end
37
+ end
38
+ AddUserSelectField = Struct.new(:session_id, :tracker_id, :field_name, :display_lines, :is_required, :is_disabled, :is_hidden_on_create, :default_values, :user_filter, :help_text) do
39
+ def send (server=nil, proxy=nil)
40
+ TeamForge.request(self, server, proxy)
41
+ end
42
+ end
43
+ CopyWorkflowTransitions = Struct.new(:session_id, :src_tracker_id, :dst_tracker_id) do
44
+ def send (server=nil, proxy=nil)
45
+ TeamForge.request(self, server, proxy)
46
+ end
47
+ end
48
+ CreateArtifact2 = Struct.new(:session_id, :tracker_id, :title, :description, :group, :category, :status, :customer, :priority, :estimated_effort, :remaining_effort, :autosumming, :points, :assigned_username, :release_id, :planning_folder_id, :flex_fields, :attachments) do
49
+ def send (server=nil, proxy=nil)
50
+ TeamForge.request(self, server, proxy)
51
+ end
52
+ end
53
+ CreateArtifactDependency = Struct.new(:session_id, :origin_id, :target_id, :desc) do
54
+ def send (server=nil, proxy=nil)
55
+ TeamForge.request(self, server, proxy)
56
+ end
57
+ end
58
+ CreateArtifact = Struct.new(:session_id, :tracker_id, :title, :description, :group, :category, :status, :customer, :priority, :estimated_effort, :remaining_effort, :autosumming, :points, :assigned_username, :release_id, :planning_folder_id, :flex_fields, :attachment_file_name, :attachment_mime_type, :attachment_file_id) do
59
+ def send (server=nil, proxy=nil)
60
+ TeamForge.request(self, server, proxy)
61
+ end
62
+ end
63
+ CreateTracker2 = Struct.new(:session_id, :project_id, :tracker_name, :tracker_title, :tracker_description, :icon, :tracker_unit_id) do
64
+ def send (server=nil, proxy=nil)
65
+ TeamForge.request(self, server, proxy)
66
+ end
67
+ end
68
+ CreateTracker = Struct.new(:session_id, :project_id, :tracker_name, :tracker_title, :tracker_description, :icon) do
69
+ def send (server=nil, proxy=nil)
70
+ TeamForge.request(self, server, proxy)
71
+ end
72
+ end
73
+ DeleteArtifact = Struct.new(:session_id, :artifact_id) do
74
+ def send (server=nil, proxy=nil)
75
+ TeamForge.request(self, server, proxy)
76
+ end
77
+ end
78
+ DeleteField = Struct.new(:session_id, :object_id, :field_id) do
79
+ def send (server=nil, proxy=nil)
80
+ TeamForge.request(self, server, proxy)
81
+ end
82
+ end
83
+ DeleteSeparator = Struct.new(:session_id, :tracker_id, :layout_id) do
84
+ def send (server=nil, proxy=nil)
85
+ TeamForge.request(self, server, proxy)
86
+ end
87
+ end
88
+ FindArtifacts = Struct.new(:session_id, :query_string, :project_id, :search_attachments) do
89
+ def send (server=nil, proxy=nil)
90
+ TeamForge.request(self, server, proxy)
91
+ end
92
+ end
93
+ GetAllowedWorkflowTransitionList = Struct.new(:session_id, :tracker_id) do
94
+ def send (server=nil, proxy=nil)
95
+ TeamForge.request(self, server, proxy)
96
+ end
97
+ end
98
+ GetArtifactData = Struct.new(:session_id, :artifact_id) do
99
+ def send (server=nil, proxy=nil)
100
+ TeamForge.request(self, server, proxy)
101
+ end
102
+ end
103
+ GetArtifactDetailList = Struct.new(:session_id, :tracker_id, :selected_columns, :filters, :sort_keys, :start_index, :max_rows, :exception_if_expired_cache, :force_new_query) do
104
+ def send (server=nil, proxy=nil)
105
+ TeamForge.request(self, server, proxy)
106
+ end
107
+ end
108
+ GetArtifactList = Struct.new(:session_id, :container_id, :filters) do
109
+ def send (server=nil, proxy=nil)
110
+ TeamForge.request(self, server, proxy)
111
+ end
112
+ end
113
+ GetChildDependencyList = Struct.new(:session_id, :artifact_id) do
114
+ def send (server=nil, proxy=nil)
115
+ TeamForge.request(self, server, proxy)
116
+ end
117
+ end
118
+ GetCrossTrackerArtifactList = Struct.new(:session_id, :container_id, :filters, :selected_columns) do
119
+ def send (server=nil, proxy=nil)
120
+ TeamForge.request(self, server, proxy)
121
+ end
122
+ end
123
+ GetFields = Struct.new(:session_id, :tracker_id) do
124
+ def send (server=nil, proxy=nil)
125
+ TeamForge.request(self, server, proxy)
126
+ end
127
+ end
128
+ GetOrderedTrackerFields = Struct.new(:session_id, :tracker_id) do
129
+ def send (server=nil, proxy=nil)
130
+ TeamForge.request(self, server, proxy)
131
+ end
132
+ end
133
+ GetParentDependencyList = Struct.new(:session_id, :artifact_id) do
134
+ def send (server=nil, proxy=nil)
135
+ TeamForge.request(self, server, proxy)
136
+ end
137
+ end
138
+ GetTracker2Data = Struct.new(:session_id, :tracker_id) do
139
+ def send (server=nil, proxy=nil)
140
+ TeamForge.request(self, server, proxy)
141
+ end
142
+ end
143
+ GetTracker2List = Struct.new(:session_id, :project_id) do
144
+ def send (server=nil, proxy=nil)
145
+ TeamForge.request(self, server, proxy)
146
+ end
147
+ end
148
+ GetTrackerData = Struct.new(:session_id, :tracker_id) do
149
+ def send (server=nil, proxy=nil)
150
+ TeamForge.request(self, server, proxy)
151
+ end
152
+ end
153
+ GetTrackerList = Struct.new(:session_id, :project_id) do
154
+ def send (server=nil, proxy=nil)
155
+ TeamForge.request(self, server, proxy)
156
+ end
157
+ end
158
+ GetUnitsByProject = Struct.new(:session_id, :project_id) do
159
+ def send (server=nil, proxy=nil)
160
+ TeamForge.request(self, server, proxy)
161
+ end
162
+ end
163
+ MoveArtifact = Struct.new(:session_id, :artifact_id, :target_folder_id, :new_assignee) do
164
+ def send (server=nil, proxy=nil)
165
+ TeamForge.request(self, server, proxy)
166
+ end
167
+ end
168
+ RemoveArtifactDependency = Struct.new(:session_id, :origin_id, :target_id) do
169
+ def send (server=nil, proxy=nil)
170
+ TeamForge.request(self, server, proxy)
171
+ end
172
+ end
173
+ ReorderTrackerFields = Struct.new(:session_id, :tracker_id, :layout_ids) do
174
+ def send (server=nil, proxy=nil)
175
+ TeamForge.request(self, server, proxy)
176
+ end
177
+ end
178
+ ReorderTrackers = Struct.new(:session_id, :tracker_ids) do
179
+ def send (server=nil, proxy=nil)
180
+ TeamForge.request(self, server, proxy)
181
+ end
182
+ end
183
+ SetArtifactData2 = Struct.new(:session_id, :artifact_data, :comment, :attachments) do
184
+ def send (server=nil, proxy=nil)
185
+ TeamForge.request(self, server, proxy)
186
+ end
187
+ end
188
+ SetArtifactData = Struct.new(:session_id, :artifact_data, :comment, :attachment_file_name, :attachment_mime_type, :attachment_file_id) do
189
+ def send (server=nil, proxy=nil)
190
+ TeamForge.request(self, server, proxy)
191
+ end
192
+ end
193
+ SetArtifactRank = Struct.new(:session_id, :planning_folder_id, :artf_to_rank_id, :artf_before_id, :artf_after_id) do
194
+ def send (server=nil, proxy=nil)
195
+ TeamForge.request(self, server, proxy)
196
+ end
197
+ end
198
+ SetField = Struct.new(:session_id, :object_id, :field_data) do
199
+ def send (server=nil, proxy=nil)
200
+ TeamForge.request(self, server, proxy)
201
+ end
202
+ end
203
+ SetTracker2Data = Struct.new(:session_id, :tracker_data) do
204
+ def send (server=nil, proxy=nil)
205
+ TeamForge.request(self, server, proxy)
206
+ end
207
+ end
208
+ SetTrackerData = Struct.new(:session_id, :tracker_data) do
209
+ def send (server=nil, proxy=nil)
210
+ TeamForge.request(self, server, proxy)
211
+ end
212
+ end
213
+
214
+
215
+ ######################
216
+ # TrackerApp Types
217
+ ######################
218
+
219
+ ArtifactDependencySoapRow = Struct.new(:description,:has_view_permission,:origin_id,:origin_status,:origin_status_class,:origin_title,:target_id,:target_status,:target_status_class,:target_title,:tracker_icon, :attributes!)
220
+ ArtifactDetailSoapRow = Struct.new(:actual_effort,:artifact_group,:assigned_to_fullname,:assigned_to_username,:autosumming,:category,:close_date,:customer,:description,:estimated_effort,:flex_fields,:folder_id,:folder_path_string,:folder_title,:id,:last_modified_date,:planning_folder_id,:planning_folder_title,:points,:priority,:project_id,:project_path_string,:project_title,:remaining_effort,:reported_in_release_id,:reported_in_release_title,:resolved_in_release_id,:resolved_in_release_title,:status,:status_class,:submitted_by_fullname,:submitted_by_username,:submitted_date,:title,:tracker_icon,:version, :attributes!)
221
+ ArtifactSoapDO = Struct.new(:actual_effort,:assigned_to,:autosumming,:category,:close_date,:created_by,:created_date,:customer,:description,:estimated_effort,:flex_fields,:folder_id,:group,:id,:last_modified_by,:last_modified_date,:path,:planning_folder_id,:points,:priority,:remaining_effort,:reported_release_id,:resolved_release_id,:status,:status_class,:title,:version, :attributes!)
222
+ ArtifactSoapRow = Struct.new(:actual_effort,:artifact_group,:assigned_to_fullname,:assigned_to_username,:autosumming,:category,:close_date,:customer,:description,:estimated_effort,:folder_id,:folder_path_string,:folder_title,:id,:last_modified_date,:planning_folder_id,:points,:priority,:project_id,:project_path_string,:project_title,:remaining_effort,:status,:status_class,:submitted_by_fullname,:submitted_by_username,:submitted_date,:title,:version, :attributes!)
223
+ AttachmentSoapDO = Struct.new(:attachment_file_id,:attachment_file_name,:attachment_mime_type,:created_by,:created_date,:id,:last_modified_by,:last_modified_date,:version, :attributes!)
224
+ OrderedTrackerFieldSoapRow = Struct.new(:default_text_value,:default_usernames,:disabled,:display_lines,:display_order,:display_size,:field_display_type,:field_id,:field_name,:field_values,:folder_id,:help_text,:hidden_on_create,:label,:layout_id,:parent_childfield_value_map,:parent_field_id,:pattern,:required,:user_filter,:value_type, :attributes!)
225
+ SoapFieldValues = Struct.new(:names,:types,:values, :attributes!)
226
+ SoapFilter = Struct.new(:name,:value, :attributes!)
227
+ SoapNamedValues = Struct.new(:names,:values, :attributes!)
228
+ SoapSortKey = Struct.new(:ascending,:name, :attributes!)
229
+ Tracker2SoapDO = Struct.new(:assignments,:auto_assign_field,:created_by,:created_date,:description,:icon,:id,:last_modified_by,:last_modified_date,:parent_folder_id,:path,:project_id,:title,:tracker_unit_id,:version, :attributes!)
230
+ Tracker2SoapRow = Struct.new(:created_by,:created_on,:description,:icon,:id,:last_edited_by_fullname,:last_edited_by_username,:last_edited_date,:last_modified_by,:last_modified_on,:parent_folder_id,:path,:project_id,:title,:tracker_unit_id, :attributes!)
231
+ TrackerFieldSoapDO = Struct.new(:created_by,:created_date,:default_text_value,:default_usernames,:disabled,:display_lines,:display_size,:field_type,:field_values,:help_text,:hidden_on_create,:id,:last_modified_by,:last_modified_date,:name,:parent_child_field_value_map,:parent_field_id,:pattern,:required,:user_filter,:value_type,:version, :attributes!)
232
+ TrackerFieldValueSoapDO = Struct.new(:id,:is_default,:value,:value_class, :attributes!)
233
+ TrackerSoapDO = Struct.new(:assignments,:auto_assign_field,:created_by,:created_date,:description,:icon,:id,:last_modified_by,:last_modified_date,:parent_folder_id,:path,:project_id,:title,:version, :attributes!)
234
+ TrackerSoapRow = Struct.new(:created_by,:created_on,:description,:icon,:id,:last_edited_by_fullname,:last_edited_by_username,:last_edited_date,:last_modified_by,:last_modified_on,:parent_folder_id,:path,:project_id,:title, :attributes!)
235
+ TrackerUnitSoapRow = Struct.new(:base_unit_multiplier,:conversion_unit_id,:conversion_unit_multiplier,:display_order,:id,:last_edited_date,:name,:project_id,:version, :attributes!)
236
+ WorkflowTransitionSoapRow = Struct.new(:display_order,:from_status_name,:required_fields,:to_status_name, :attributes!)
237
+
238
+ end # module TrackerApp
239
+
240
+
241
+ end # module TeamForge
@@ -0,0 +1,66 @@
1
+
2
+ module TeamForge
3
+ module WikiApp
4
+
5
+ ######################
6
+ # WikiApp Messages
7
+ ######################
8
+ AddAttachment = Struct.new(:session_id, :wiki_page_id, :file_id, :filename, :mimetype) do
9
+ def send (server=nil, proxy=nil)
10
+ TeamForge.request(self, server, proxy)
11
+ end
12
+ end
13
+ AddAttachments = Struct.new(:session_id, :wiki_page_id, :attachments) do
14
+ def send (server=nil, proxy=nil)
15
+ TeamForge.request(self, server, proxy)
16
+ end
17
+ end
18
+ CreateWikiPage = Struct.new(:session_id, :project_id, :name, :wiki_text, :version_comment) do
19
+ def send (server=nil, proxy=nil)
20
+ TeamForge.request(self, server, proxy)
21
+ end
22
+ end
23
+ DeleteWikiPage = Struct.new(:session_id, :wiki_page_id) do
24
+ def send (server=nil, proxy=nil)
25
+ TeamForge.request(self, server, proxy)
26
+ end
27
+ end
28
+ GetFormattedWikiPageText = Struct.new(:session_id, :wiki_page_id) do
29
+ def send (server=nil, proxy=nil)
30
+ TeamForge.request(self, server, proxy)
31
+ end
32
+ end
33
+ GetWikiPageDataByName = Struct.new(:session_id, :project_id, :wiki_page_name) do
34
+ def send (server=nil, proxy=nil)
35
+ TeamForge.request(self, server, proxy)
36
+ end
37
+ end
38
+ GetWikiPageData = Struct.new(:session_id, :wiki_page_id) do
39
+ def send (server=nil, proxy=nil)
40
+ TeamForge.request(self, server, proxy)
41
+ end
42
+ end
43
+ GetWikiPageList = Struct.new(:session_id, :project_id) do
44
+ def send (server=nil, proxy=nil)
45
+ TeamForge.request(self, server, proxy)
46
+ end
47
+ end
48
+ SetWikiPageData = Struct.new(:session_id, :wiki_page_data) do
49
+ def send (server=nil, proxy=nil)
50
+ TeamForge.request(self, server, proxy)
51
+ end
52
+ end
53
+
54
+
55
+ ######################
56
+ # WikiApp Types
57
+ ######################
58
+
59
+ AttachmentSoapDO = Struct.new(:attachment_file_id,:attachment_file_name,:attachment_mime_type,:created_by,:created_date,:id,:last_modified_by,:last_modified_date,:version, :attributes!)
60
+ WikiPageSoapDO = Struct.new(:created_by,:created_date,:date_version_created,:folder_id,:id,:last_modified_by,:last_modified_date,:path,:title,:version,:version_comment,:version_created_by,:wiki_page_version,:wiki_text, :attributes!)
61
+ WikiPageSoapRow = Struct.new(:date_version_created,:id,:version_created_by,:wiki_page_name,:wiki_page_version, :attributes!)
62
+
63
+ end # module WikiApp
64
+
65
+
66
+ end # module TeamForge
@@ -0,0 +1,5 @@
1
+ module TeamForge
2
+
3
+ VERSION = "0.0.4"
4
+
5
+ end
data/lib/teamforge.rb ADDED
@@ -0,0 +1,64 @@
1
+ require "savon"
2
+ require "time"
3
+ require "teamforge/ctfsoap"
4
+ require "teamforge/version"
5
+ require "teamforge/services/collabnet"
6
+
7
+
8
+ module TeamForge
9
+
10
+ SERVICE_NAMESPACE="http://schema.open.collab.net/sfee50/soap60/service"
11
+ TYPE_NAMESPACE="http://schema.open.collab.net/sfee50/soap60/type"
12
+ SOAP_NAMESPACE="http://schemas.xmlsoap.org/soap/encoding/"
13
+ SERVICE_PATH="/ce-soap60/services/"
14
+
15
+
16
+ autoload :TrackerApp, "teamforge/services/trackerapp"
17
+ autoload :WikiApp, "teamforge/services/wikiapp"
18
+ autoload :FrsApp, "teamforge/services/frsapp"
19
+ autoload :ScmApp, "teamforge/services/scmapp"
20
+ autoload :PlanningApp, "teamforge/services/planningapp"
21
+ autoload :DiscussionApp, "teamforge/services/discussionapp"
22
+ autoload :CategorizationApp, "teamforge/services/categorizationapp"
23
+ autoload :DocumentApp, "teamforge/services/documentapp"
24
+ autoload :RbacApp, "teamforge/services/rbacapp"
25
+ autoload :SimpleFileStorageApp, "teamforge/services/simplefilestorageapp"
26
+ autoload :IntegrationDataApp, "teamforge/services/integrationdataapp"
27
+ autoload :PluggableApp, "teamforge/services/pluggableapp"
28
+
29
+ def self.proxy
30
+ @proxy
31
+ end
32
+
33
+ def self.proxy=(proxy)
34
+ @proxy=format_url(proxy)
35
+ end
36
+
37
+ def self.server
38
+ @ctfserver
39
+ end
40
+
41
+ def self.server=(server)
42
+ @server=format_url(server)
43
+ end
44
+
45
+ def self.format_url(url)
46
+ url = "http://#{url}" unless /^http?/ =~ url
47
+ url = url.gsub(/\/+$/, '')
48
+ end
49
+
50
+ # Currently, this SDK wrapper uses Savon to send and receive soap messages. Only the Client is being used currently but not any of the parsers. Adapting to a different HTTP library would be fairly simple.
51
+ # When loaded, Savon logging is turned off as is HTTPI logging. Otherwise, by default Savon writes all messages to Stdout.
52
+ Savon.configure do |config|
53
+ config.log = false # disable logging
54
+ config.log_level = :info # changing the log level
55
+ end
56
+ HTTPI.log = false # disable HTTPI logging
57
+
58
+ # Error to indicate problems accessing a CTF server
59
+ class TeamForgeError < RuntimeError; end
60
+
61
+
62
+ end
63
+
64
+
metadata ADDED
@@ -0,0 +1,77 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: teamforge
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.4
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Patrick Wolf
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2013-04-05 00:00:00.000000000Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: savon
16
+ requirement: &2151762820 !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: 1.2.0
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: *2151762820
25
+ description: A SOAP wrapper to communicate with TeamForge WebServices
26
+ email: pwolf@collab.net
27
+ executables: []
28
+ extensions: []
29
+ extra_rdoc_files:
30
+ - README.rdoc
31
+ files:
32
+ - lib/teamforge/ctfsoap.rb
33
+ - lib/teamforge/services/categorizationapp.rb
34
+ - lib/teamforge/services/collabnet.rb
35
+ - lib/teamforge/services/discussionapp.rb
36
+ - lib/teamforge/services/documentapp.rb
37
+ - lib/teamforge/services/frsapp.rb
38
+ - lib/teamforge/services/integrationdataapp.rb
39
+ - lib/teamforge/services/newsapp.rb
40
+ - lib/teamforge/services/pageapp.rb
41
+ - lib/teamforge/services/planningapp.rb
42
+ - lib/teamforge/services/pluggableapp.rb
43
+ - lib/teamforge/services/rbacapp.rb
44
+ - lib/teamforge/services/scmapp.rb
45
+ - lib/teamforge/services/simplefilestorageapp.rb
46
+ - lib/teamforge/services/taskapp.rb
47
+ - lib/teamforge/services/trackerapp.rb
48
+ - lib/teamforge/services/wikiapp.rb
49
+ - lib/teamforge/version.rb
50
+ - lib/teamforge.rb
51
+ - MIT-LICENSE
52
+ - README.rdoc
53
+ homepage: http://collab.net/
54
+ licenses: []
55
+ post_install_message:
56
+ rdoc_options: []
57
+ require_paths:
58
+ - lib
59
+ required_ruby_version: !ruby/object:Gem::Requirement
60
+ none: false
61
+ requirements:
62
+ - - ! '>='
63
+ - !ruby/object:Gem::Version
64
+ version: '0'
65
+ required_rubygems_version: !ruby/object:Gem::Requirement
66
+ none: false
67
+ requirements:
68
+ - - ! '>='
69
+ - !ruby/object:Gem::Version
70
+ version: '0'
71
+ requirements: []
72
+ rubyforge_project:
73
+ rubygems_version: 1.8.17
74
+ signing_key:
75
+ specification_version: 3
76
+ summary: CollabNet TeamForge
77
+ test_files: []