viewpoint 0.1.27 → 1.0.0.beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. data/README.md +196 -0
  2. data/lib/ews/calendar_accessors.rb +34 -0
  3. data/lib/ews/connection.rb +117 -0
  4. data/lib/ews/connection_helper.rb +35 -0
  5. data/lib/ews/ews_client.rb +71 -0
  6. data/lib/ews/exceptions/exceptions.rb +59 -0
  7. data/lib/ews/folder_accessors.rb +199 -0
  8. data/lib/ews/item_accessors.rb +157 -0
  9. data/lib/ews/mailbox_accessors.rb +87 -0
  10. data/lib/ews/message_accessors.rb +86 -0
  11. data/lib/ews/push_subscription_accessors.rb +33 -0
  12. data/lib/ews/soap.rb +63 -0
  13. data/lib/ews/soap/builders/ews_builder.rb +1011 -0
  14. data/lib/ews/soap/ews_response.rb +83 -0
  15. data/lib/ews/soap/ews_soap_availability_response.rb +58 -0
  16. data/lib/ews/soap/ews_soap_free_busy_response.rb +109 -0
  17. data/lib/ews/soap/ews_soap_response.rb +103 -0
  18. data/lib/ews/soap/exchange_availability.rb +61 -0
  19. data/lib/ews/soap/exchange_data_services.rb +742 -0
  20. data/lib/ews/soap/exchange_notification.rb +146 -0
  21. data/lib/ews/soap/exchange_user_configuration.rb +33 -0
  22. data/lib/ews/soap/exchange_web_service.rb +294 -0
  23. data/lib/{model/attendee.rb → ews/soap/parsers/ews_parser.rb} +20 -14
  24. data/lib/ews/soap/parsers/ews_sax_document.rb +66 -0
  25. data/lib/ews/soap/response_message.rb +78 -0
  26. data/lib/ews/soap/responses/create_attachment_response_message.rb +46 -0
  27. data/lib/{model/meeting_message.rb → ews/soap/responses/create_item_response_message.rb} +7 -10
  28. data/lib/ews/soap/responses/find_item_response_message.rb +80 -0
  29. data/lib/ews/soap/responses/get_events_response_message.rb +53 -0
  30. data/lib/ews/soap/responses/send_notification_response_message.rb +58 -0
  31. data/lib/{model/attachment.rb → ews/soap/responses/subscribe_response_message.rb} +17 -13
  32. data/lib/ews/templates/forward_item.rb +24 -0
  33. data/lib/ews/templates/message.rb +66 -0
  34. data/lib/ews/templates/reply_to_item.rb +25 -0
  35. data/lib/ews/types.rb +146 -0
  36. data/lib/ews/types/attachment.rb +77 -0
  37. data/lib/{model/meeting_cancellation.rb → ews/types/attendee.rb} +9 -8
  38. data/lib/ews/types/calendar_folder.rb +8 -0
  39. data/lib/ews/types/calendar_item.rb +37 -0
  40. data/lib/ews/types/contact.rb +7 -0
  41. data/lib/ews/types/contacts_folder.rb +8 -0
  42. data/lib/ews/types/copied_event.rb +51 -0
  43. data/lib/{soap/handsoap/builder.rb → ews/types/created_event.rb} +5 -2
  44. data/lib/{model/meeting_response.rb → ews/types/deleted_event.rb} +6 -6
  45. data/lib/ews/types/distribution_list.rb +7 -0
  46. data/lib/ews/types/event.rb +62 -0
  47. data/lib/ews/types/file_attachment.rb +65 -0
  48. data/lib/ews/types/folder.rb +60 -0
  49. data/lib/{model/distribution_list.rb → ews/types/free_busy_changed_event.rb} +6 -6
  50. data/lib/ews/types/generic_folder.rb +352 -0
  51. data/lib/ews/types/item.rb +381 -0
  52. data/lib/ews/types/item_attachment.rb +46 -0
  53. data/lib/{model → ews/types}/item_field_uri_map.rb +2 -2
  54. data/lib/ews/types/mailbox_user.rb +156 -0
  55. data/lib/ews/types/meeting_cancellation.rb +7 -0
  56. data/lib/ews/types/meeting_message.rb +7 -0
  57. data/lib/ews/types/meeting_request.rb +7 -0
  58. data/lib/ews/types/meeting_response.rb +7 -0
  59. data/lib/ews/types/message.rb +7 -0
  60. data/lib/ews/types/modified_event.rb +48 -0
  61. data/lib/{model/item_attachment.rb → ews/types/moved_event.rb} +33 -15
  62. data/lib/ews/types/new_mail_event.rb +24 -0
  63. data/lib/ews/types/out_of_office.rb +147 -0
  64. data/lib/ews/types/search_folder.rb +8 -0
  65. data/lib/ews/types/status_event.rb +39 -0
  66. data/lib/ews/types/task.rb +7 -0
  67. data/lib/ews/types/tasks_folder.rb +8 -0
  68. data/lib/viewpoint.rb +82 -106
  69. metadata +99 -67
  70. data/README +0 -114
  71. data/lib/exceptions/exceptions.rb +0 -46
  72. data/lib/model/calendar_folder.rb +0 -67
  73. data/lib/model/calendar_item.rb +0 -267
  74. data/lib/model/contact.rb +0 -238
  75. data/lib/model/contacts_folder.rb +0 -46
  76. data/lib/model/event.rb +0 -116
  77. data/lib/model/file_attachment.rb +0 -53
  78. data/lib/model/folder.rb +0 -47
  79. data/lib/model/generic_folder.rb +0 -471
  80. data/lib/model/item.rb +0 -313
  81. data/lib/model/mailbox_user.rb +0 -146
  82. data/lib/model/meeting_request.rb +0 -39
  83. data/lib/model/message.rb +0 -142
  84. data/lib/model/model.rb +0 -269
  85. data/lib/model/search_folder.rb +0 -48
  86. data/lib/model/task.rb +0 -121
  87. data/lib/model/tasks_folder.rb +0 -44
  88. data/lib/soap/handsoap/builders/ews_build_helpers.rb +0 -383
  89. data/lib/soap/handsoap/builders/ews_builder.rb +0 -146
  90. data/lib/soap/handsoap/ews_service.rb +0 -813
  91. data/lib/soap/handsoap/parser.rb +0 -104
  92. data/lib/soap/handsoap/parsers/ews_parser.rb +0 -246
  93. data/lib/soap/soap_provider.rb +0 -64
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class MeetingCancellation
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class MeetingMessage
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class MeetingRequest
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class MeetingResponse
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class Message
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,48 @@
1
+ =begin
2
+ This file is part of Viewpoint; the Ruby library for Microsoft Exchange Web Services.
3
+
4
+ Copyright © 2011 Dan Wanek <dan.wanek@gmail.com>
5
+
6
+ Licensed under the Apache License, Version 2.0 (the "License");
7
+ you may not use this file except in compliance with the License.
8
+ You may obtain a copy of the License at
9
+
10
+ http://www.apache.org/licenses/LICENSE-2.0
11
+
12
+ Unless required by applicable law or agreed to in writing, software
13
+ distributed under the License is distributed on an "AS IS" BASIS,
14
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ See the License for the specific language governing permissions and
16
+ limitations under the License.
17
+ =end
18
+
19
+ module Viewpoint::EWS::Types
20
+
21
+ class ModifiedEvent < Event
22
+
23
+ MODIFIED_EVENT_KEY_PATHS = {
24
+ }
25
+
26
+ MODIFIED_EVENT_KEY_TYPES = {
27
+ }
28
+
29
+ MODIFIED_EVENT_KEY_ALIAS = { }
30
+
31
+
32
+ private
33
+
34
+
35
+ def key_paths
36
+ @key_paths ||= super.merge MODIFIED_EVENT_KEY_PATHS
37
+ end
38
+
39
+ def key_types
40
+ @key_types ||= super.merge MODIFIED_EVENT_KEY_TYPES
41
+ end
42
+
43
+ def key_alias
44
+ @key_alias ||= super.merge MODIFIED_EVENT_KEY_ALIAS
45
+ end
46
+
47
+ end
48
+ end
@@ -16,18 +16,36 @@
16
16
  limitations under the License.
