adobe_connect_api 0.0.36.alpha → 0.0.37.alpha

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,3 @@
1
1
  module AdobeConnectApi
2
- VERSION = "0.0.36.alpha"
2
+ VERSION = "0.0.37.alpha"
3
3
  end
@@ -324,22 +324,25 @@ class AdobeConnectAPI
324
324
  end
325
325
 
326
326
  def search_meeting(name)
327
- action = "sco-search-by-field&query=" + name + "&field=name"
328
- uri = URI.parse(AC_HOST + "/api/xml?action=#{action}")
329
- http = Net::HTTP.new(uri.host, uri.port)
330
- if uri.scheme == "https"
331
- http.use_ssl=true
332
- http.verify_mode = OpenSSL::SSL::VERIFY_NONE
333
- end
334
- request = Net::HTTP::Get.new(uri.request_uri)
335
- if @sessionid
336
- request.add_field("Cookie", "BREEZESESSION="+@sessionid)
337
- end
338
- puts request.path
339
- response = http.request(request)
327
+ res = query("sco-search-by-field",
328
+ "query" => name,
329
+ "field" => "name")
330
+ # action = "sco-search-by-field&query=" + name + "&field=name"
331
+ # uri = URI.parse(AC_HOST + "/api/xml?action=#{action}")
332
+ # http = Net::HTTP.new(uri.host, uri.port)
333
+ # if uri.scheme == "https"
334
+ # http.use_ssl=true
335
+ # http.verify_mode = OpenSSL::SSL::VERIFY_NONE
336
+ # end
337
+ # request = Net::HTTP::Get.new(uri.request_uri)
338
+ # if @sessionid
339
+ # request.add_field("Cookie", "BREEZESESSION="+@sessionid)
340
+ # end
341
+ # puts request.path
342
+ # response = http.request(request)
340
343
 
341
- puts response.body
342
- data = XmlSimple.xml_in(response.body)
344
+ puts res.body
345
+ data = XmlSimple.xml_in(res.body)
343
346
  scos = []
344
347
  if data["sco-search-by-field-info"]
345
348
  results = data["sco-search-by-field-info"][0]
@@ -348,12 +351,20 @@ class AdobeConnectAPI
348
351
  return AdobeConnectAPI::Result.new(data["status"][0]["code"], scos)
349
352
  end
350
353
 
354
+ def update_meeting(sco_id, description, language)
355
+ "action = sco-update&sco-id=&description=&lang="
356
+ res = query("sco-update",
357
+ "sco-id" => sco_id,
358
+ "description" => description,
359
+ "lang" => lang)
360
+ data = XmlSimple.xml_in(res.body)
361
+ return AdobeConnectAPI::Result.new(data["status"][0]["code"], nil)
362
+ end
363
+
351
364
  #sends a query to the server and returns the http response. Parameters,
352
365
  #filter- and sort-definitions can be added. The filter as "filter" => ... and
353
366
  #the sort as "sort" => ...
354
367
  def query(action, hash = {})
355
- puts action
356
- puts hash.inspect
357
368
  # uri = URI.parse("https://130.59.10.31")
358
369
  # http = Net::HTTP.new(uri.host, uri.port)
359
370
  # http.use_ssl = true
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: adobe_connect_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.36.alpha
4
+ version: 0.0.37.alpha
5
5
  prerelease: 7
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2012-09-26 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: xml-simple
16
- requirement: &2164359360 !ruby/object:Gem::Requirement
16
+ requirement: &2153526440 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,7 +21,7 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *2164359360
24
+ version_requirements: *2153526440
25
25
  description: Wrapper to the Adobe Connect API
26
26
  email:
27
27
  - christian.rohrer@switch.ch