Module: Groupwise

Defined in:
lib/groupwise.rb,
lib/groupwise/version.rb,
lib/groupwise/post_office_agent.rb,
lib/groupwise/free_busy_session_message.rb

Defined Under Namespace

Classes: FreeBusySessionMessage, PostOfficeAgent

Constant Summary collapse

VERSION =
"0.0.1"

Class Method Summary collapse

Class Method Details

.wsdl_version(version) ⇒ Object



8
9
10
11
12
13
14
15
# File 'lib/groupwise.rb', line 8

def self.wsdl_version(version)
  version = version.tr('.','').to_i
  dir = File.expand_path('../../contrib/novell/GW*', __FILE__)
  versions = Dir[dir].map do |dir|    
    dir.match(/(?<=GW)([^\n\r]*)/).captures.first.to_i
  end
  versions.min{|a,b|  (version-a).abs <=> (version-b).abs }.to_s
end