17
17
  =end
18
18
 
19
- module Viewpoint
20
- module EWS
21
- # An attachment that represents an attachment to another Exchange Item.
22
- # This is not yet implemented.
23
- class ItemAttachment < Attachment
24
-
25
- # @param [String] attachment_id The unique ID for the attachment.
26
- def initialize(attachment_id)
27
- #raise EwsNotImplemented, "ItemAttachments are not yet implemented in Viewpoint"
28
- warn "ItemAttachments are not yet implemented in Viewpoint"
29
- end
30
-
31
- end # ItemAttachment
32
- end # EWS
33
- end # Viewpoint
19
+ module Viewpoint::EWS::Types
20
+
21
+ class MovedEvent < Event
22
+
23
+ MOVED_EVENT_KEY_PATHS = {
24
+ :old_item_id => [:old_item_id, :attribs],
25
+ :old_folder_id => [:old_folder_id, :attribs],
26
+ :old_parent_folder_id => [:old_parent_folder_id, :attribs],
27
+ }
28
+
29
+ MOVED_EVENT_KEY_TYPES = {
30
+ }
31
+
32
+ MOVED_EVENT_KEY_ALIAS = { }
33
+
34
+
35
+ private
36
+
37
+
38
+ def key_paths
39
+ @key_paths ||= super.merge MOVED_EVENT_KEY_PATHS
40
+ end
41
+
42
+ def key_types
43
+ @key_types ||= super.merge MOVED_EVENT_KEY_TYPES
44
+ end
45
+
46
+ def key_alias
47
+ @key_alias ||= super.merge MOVED_EVENT_KEY_ALIAS
48
+ end
49
+
50
+ end
51
+ end
@@ -0,0 +1,24 @@
1
+ =begin
2
+ This file is part of Viewpoint; the Ruby library for Microsoft Exchange Web Services.
3
+
4
+ Copyright © 2011 Dan Wanek <dan.wanek@gmail.com>
5
+
6
+ Licensed under the Apache License, Version 2.0 (the "License");
7
+ you may not use this file except in compliance with the License.
8
+ You may obtain a copy of the License at
9
+
10
+ http://www.apache.org/licenses/LICENSE-2.0
11
+
12
+ Unless required by applicable law or agreed to in writing, software
13
+ distributed under the License is distributed on an "AS IS" BASIS,
14
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ See the License for the specific language governing permissions and
16
+ limitations under the License.
17
+ =end
18
+
19
+ module Viewpoint::EWS::Types
20
+
21
+ class NewMailEvent < Event
22
+
23
+ end
24
+ end
@@ -0,0 +1,147 @@
1
+ =begin
2
+ This file is part of Viewpoint; the Ruby library for Microsoft Exchange Web Services.
3
+
4
+ Copyright © 2011 Dan Wanek <dan.wanek@gmail.com>
5
+
6
+ Licensed under the Apache License, Version 2.0 (the "License");
7
+ you may not use this file except in compliance with the License.
8
+ You may obtain a copy of the License at
9
+
10
+ http://www.apache.org/licenses/LICENSE-2.0
11
+
12
+ Unless required by applicable law or agreed to in writing, software
13
+ distributed under the License is distributed on an "AS IS" BASIS,
14
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ See the License for the specific language governing permissions and
16
+ limitations under the License.
17
+ =end
18
+
19
+ module Viewpoint::EWS::Types
20
+
21
+ OOF_KEY_PATHS = {
22
+ :enabled? => [:oof_settings, :oof_state],
23
+ :scheduled? => [:oof_settings, :oof_state],
24
+ :duration => [:oof_settings, :duration],
25
+ }
26
+
27
+ OOF_KEY_TYPES = {
28
+ :enabled? => ->(str){str == :enabled},
29
+ :scheduled? => ->(str){str == :scheduled},
30
+ :duration => ->(hsh){ hsh[:start_time]..hsh[:end_time] },
31
+ }
32
+
33
+ OOF_KEY_ALIAS = {}
34
+
35
+ # This represents OutOfOffice settings
36
+ # @see http://msdn.microsoft.com/en-us/library/aa563465.aspx
37
+ class OutOfOffice
38
+ include Viewpoint::EWS
39
+ include Viewpoint::EWS::Types
40
+
41
+ attr_reader :user
42
+
43
+ # @param [MailboxUser] user
44
+ # @param [Hash] ews_item
45
+ def initialize(user, ews_item)
46
+ @ews = user.ews
47
+ @user = user
48
+ @ews_item = ews_item
49
+ @changed = false
50
+ simplify!
51
+ end
52
+
53
+ def changed?
54
+ @changed
55
+ end
56
+
57
+ def save!
58
+ return true unless changed?
59
+ opts = { mailbox: {address: user.email_address} }.merge(@ews_item[:oof_settings])
60
+ resp = @ews.set_user_oof_settings(opts)
61
+ if resp.success?
62
+ @changed = false
63
+ true
64
+ else
65
+ raise SaveFailed, "Could not save #{self.class}. #{resp.code}: #{resp.message}"
66
+ end
67
+ end
68
+
69
+ def enable
70
+ return true if enabled?
71
+ @changed = true
72
+ @ews_item[:oof_settings][:oof_state] = :enabled
73
+ end
74
+
75
+ def disable
76
+ return true unless enabled? || scheduled?
77
+ @changed = true
78
+ @ews_item[:oof_settings][:oof_state] = :disabled
79
+ end
80
+
81
+ # Schedule an out of office.
82
+ # @param [DateTime] start_time
83
+ # @param [DateTime] end_time
84
+ def schedule(start_time, end_time)
85
+ @changed = true
86
+ @ews_item[:oof_settings][:oof_state] = :scheduled
87
+ set_duration start_time, end_time
88
+ end
89
+
90
+ # Specify a duration for this Out Of Office setting
91
+ # @param [DateTime] start_time
92
+ # @param [DateTime] end_time
93
+ def set_duration(start_time, end_time)
94
+ @changed = true
95
+ @ews_item[:oof_settings][:duration][:start_time] = start_time
96
+ @ews_item[:oof_settings][:duration][:end_time] = end_time
97
+ end
98
+
99
+ # A message to send to internal users
100
+ # @param [String] message
101
+ def internal_reply=(message)
102
+ @changed = true
103
+ @ews_item[:oof_settings][:internal_reply] = message
104
+ end
105
+
106
+ # A message to send to external users
107
+ # @param [String] message
108
+ def external_reply=(message)
109
+ @changed = true
110
+ @ews_item[:oof_settings][:external_reply] = message
111
+ end
112
+
113
+
114
+ private
115
+
116
+ def key_paths
117
+ @key_paths ||= super.merge(OOF_KEY_PATHS)
118
+ end
119
+
120
+ def key_types
121
+ @key_types ||= super.merge(OOF_KEY_TYPES)
122
+ end
123
+
124
+ def key_alias
125
+ @key_alias ||= super.merge(OOF_KEY_ALIAS)
126
+ end
127
+
128
+ def simplify!
129
+ oof_settings = @ews_item[:oof_settings][:elems].inject(:merge)
130
+ oof_settings[:oof_state] = oof_settings[:oof_state][:text].downcase.to_sym
131
+ oof_settings[:external_audience] = oof_settings[:external_audience][:text]
132
+ if oof_settings[:duration]
133
+ dur = oof_settings[:duration][:elems].inject(:merge)
134
+ oof_settings[:duration] = {
135
+ start_time: DateTime.iso8601(dur[:start_time][:text]),
136
+ end_time: DateTime.iso8601(dur[:end_time][:text])
137
+ }
138
+ end
139
+ oof_settings[:internal_reply] = oof_settings[:internal_reply][:elems][0][:message][:text] || ""
140
+ oof_settings[:external_reply] = oof_settings[:external_reply][:elems][0][:message][:text] || ""
141
+ @ews_item[:oof_settings] = oof_settings
142
+ @ews_item[:allow_external_oof] = @ews_item[:allow_external_oof][:text]
143
+ end
144
+
145
+ end #OutOfOffice
146
+
147
+ end
@@ -0,0 +1,8 @@
1
+ module Viewpoint::EWS::Types
2
+ class SearchFolder
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::GenericFolder
6
+
7
+ end
8
+ end
@@ -0,0 +1,39 @@
1
+ =begin
2
+ This file is part of Viewpoint; the Ruby library for Microsoft Exchange Web Services.
3
+
4
+ Copyright © 2011 Dan Wanek <dan.wanek@gmail.com>
5
+
6
+ Licensed under the Apache License, Version 2.0 (the "License");
7
+ you may not use this file except in compliance with the License.
8
+ You may obtain a copy of the License at
9
+
10
+ http://www.apache.org/licenses/LICENSE-2.0
11
+
12
+ Unless required by applicable law or agreed to in writing, software
13
+ distributed under the License is distributed on an "AS IS" BASIS,
14
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ See the License for the specific language governing permissions and
16
+ limitations under the License.
17
+ =end
18
+
19
+ module Viewpoint::EWS::Types
20
+
21
+ class StatusEvent
22
+ include Viewpoint::EWS
23
+ include Viewpoint::EWS::Types
24
+ include Viewpoint::EWS::Types::Item
25
+
26
+ STATUS_EVENT_KEY_PATHS = {
27
+ :watermark => [:watermark, :text],
28
+ }
29
+
30
+
31
+ private
32
+
33
+
34
+ def key_paths
35
+ @key_paths ||= STATUS_EVENT_KEY_PATHS
36
+ end
37
+
38
+ end
39
+ end
@@ -0,0 +1,7 @@
1
+ module Viewpoint::EWS::Types
2
+ class Task
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::Item
6
+ end
7
+ end
@@ -0,0 +1,8 @@
1
+ module Viewpoint::EWS::Types
2
+ class TasksFolder
3
+ include Viewpoint::EWS
4
+ include Viewpoint::EWS::Types
5
+ include Viewpoint::EWS::Types::GenericFolder
6
+
7
+ end
8
+ end
@@ -16,118 +16,94 @@
16
16
  limitations under the License.
