evernote_oauth 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +27 -0
- data/README.md +58 -0
- data/evernote_oauth.gemspec +32 -0
- data/lib/evernote_oauth.rb +34 -0
- data/lib/evernote_oauth/client.rb +65 -0
- data/lib/evernote_oauth/note_store.rb +23 -0
- data/lib/evernote_oauth/user_store.rb +29 -0
- data/lib/evernote_oauth/version.rb +3 -0
- data/spec/evernote_oauth/client_spec.rb +55 -0
- data/spec/evernote_oauth/note_store_spec.rb +18 -0
- data/spec/evernote_oauth/user_store_spec.rb +24 -0
- data/spec/spec_helper.rb +6 -0
- data/vendor/evernote.rb +12 -0
- data/vendor/evernote/edam/errors_constants.rb +14 -0
- data/vendor/evernote/edam/errors_types.rb +128 -0
- data/vendor/evernote/edam/limits_constants.rb +240 -0
- data/vendor/evernote/edam/limits_types.rb +13 -0
- data/vendor/evernote/edam/note_store.rb +5487 -0
- data/vendor/evernote/edam/note_store_constants.rb +14 -0
- data/vendor/evernote/edam/note_store_types.rb +1012 -0
- data/vendor/evernote/edam/types_constants.rb +20 -0
- data/vendor/evernote/edam/types_types.rb +1792 -0
- data/vendor/evernote/edam/user_store.rb +549 -0
- data/vendor/evernote/edam/user_store_constants.rb +18 -0
- data/vendor/evernote/edam/user_store_types.rb +415 -0
- metadata +120 -0
@@ -0,0 +1,18 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.8.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'user_store_types'
|
8
|
+
|
9
|
+
module Evernote
|
10
|
+
module EDAM
|
11
|
+
module UserStore
|
12
|
+
EDAM_VERSION_MAJOR = 1
|
13
|
+
|
14
|
+
EDAM_VERSION_MINOR = 21
|
15
|
+
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,415 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.8.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'types_types'
|
8
|
+
require 'errors_types'
|
9
|
+
|
10
|
+
|
11
|
+
module Evernote
|
12
|
+
module EDAM
|
13
|
+
module UserStore
|
14
|
+
module SponsoredGroupRole
|
15
|
+
GROUP_MEMBER = 1
|
16
|
+
GROUP_ADMIN = 2
|
17
|
+
GROUP_OWNER = 3
|
18
|
+
VALUE_MAP = {1 => "GROUP_MEMBER", 2 => "GROUP_ADMIN", 3 => "GROUP_OWNER"}
|
19
|
+
VALID_VALUES = Set.new([GROUP_MEMBER, GROUP_ADMIN, GROUP_OWNER]).freeze
|
20
|
+
end
|
21
|
+
|
22
|
+
# This structure is used to provide publicly-available user information
|
23
|
+
# about a particular account.
|
24
|
+
# <dl>
|
25
|
+
# <dt>userId:</dt>
|
26
|
+
# <dd>
|
27
|
+
# The unique numeric user identifier for the user account.
|
28
|
+
# </dd>
|
29
|
+
# <dt>shardId:</dt>
|
30
|
+
# <dd>
|
31
|
+
# The name of the virtual server that manages the state of
|
32
|
+
# this user. This value is used internally to determine which system should
|
33
|
+
# service requests about this user's data.
|
34
|
+
# </dd>
|
35
|
+
# <dt>privilege:</dt>
|
36
|
+
# <dd>
|
37
|
+
# The privilege level of the account, to determine whether
|
38
|
+
# this is a Premium or Free account.
|
39
|
+
# </dd>
|
40
|
+
# <dt>noteStoreUrl:</dt>
|
41
|
+
# <dd>
|
42
|
+
# This field will contain the full URL that clients should use to make
|
43
|
+
# NoteStore requests to the server shard that contains that user's data.
|
44
|
+
# I.e. this is the URL that should be used to create the Thrift HTTP client
|
45
|
+
# transport to send messages to the NoteStore service for the account.
|
46
|
+
# </dd>
|
47
|
+
# </dl>
|
48
|
+
class PublicUserInfo
|
49
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
50
|
+
USERID = 1
|
51
|
+
SHARDID = 2
|
52
|
+
PRIVILEGE = 3
|
53
|
+
USERNAME = 4
|
54
|
+
NOTESTOREURL = 5
|
55
|
+
|
56
|
+
FIELDS = {
|
57
|
+
USERID => {:type => ::Thrift::Types::I32, :name => 'userId'},
|
58
|
+
SHARDID => {:type => ::Thrift::Types::STRING, :name => 'shardId'},
|
59
|
+
PRIVILEGE => {:type => ::Thrift::Types::I32, :name => 'privilege', :optional => true, :enum_class => Evernote::EDAM::Type::PrivilegeLevel},
|
60
|
+
USERNAME => {:type => ::Thrift::Types::STRING, :name => 'username', :optional => true},
|
61
|
+
NOTESTOREURL => {:type => ::Thrift::Types::STRING, :name => 'noteStoreUrl', :optional => true}
|
62
|
+
}
|
63
|
+
|
64
|
+
def struct_fields; FIELDS; end
|
65
|
+
|
66
|
+
def validate
|
67
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field userId is unset!') unless @userId
|
68
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field shardId is unset!') unless @shardId
|
69
|
+
unless @privilege.nil? || Evernote::EDAM::Type::PrivilegeLevel::VALID_VALUES.include?(@privilege)
|
70
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field privilege!')
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
::Thrift::Struct.generate_accessors self
|
75
|
+
end
|
76
|
+
|
77
|
+
# This structure is used to provide information about a user's Premium account.
|
78
|
+
# <dl>
|
79
|
+
# <dt>currentTime:</dt>
|
80
|
+
# <dd>
|
81
|
+
# The server-side date and time when this data was generated.
|
82
|
+
# </dd>
|
83
|
+
# <dt>premium:</dt>
|
84
|
+
# <dd>
|
85
|
+
# True if the user's account is Premium.
|
86
|
+
# </dd>
|
87
|
+
# <dt>premiumRecurring</dt>
|
88
|
+
# <dd>
|
89
|
+
# True if the user's account is Premium and has a recurring payment method.
|
90
|
+
# </dd>
|
91
|
+
# <dt>premiumExpirationDate:</dt>
|
92
|
+
# <dd>
|
93
|
+
# The date when the user's Premium account expires, or the date when the
|
94
|
+
# user's account will be charged if it has a recurring payment method.
|
95
|
+
# </dd>
|
96
|
+
# <dt>premiumExtendable:</dt>
|
97
|
+
# <dd>
|
98
|
+
# True if the user is eligible for purchasing Premium account extensions.
|
99
|
+
# </dd>
|
100
|
+
# <dt>premiumPending:</dt>
|
101
|
+
# <dd>
|
102
|
+
# True if the user's Premium account is pending payment confirmation
|
103
|
+
# </dd>
|
104
|
+
# <dt>premiumCancellationPending:</dt>
|
105
|
+
# <dd>
|
106
|
+
# True if the user has requested that no further charges to be made; the
|
107
|
+
# Premium account will remain active until it expires.
|
108
|
+
# </dd>
|
109
|
+
# <dt>canPurchaseUploadAllowance:</dt>
|
110
|
+
# <dd>
|
111
|
+
# True if the user is eligible for purchasing additional upload allowance.
|
112
|
+
# </dd>
|
113
|
+
# <dt>sponsoredGroupName:</dt>
|
114
|
+
# <dd>
|
115
|
+
# The name of the sponsored group that the user is part of.
|
116
|
+
# </dd>
|
117
|
+
# <dt>sponsoredGroupRole:</dt>
|
118
|
+
# <dd>
|
119
|
+
# The role of the user within a sponsored group.
|
120
|
+
# </dd>
|
121
|
+
# <dt>businessName:</dt>
|
122
|
+
# <dd>
|
123
|
+
# The name of the business that the user is associated with.
|
124
|
+
# </dd>
|
125
|
+
# <dt>businessAdmin:</dt>
|
126
|
+
# <dd>
|
127
|
+
# True if the user is the administrator of the business.
|
128
|
+
# </dd>
|
129
|
+
# </dl>
|
130
|
+
class PremiumInfo
|
131
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
132
|
+
CURRENTTIME = 1
|
133
|
+
PREMIUM = 2
|
134
|
+
PREMIUMRECURRING = 3
|
135
|
+
PREMIUMEXPIRATIONDATE = 4
|
136
|
+
PREMIUMEXTENDABLE = 5
|
137
|
+
PREMIUMPENDING = 6
|
138
|
+
PREMIUMCANCELLATIONPENDING = 7
|
139
|
+
CANPURCHASEUPLOADALLOWANCE = 8
|
140
|
+
SPONSOREDGROUPNAME = 9
|
141
|
+
SPONSOREDGROUPROLE = 10
|
142
|
+
BUSINESSNAME = 11
|
143
|
+
BUSINESSADMIN = 12
|
144
|
+
|
145
|
+
FIELDS = {
|
146
|
+
CURRENTTIME => {:type => ::Thrift::Types::I64, :name => 'currentTime'},
|
147
|
+
PREMIUM => {:type => ::Thrift::Types::BOOL, :name => 'premium'},
|
148
|
+
PREMIUMRECURRING => {:type => ::Thrift::Types::BOOL, :name => 'premiumRecurring'},
|
149
|
+
PREMIUMEXPIRATIONDATE => {:type => ::Thrift::Types::I64, :name => 'premiumExpirationDate', :optional => true},
|
150
|
+
PREMIUMEXTENDABLE => {:type => ::Thrift::Types::BOOL, :name => 'premiumExtendable'},
|
151
|
+
PREMIUMPENDING => {:type => ::Thrift::Types::BOOL, :name => 'premiumPending'},
|
152
|
+
PREMIUMCANCELLATIONPENDING => {:type => ::Thrift::Types::BOOL, :name => 'premiumCancellationPending'},
|
153
|
+
CANPURCHASEUPLOADALLOWANCE => {:type => ::Thrift::Types::BOOL, :name => 'canPurchaseUploadAllowance'},
|
154
|
+
SPONSOREDGROUPNAME => {:type => ::Thrift::Types::STRING, :name => 'sponsoredGroupName', :optional => true},
|
155
|
+
SPONSOREDGROUPROLE => {:type => ::Thrift::Types::I32, :name => 'sponsoredGroupRole', :optional => true, :enum_class => Evernote::EDAM::UserStore::SponsoredGroupRole},
|
156
|
+
BUSINESSNAME => {:type => ::Thrift::Types::STRING, :name => 'businessName', :optional => true},
|
157
|
+
BUSINESSADMIN => {:type => ::Thrift::Types::BOOL, :name => 'businessAdmin', :optional => true}
|
158
|
+
}
|
159
|
+
|
160
|
+
def struct_fields; FIELDS; end
|
161
|
+
|
162
|
+
def validate
|
163
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field currentTime is unset!') unless @currentTime
|
164
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field premium is unset!') if @premium.nil?
|
165
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field premiumRecurring is unset!') if @premiumRecurring.nil?
|
166
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field premiumExtendable is unset!') if @premiumExtendable.nil?
|
167
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field premiumPending is unset!') if @premiumPending.nil?
|
168
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field premiumCancellationPending is unset!') if @premiumCancellationPending.nil?
|
169
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field canPurchaseUploadAllowance is unset!') if @canPurchaseUploadAllowance.nil?
|
170
|
+
unless @sponsoredGroupRole.nil? || Evernote::EDAM::UserStore::SponsoredGroupRole::VALID_VALUES.include?(@sponsoredGroupRole)
|
171
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field sponsoredGroupRole!')
|
172
|
+
end
|
173
|
+
end
|
174
|
+
|
175
|
+
::Thrift::Struct.generate_accessors self
|
176
|
+
end
|
177
|
+
|
178
|
+
# When an authentication (or re-authentication) is performed, this structure
|
179
|
+
# provides the result to the client.
|
180
|
+
# <dl>
|
181
|
+
# <dt>currentTime:</dt>
|
182
|
+
# <dd>
|
183
|
+
# The server-side date and time when this result was
|
184
|
+
# generated.
|
185
|
+
# </dd>
|
186
|
+
# <dt>authenticationToken:</dt>
|
187
|
+
# <dd>
|
188
|
+
# Holds an opaque, ASCII-encoded token that can be
|
189
|
+
# used by the client to perform actions on a NoteStore.
|
190
|
+
# </dd>
|
191
|
+
# <dt>expiration:</dt>
|
192
|
+
# <dd>
|
193
|
+
# Holds the server-side date and time when the
|
194
|
+
# authentication token will expire.
|
195
|
+
# This time can be compared to "currentTime" to produce an expiration
|
196
|
+
# time that can be reconciled with the client's local clock.
|
197
|
+
# </dd>
|
198
|
+
# <dt>user:</dt>
|
199
|
+
# <dd>
|
200
|
+
# Holds the information about the account which was
|
201
|
+
# authenticated if this was a full authentication. May be absent if this
|
202
|
+
# particular authentication did not require user information.
|
203
|
+
# </dd>
|
204
|
+
# <dt>publicUserInfo:</dt>
|
205
|
+
# <dd>
|
206
|
+
# If this authentication result was achieved without full permissions to
|
207
|
+
# access the full User structure, this field may be set to give back
|
208
|
+
# a more limited public set of data.
|
209
|
+
# </dd>
|
210
|
+
# <dt>noteStoreUrl:</dt>
|
211
|
+
# <dd>
|
212
|
+
# This field will contain the full URL that clients should use to make
|
213
|
+
# NoteStore requests to the server shard that contains that user's data.
|
214
|
+
# I.e. this is the URL that should be used to create the Thrift HTTP client
|
215
|
+
# transport to send messages to the NoteStore service for the account.
|
216
|
+
# </dd>
|
217
|
+
# <dt>webApiUrlPrefix:</dt>
|
218
|
+
# <dd>
|
219
|
+
# This field will contain the initial part of the URLs that should be used
|
220
|
+
# to make requests to Evernote's thin client "web API", which provide
|
221
|
+
# optimized operations for clients that aren't capable of manipulating
|
222
|
+
# the full contents of accounts via the full Thrift data model. Clients
|
223
|
+
# should concatenate the relative path for the various servlets onto the
|
224
|
+
# end of this string to construct the full URL, as documented on our
|
225
|
+
# developer web site.
|
226
|
+
# </dd>
|
227
|
+
# </dl>
|
228
|
+
class AuthenticationResult
|
229
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
230
|
+
CURRENTTIME = 1
|
231
|
+
AUTHENTICATIONTOKEN = 2
|
232
|
+
EXPIRATION = 3
|
233
|
+
USER = 4
|
234
|
+
PUBLICUSERINFO = 5
|
235
|
+
NOTESTOREURL = 6
|
236
|
+
WEBAPIURLPREFIX = 7
|
237
|
+
|
238
|
+
FIELDS = {
|
239
|
+
CURRENTTIME => {:type => ::Thrift::Types::I64, :name => 'currentTime'},
|
240
|
+
AUTHENTICATIONTOKEN => {:type => ::Thrift::Types::STRING, :name => 'authenticationToken'},
|
241
|
+
EXPIRATION => {:type => ::Thrift::Types::I64, :name => 'expiration'},
|
242
|
+
USER => {:type => ::Thrift::Types::STRUCT, :name => 'user', :class => Evernote::EDAM::Type::User, :optional => true},
|
243
|
+
PUBLICUSERINFO => {:type => ::Thrift::Types::STRUCT, :name => 'publicUserInfo', :class => Evernote::EDAM::UserStore::PublicUserInfo, :optional => true},
|
244
|
+
NOTESTOREURL => {:type => ::Thrift::Types::STRING, :name => 'noteStoreUrl', :optional => true},
|
245
|
+
WEBAPIURLPREFIX => {:type => ::Thrift::Types::STRING, :name => 'webApiUrlPrefix', :optional => true}
|
246
|
+
}
|
247
|
+
|
248
|
+
def struct_fields; FIELDS; end
|
249
|
+
|
250
|
+
def validate
|
251
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field currentTime is unset!') unless @currentTime
|
252
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field authenticationToken is unset!') unless @authenticationToken
|
253
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field expiration is unset!') unless @expiration
|
254
|
+
end
|
255
|
+
|
256
|
+
::Thrift::Struct.generate_accessors self
|
257
|
+
end
|
258
|
+
|
259
|
+
# This structure describes a collection of bootstrap settings.
|
260
|
+
# <dl>
|
261
|
+
# <dt>serviceHost:</dt>
|
262
|
+
# <dd>
|
263
|
+
# The hostname and optional port for composing Evernote web service URLs.
|
264
|
+
# This URL can be used to access the UserStore and related services,
|
265
|
+
# but must not be used to compose the NoteStore URL. Client applications
|
266
|
+
# must handle serviceHost values that include only the hostname
|
267
|
+
# (e.g. www.evernote.com) or both the hostname and port (e.g. www.evernote.com:8080).
|
268
|
+
# If no port is specified, or if port 443 is specified, client applications must
|
269
|
+
# use the scheme "https" when composing URLs. Otherwise, a client must use the
|
270
|
+
# scheme "http".
|
271
|
+
# </dd>
|
272
|
+
# <dt>marketingUrl:</dt>
|
273
|
+
# <dd>
|
274
|
+
# The URL stem for the Evernote corporate marketing website, e.g. http://www.evernote.com.
|
275
|
+
# This stem can be used to compose website URLs. For example, the URL of the Evernote
|
276
|
+
# Trunk is composed by appending "/about/trunk/" to the value of marketingUrl.
|
277
|
+
# </dd>
|
278
|
+
# <dt>supportUrl:</dt>
|
279
|
+
# <dd>
|
280
|
+
# The full URL for the Evernote customer support website, e.g. https://support.evernote.com.
|
281
|
+
# </dd>
|
282
|
+
# <dt>accountEmailDomain:</dt>
|
283
|
+
# <dd>
|
284
|
+
# The domain used for an Evernote user's incoming email address, which allows notes to
|
285
|
+
# be emailed into an account. E.g. m.evernote.com.
|
286
|
+
# </dd>
|
287
|
+
# <dt>enableFacebookSharing:</dt>
|
288
|
+
# <dd>
|
289
|
+
# Whether the client application should enable sharing of notes on Facebook.
|
290
|
+
# </dd>
|
291
|
+
# <dt>enableGiftSubscriptions:</dt>
|
292
|
+
# <dd>
|
293
|
+
# Whether the client application should enable gift subscriptions.
|
294
|
+
# </dd>
|
295
|
+
# <dt>enableSupportTickets:</dt>
|
296
|
+
# <dd>
|
297
|
+
# Whether the client application should enable in-client creation of support tickets.
|
298
|
+
# </dd>
|
299
|
+
# <dt>enableSharedNotebooks:</dt>
|
300
|
+
# <dd>
|
301
|
+
# Whether the client application should enable shared notebooks.
|
302
|
+
# </dd>
|
303
|
+
# <dt>enableSingleNoteSharing:</dt>
|
304
|
+
# <dd>
|
305
|
+
# Whether the client application should enable single note sharing.
|
306
|
+
# </dd>
|
307
|
+
# <dt>enableSponsoredAccounts:</dt>
|
308
|
+
# <dd>
|
309
|
+
# Whether the client application should enable sponsored accounts.
|
310
|
+
# </dd>
|
311
|
+
# <dt>enableTwitterSharing:</dt>
|
312
|
+
# <dd>
|
313
|
+
# Whether the client application should enable sharing of notes on Twitter.
|
314
|
+
# </dd>
|
315
|
+
# </dl>
|
316
|
+
class BootstrapSettings
|
317
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
318
|
+
SERVICEHOST = 1
|
319
|
+
MARKETINGURL = 2
|
320
|
+
SUPPORTURL = 3
|
321
|
+
ACCOUNTEMAILDOMAIN = 4
|
322
|
+
ENABLEFACEBOOKSHARING = 5
|
323
|
+
ENABLEGIFTSUBSCRIPTIONS = 6
|
324
|
+
ENABLESUPPORTTICKETS = 7
|
325
|
+
ENABLESHAREDNOTEBOOKS = 8
|
326
|
+
ENABLESINGLENOTESHARING = 9
|
327
|
+
ENABLESPONSOREDACCOUNTS = 10
|
328
|
+
ENABLETWITTERSHARING = 11
|
329
|
+
|
330
|
+
FIELDS = {
|
331
|
+
SERVICEHOST => {:type => ::Thrift::Types::STRING, :name => 'serviceHost'},
|
332
|
+
MARKETINGURL => {:type => ::Thrift::Types::STRING, :name => 'marketingUrl'},
|
333
|
+
SUPPORTURL => {:type => ::Thrift::Types::STRING, :name => 'supportUrl'},
|
334
|
+
ACCOUNTEMAILDOMAIN => {:type => ::Thrift::Types::STRING, :name => 'accountEmailDomain'},
|
335
|
+
ENABLEFACEBOOKSHARING => {:type => ::Thrift::Types::BOOL, :name => 'enableFacebookSharing', :optional => true},
|
336
|
+
ENABLEGIFTSUBSCRIPTIONS => {:type => ::Thrift::Types::BOOL, :name => 'enableGiftSubscriptions', :optional => true},
|
337
|
+
ENABLESUPPORTTICKETS => {:type => ::Thrift::Types::BOOL, :name => 'enableSupportTickets', :optional => true},
|
338
|
+
ENABLESHAREDNOTEBOOKS => {:type => ::Thrift::Types::BOOL, :name => 'enableSharedNotebooks', :optional => true},
|
339
|
+
ENABLESINGLENOTESHARING => {:type => ::Thrift::Types::BOOL, :name => 'enableSingleNoteSharing', :optional => true},
|
340
|
+
ENABLESPONSOREDACCOUNTS => {:type => ::Thrift::Types::BOOL, :name => 'enableSponsoredAccounts', :optional => true},
|
341
|
+
ENABLETWITTERSHARING => {:type => ::Thrift::Types::BOOL, :name => 'enableTwitterSharing', :optional => true}
|
342
|
+
}
|
343
|
+
|
344
|
+
def struct_fields; FIELDS; end
|
345
|
+
|
346
|
+
def validate
|
347
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field serviceHost is unset!') unless @serviceHost
|
348
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field marketingUrl is unset!') unless @marketingUrl
|
349
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field supportUrl is unset!') unless @supportUrl
|
350
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field accountEmailDomain is unset!') unless @accountEmailDomain
|
351
|
+
end
|
352
|
+
|
353
|
+
::Thrift::Struct.generate_accessors self
|
354
|
+
end
|
355
|
+
|
356
|
+
# This structure describes a collection of bootstrap settings.
|
357
|
+
# <dl>
|
358
|
+
# <dt>name:</dt>
|
359
|
+
# <dd>
|
360
|
+
# The unique name of the profile, which is guaranteed to remain consistent across
|
361
|
+
# calls to getBootstrapInfo.
|
362
|
+
# </dd>
|
363
|
+
# <dt>settings:</dt>
|
364
|
+
# <dd>
|
365
|
+
# The settings for this profile.
|
366
|
+
# </dd>
|
367
|
+
# </dl>
|
368
|
+
class BootstrapProfile
|
369
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
370
|
+
NAME = 1
|
371
|
+
SETTINGS = 2
|
372
|
+
|
373
|
+
FIELDS = {
|
374
|
+
NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
|
375
|
+
SETTINGS => {:type => ::Thrift::Types::STRUCT, :name => 'settings', :class => Evernote::EDAM::UserStore::BootstrapSettings}
|
376
|
+
}
|
377
|
+
|
378
|
+
def struct_fields; FIELDS; end
|
379
|
+
|
380
|
+
def validate
|
381
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field name is unset!') unless @name
|
382
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field settings is unset!') unless @settings
|
383
|
+
end
|
384
|
+
|
385
|
+
::Thrift::Struct.generate_accessors self
|
386
|
+
end
|
387
|
+
|
388
|
+
# This structure describes a collection of bootstrap profiles.
|
389
|
+
# <dl>
|
390
|
+
# <dt>profiles:</dt>
|
391
|
+
# <dd>
|
392
|
+
# List of one or more bootstrap profiles, in descending
|
393
|
+
# preference order.
|
394
|
+
# </dd>
|
395
|
+
# </dl>
|
396
|
+
class BootstrapInfo
|
397
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
398
|
+
PROFILES = 1
|
399
|
+
|
400
|
+
FIELDS = {
|
401
|
+
PROFILES => {:type => ::Thrift::Types::LIST, :name => 'profiles', :element => {:type => ::Thrift::Types::STRUCT, :class => Evernote::EDAM::UserStore::BootstrapProfile}}
|
402
|
+
}
|
403
|
+
|
404
|
+
def struct_fields; FIELDS; end
|
405
|
+
|
406
|
+
def validate
|
407
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field profiles is unset!') unless @profiles
|
408
|
+
end
|
409
|
+
|
410
|
+
::Thrift::Struct.generate_accessors self
|
411
|
+
end
|
412
|
+
|
413
|
+
end
|
414
|
+
end
|
415
|
+
end
|
metadata
ADDED
@@ -0,0 +1,120 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: evernote_oauth
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
prerelease:
|
6
|
+
platform: ruby
|
7
|
+
authors:
|
8
|
+
- Kentaro Suzuki
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2012-08-14 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: oauth
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: 0.4.1
|
22
|
+
type: :runtime
|
23
|
+
prerelease: false
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 0.4.1
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: thrift_client
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: 0.8.1
|
38
|
+
type: :runtime
|
39
|
+
prerelease: false
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: 0.8.1
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: rspec
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
54
|
+
type: :development
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
description: evernote_oauth is a Ruby client for the Evernote API using OAuth and
|
63
|
+
Thrift.
|
64
|
+
email: ksuzuki@gmail.com
|
65
|
+
executables: []
|
66
|
+
extensions: []
|
67
|
+
extra_rdoc_files: []
|
68
|
+
files:
|
69
|
+
- LICENSE
|
70
|
+
- README.md
|
71
|
+
- evernote_oauth.gemspec
|
72
|
+
- lib/evernote_oauth/client.rb
|
73
|
+
- lib/evernote_oauth/note_store.rb
|
74
|
+
- lib/evernote_oauth/user_store.rb
|
75
|
+
- lib/evernote_oauth/version.rb
|
76
|
+
- lib/evernote_oauth.rb
|
77
|
+
- spec/evernote_oauth/client_spec.rb
|
78
|
+
- spec/evernote_oauth/note_store_spec.rb
|
79
|
+
- spec/evernote_oauth/user_store_spec.rb
|
80
|
+
- spec/spec_helper.rb
|
81
|
+
- vendor/evernote/edam/errors_constants.rb
|
82
|
+
- vendor/evernote/edam/errors_types.rb
|
83
|
+
- vendor/evernote/edam/limits_constants.rb
|
84
|
+
- vendor/evernote/edam/limits_types.rb
|
85
|
+
- vendor/evernote/edam/note_store.rb
|
86
|
+
- vendor/evernote/edam/note_store_constants.rb
|
87
|
+
- vendor/evernote/edam/note_store_types.rb
|
88
|
+
- vendor/evernote/edam/types_constants.rb
|
89
|
+
- vendor/evernote/edam/types_types.rb
|
90
|
+
- vendor/evernote/edam/user_store.rb
|
91
|
+
- vendor/evernote/edam/user_store_constants.rb
|
92
|
+
- vendor/evernote/edam/user_store_types.rb
|
93
|
+
- vendor/evernote.rb
|
94
|
+
homepage: http://github.com/rekotan/evernote_oauth
|
95
|
+
licenses: []
|
96
|
+
post_install_message:
|
97
|
+
rdoc_options:
|
98
|
+
- --inline-source
|
99
|
+
- --charset=UTF-8
|
100
|
+
require_paths:
|
101
|
+
- lib
|
102
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
103
|
+
none: false
|
104
|
+
requirements:
|
105
|
+
- - ! '>='
|
106
|
+
- !ruby/object:Gem::Version
|
107
|
+
version: '0'
|
108
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
|
+
none: false
|
110
|
+
requirements:
|
111
|
+
- - ! '>='
|
112
|
+
- !ruby/object:Gem::Version
|
113
|
+
version: '0'
|
114
|
+
requirements: []
|
115
|
+
rubyforge_project: evernote_oauth
|
116
|
+
rubygems_version: 1.8.24
|
117
|
+
signing_key:
|
118
|
+
specification_version: 2
|
119
|
+
summary: evernote_oauth is a Ruby client for the Evernote API using OAuth and Thrift.
|
120
|
+
test_files: []
|