17
17
  =end
18
18
 
19
- # We only what one instance of this class so include Singleton
20
- require 'singleton'
19
+ require 'kconv' if(RUBY_VERSION.start_with? '1.9') # bug in rubyntlm with ruby 1.9.x
21
20
  require 'date'
22
21
  require 'base64'
23
- require 'kconv' if(RUBY_VERSION.start_with? '1.9') # bug in rubyntlm with ruby 1.9.x
22
+ require 'nokogiri'
23
+ require 'ostruct'
24
+ require 'logging'
24
25
 
25
-
26
- # Class Extensions
26
+ # Class Extensions (Monkey patches)
27
27
  require 'extensions/string'
28
28
 
29
- # Load the backend SOAP infrastructure. Today this is Handsoap.
30
- require 'soap/soap_provider'
31
-
32
- # Load the model classes
33
- # Base Models
34
- require 'model/model'
35
- require 'model/mailbox_user'
36
- require 'model/attendee'
37
- require 'model/generic_folder'
38
- require 'model/item_field_uri_map' # supports Item
39
- require 'model/item'
40
- # Specific Models
41
- # Folders
42
- require 'model/folder'
43
- require 'model/calendar_folder'
44
- require 'model/contacts_folder'
45
- require 'model/search_folder'
46
- require 'model/tasks_folder'
47
- # Items
48
- require 'model/message'
49
- require 'model/calendar_item'
50
- require 'model/contact'
51
- require 'model/distribution_list'
52
- require 'model/meeting_message'
53
- require 'model/meeting_request'
54
- require 'model/meeting_response'
55
- require 'model/meeting_cancellation'
56
- require 'model/task'
57
- require 'model/attachment'
58
- require 'model/file_attachment'
59
- require 'model/item_attachment'
60
- # Third Party Libraries
61
- require 'mail' # used to convert Message items to RFC822 compliant messages
62
- require 'icalendar' # used to convert Calendar items to iCalendar objects
63
-
64
- # Load the Exception classes
65
- require 'exceptions/exceptions'
66
-
67
-
68
- # This is the Singlenton class that controls access and presentation to Exchange
69
- # Web Services. It is possible to just use the SOAP classes themselves but this
70
- # is what ties all the pieces together.
71
- # @attr_reader [SOAP::ExchangeWebService] :ews The SOAP object used to make calls
72
- # to the Exchange Web Service.
73
29
  module Viewpoint
74
30
  module EWS
75
- # @attr_reader [Viewpoint::EWS::SOAP::ExchangeWebService] :ews The EWS object used
76
- # to make SOAP calls. You typically don't need to use this, but if you want to
77
- # play around with the SOAP back-end it's available.
78
- class EWS
79
- include Singleton
80
- include Viewpoint
81
-
82
- attr_reader :ews
83
-
84
- # Set the endpoint for Exchange Web Services.
85
- # @param [String] endpoint The URL of the endpoint. This should end in
86
- # 'exchange.asmx' and is typically something like this:
87
- # https://myexch/ews/exchange.asmx
88
- # @param [Integer] version The SOAP version to use. This defaults to 1
89
- # and you should not need to pass this parameter.
90
- def self.endpoint=(endpoint, version = 1)
91
- @@endpoint = endpoint
92
- SOAP::ExchangeWebService.endpoint(:uri => endpoint, :version => version) && true
93
- end
94
-
95
- # Fetch the current endpoint
96
- def self.endpoint
97
- @@endpoint
98
- end
99
-
100
- # Set the SOAP username and password.
101
- # @param [String] user The user name
102
- # @param [String] pass The password
103
- def self.set_auth(user,pass)
104
- @@user = user
105
- SOAP::ExchangeWebService.set_auth(user,pass) && true
106
- end
107
-
108
- # Set the http driver that the SOAP back-end will use.
109
- # @param [Symbol] driver The HTTP driver. Available drivers:
110
- # :curb, :net_http, :http_client(Default)
111
- def self.set_http_driver(driver)
112
- Handsoap.http_driver = driver
113
- end
114
-
115
- # Sets the CA path to a certificate or hashed certificate directory.
116
- # This is the same as HTTPClient::SSLConfig.set_trust_ca
117
- # @param [String] ca_path A path to an OpenSSL::X509::Certificate or a 'c-rehash'ed directory
118
- def self.set_trust_ca(ca_path)
119
- SOAP::ExchangeWebService.set_http_options(:trust_ca_file => ca_path) && true
120
- end
121
-
122
- def initialize
123
- @ews = SOAP::ExchangeWebService.new
124
- end
125
-
126
- # The MailboxUser object that represents the user connected to EWS.
127
- def me
128
- MailboxUser.find_user((@@user.include?('@') ? @@user : "#{@@user}@"))
129
- end
130
-
131
- end # class EWS
31
+ attr_reader :logger
32
+ Logging.logger.root.level = :debug
33
+ Logging.logger.root.appenders = Logging.appenders.stdout
34
+
35
+ def self.root_logger
36
+ Logging.logger.root
37
+ end
38
+
132
39
  end # EWS
133
40
  end
41
+
42
+ # Load the Exception classes
43
+ require 'ews/exceptions/exceptions'
44
+
45
+ # Load the backend SOAP / EWS infrastructure.
46
+ require 'ews/soap'
47
+ require 'ews/soap/response_message'
48
+ require 'ews/soap/ews_response'
49
+ require 'ews/soap/ews_soap_response'
50
+ require 'ews/soap/ews_soap_availability_response'
51
+ require 'ews/soap/ews_soap_free_busy_response'
52
+ require 'ews/soap/builders/ews_builder'
53
+ require 'ews/soap/parsers/ews_parser'
54
+ require 'ews/soap/parsers/ews_sax_document'
55
+ # Mix-ins for the ExchangeWebService
56
+ require 'ews/soap/exchange_data_services'
57
+ require 'ews/soap/exchange_notification'
58
+ require 'ews/soap/exchange_availability'
59
+ require 'ews/soap/exchange_user_configuration'
60
+ require 'ews/soap/exchange_web_service'
61
+
62
+ require 'ews/connection_helper'
63
+ require 'ews/connection'
64
+
65
+ # Base Types
66
+ require 'ews/types'
67
+ require 'ews/types/item_field_uri_map'
68
+ require 'ews/types/generic_folder'
69
+ require 'ews/types/item'
70
+ # Folders
71
+ require 'ews/types/folder'
72
+ require 'ews/types/calendar_folder'
73
+ require 'ews/types/contacts_folder'
74
+ require 'ews/types/tasks_folder'
75
+ require 'ews/types/search_folder'
76
+ # Items
77
+ require 'ews/types/message'
78
+ require 'ews/types/calendar_item'
79
+ require 'ews/types/contact'
80
+ require 'ews/types/distribution_list'
81
+ require 'ews/types/meeting_message'
82
+ require 'ews/types/meeting_request'
83
+ require 'ews/types/meeting_response'
84
+ require 'ews/types/meeting_cancellation'
85
+ require 'ews/types/task'
86
+ require 'ews/types/attachment'
87
+ require 'ews/types/file_attachment'
88
+ require 'ews/types/item_attachment'
89
+ require 'ews/types/mailbox_user'
90
+ require 'ews/types/out_of_office'
91
+
92
+ # Events
93
+ require 'ews/types/event'
94
+ require 'ews/types/copied_event'
95
+ require 'ews/types/created_event'
96
+ require 'ews/types/deleted_event'
97
+ require 'ews/types/free_busy_changed_event'
98
+ require 'ews/types/modified_event'
99
+ require 'ews/types/moved_event'
100
+ require 'ews/types/new_mail_event'
101
+ require 'ews/types/status_event'
102
+
103
+ # Template Objects
104
+ require 'ews/templates/message'
105
+ require 'ews/templates/forward_item'
106
+ require 'ews/templates/reply_to_item'
107
+
108
+ # The proxy between the models and the web service
109
+ require 'ews/ews_client'