evernote_oauth 0.0.4 → 0.1.0

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.
data/README.md CHANGED
@@ -1,7 +1,6 @@
1
1
  Evernote OAuth / Thrift API client library for Ruby
2
2
  ===================================================
3
- - Evernote OAuth version 0.03
4
- - Evernote API version 1.21
3
+ - Evernote OAuth version 0.1.0
5
4
 
6
5
  Install the gem
7
6
  ---------------
@@ -8,11 +8,11 @@ Gem::Specification.new do |s|
8
8
  s.name = %q{evernote_oauth}
9
9
  s.version = EvernoteOAuth::VERSION
10
10
 
11
- s.authors = ["Kentaro Suzuki"]
11
+ s.authors = ["Evernote"]
12
12
  s.date = %q{2012-08-14}
13
13
  s.description = %q{evernote_oauth is a Ruby client for the Evernote API using OAuth and Thrift.}
14
- s.email = %q{ksuzuki@gmail.com}
15
- s.files = ["LICENSE", "README.md", "evernote_oauth.gemspec"] + Dir.glob('{lib,spec,vendor}/**/*')
14
+ s.email = %q{api@evernote.com}
15
+ s.files = ["LICENSE", "README.md", "evernote_oauth.gemspec"] + Dir.glob('{lib,spec}/**/*')
16
16
  s.has_rdoc = false
17
17
  s.homepage = %q{http://github.com/rekotan/evernote_oauth}
18
18
  s.rdoc_options = ["--inline-source", "--charset=UTF-8"]
@@ -26,7 +26,7 @@ Gem::Specification.new do |s|
26
26
  s.specification_version = 2
27
27
 
28
28
  s.add_dependency 'oauth', '>= 0.4.1'
29
- s.add_dependency 'thrift_client', '>= 0.8.1'
29
+ s.add_dependency 'evernote-thrift'
30
30
  s.add_development_dependency 'rspec'
31
31
  end
32
32
  end
@@ -1,34 +1,10 @@
1
1
  require 'rubygems'
2
- require 'thrift_client'
3
2
  require 'oauth'
4
3
  require 'yaml'
5
4
 
6
- vendor_path = File.expand_path(File.dirname(__FILE__) + "/../vendor")
7
- $LOAD_PATH.unshift "#{vendor_path}/evernote/edam"
8
-
9
- require "#{vendor_path}/evernote"
5
+ require 'evernote-thrift'
10
6
 
11
7
  require 'evernote_oauth/client'
12
8
  require 'evernote_oauth/user_store'
13
9
  require 'evernote_oauth/note_store'
14
10
  require 'evernote_oauth/version'
15
-
16
- # Path Thrift 0.8.0 Gem for Ruby 1.9.3 compatibility
17
- # See: http://discussion.evernote.com/topic/15321-evernote-ruby-thrift-client-error/
18
- #
19
- if Gem::Version.new(RUBY_VERSION.dup) == Gem::Version.new('1.9.3') &&
20
- Gem.loaded_specs['thrift'].version == Gem::Version.new('0.8.0')
21
- module Thrift
22
- class HTTPClientTransport < BaseTransport
23
-
24
- def flush
25
- http = Net::HTTP.new @url.host, @url.port
26
- http.use_ssl = @url.scheme == "https"
27
- resp, data = http.post(@url.request_uri, @outbuf, @headers)
28
- # Was: @inbuf = StringIO.new data
29
- @inbuf = StringIO.new resp.body
30
- @outbuf = ""
31
- end
32
- end
33
- end
34
- end
@@ -56,9 +56,10 @@ module EvernoteOAuth
56
56
  @access_token ||= OAuth::AccessToken.new(consumer, @token, @secret)
57
57
  end
58
58
 
59
- def thrift_client(client_class, url, options={})
60
- @thrift_client = ThriftClient.new(client_class, url, options.merge(
61
- transport: Thrift::HTTPClientTransport))
59
+ def thrift_client(client_class, url)
60
+ transport = Thrift::HTTPClientTransport.new(url)
61
+ protocol = Thrift::BinaryProtocol.new(transport)
62
+ client_class.new(protocol)
62
63
  end
63
64
 
64
65
  end
@@ -4,8 +4,7 @@ module EvernoteOAuth
4
4
  def note_store(options={})
5
5
  @note_store = EvernoteOAuth::NoteStore.new(
6
6
  client: thrift_client(::Evernote::EDAM::NoteStore::NoteStore::Client,
7
- user_store(options).getNoteStoreUrl(@token),
8
- options)
7
+ options[:note_store_url] || user_store.getNoteStoreUrl(@token))
9
8
  )
10
9
  end
11
10
  end
@@ -1,10 +1,10 @@
1
1
  module EvernoteOAuth
2
2
 
3
3
  class Client
4
- def user_store(options={})
4
+ def user_store
5
5
  @user_store = EvernoteOAuth::UserStore.new(
6
6
  client: thrift_client(::Evernote::EDAM::UserStore::UserStore::Client,
7
- endpoint('edam/user'), options)
7
+ endpoint('edam/user'))
8
8
  )
9
9
  end
10
10
  end
@@ -21,8 +21,8 @@ module EvernoteOAuth
21
21
 
22
22
  def version_valid?
23
23
  checkVersion("EDAMTest",
24
- ::Evernote::EDAM::UserStore::EDAM_VERSION_MAJOR,
25
- ::Evernote::EDAM::UserStore::EDAM_VERSION_MINOR)
24
+ ::Evernote::EDAM::UserStore::EDAM_VERSION_MAJOR,
25
+ ::Evernote::EDAM::UserStore::EDAM_VERSION_MINOR)
26
26
  end
27
27
  end
28
28
 
@@ -1,3 +1,3 @@
1
1
  module EvernoteOAuth
2
- VERSION = "0.0.4"
2
+ VERSION = "0.1.0"
3
3
  end
metadata CHANGED
@@ -1,11 +1,11 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: evernote_oauth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.1.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
8
- - Kentaro Suzuki
8
+ - Evernote
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
@@ -28,13 +28,13 @@ dependencies:
28
28
  - !ruby/object:Gem::Version
29
29
  version: 0.4.1
30
30
  - !ruby/object:Gem::Dependency
31
- name: thrift_client
31
+ name: evernote-thrift
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  none: false
34
34
  requirements:
35
35
  - - ! '>='
36
36
  - !ruby/object:Gem::Version
37
- version: 0.8.1
37
+ version: '0'
38
38
  type: :runtime
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
@@ -42,7 +42,7 @@ dependencies:
42
42
  requirements:
43
43
  - - ! '>='
44
44
  - !ruby/object:Gem::Version
45
- version: 0.8.1
45
+ version: '0'
46
46
  - !ruby/object:Gem::Dependency
47
47
  name: rspec
48
48
  requirement: !ruby/object:Gem::Requirement
@@ -61,7 +61,7 @@ dependencies:
61
61
  version: '0'
62
62
  description: evernote_oauth is a Ruby client for the Evernote API using OAuth and
63
63
  Thrift.
64
- email: ksuzuki@gmail.com
64
+ email: api@evernote.com
65
65
  executables: []
66
66
  extensions: []
67
67
  extra_rdoc_files: []
@@ -78,19 +78,6 @@ files:
78
78
  - spec/evernote_oauth/note_store_spec.rb
79
79
  - spec/evernote_oauth/user_store_spec.rb
80
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
81
  homepage: http://github.com/rekotan/evernote_oauth
95
82
  licenses: []
96
83
  post_install_message:
data/vendor/evernote.rb DELETED
@@ -1,12 +0,0 @@
1
- require 'set'
2
- require 'errors_types'
3
- require 'limits_constants'
4
- require 'limits_types'
5
- require 'note_store'
6
- require 'note_store_constants'
7
- require 'note_store_types'
8
- require 'types_constants'
9
- require 'types_types'
10
- require 'user_store'
11
- require 'user_store_constants'
12
- require 'user_store_types'
@@ -1,14 +0,0 @@
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 'errors_types'
8
-
9
- module Evernote
10
- module EDAM
11
- module Error
12
- end
13
- end
14
- end
@@ -1,128 +0,0 @@
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
-
8
- module Evernote
9
- module EDAM
10
- module Error
11
- module EDAMErrorCode
12
- UNKNOWN = 1
13
- BAD_DATA_FORMAT = 2
14
- PERMISSION_DENIED = 3
15
- INTERNAL_ERROR = 4
16
- DATA_REQUIRED = 5
17
- LIMIT_REACHED = 6
18
- QUOTA_REACHED = 7
19
- INVALID_AUTH = 8
20
- AUTH_EXPIRED = 9
21
- DATA_CONFLICT = 10
22
- ENML_VALIDATION = 11
23
- SHARD_UNAVAILABLE = 12
24
- LEN_TOO_SHORT = 13
25
- LEN_TOO_LONG = 14
26
- TOO_FEW = 15
27
- TOO_MANY = 16
28
- UNSUPPORTED_OPERATION = 17
29
- VALUE_MAP = {1 => "UNKNOWN", 2 => "BAD_DATA_FORMAT", 3 => "PERMISSION_DENIED", 4 => "INTERNAL_ERROR", 5 => "DATA_REQUIRED", 6 => "LIMIT_REACHED", 7 => "QUOTA_REACHED", 8 => "INVALID_AUTH", 9 => "AUTH_EXPIRED", 10 => "DATA_CONFLICT", 11 => "ENML_VALIDATION", 12 => "SHARD_UNAVAILABLE", 13 => "LEN_TOO_SHORT", 14 => "LEN_TOO_LONG", 15 => "TOO_FEW", 16 => "TOO_MANY", 17 => "UNSUPPORTED_OPERATION"}
30
- VALID_VALUES = Set.new([UNKNOWN, BAD_DATA_FORMAT, PERMISSION_DENIED, INTERNAL_ERROR, DATA_REQUIRED, LIMIT_REACHED, QUOTA_REACHED, INVALID_AUTH, AUTH_EXPIRED, DATA_CONFLICT, ENML_VALIDATION, SHARD_UNAVAILABLE, LEN_TOO_SHORT, LEN_TOO_LONG, TOO_FEW, TOO_MANY, UNSUPPORTED_OPERATION]).freeze
31
- end
32
-
33
- # This exception is thrown by EDAM procedures when a call fails as a result of
34
- # a problem that a user may be able to resolve. For example, if the user
35
- # attempts to add a note to their account which would exceed their storage
36
- # quota, this type of exception may be thrown to indicate the source of the
37
- # error so that they can choose an alternate action.
38
- #
39
- # This exception would not be used for internal system errors that do not
40
- # reflect user actions, but rather reflect a problem within the service that
41
- # the user cannot resolve.
42
- #
43
- # errorCode: The numeric code indicating the type of error that occurred.
44
- # must be one of the values of EDAMErrorCode.
45
- #
46
- # parameter: If the error applied to a particular input parameter, this will
47
- # indicate which parameter.
48
- class EDAMUserException < ::Thrift::Exception
49
- include ::Thrift::Struct, ::Thrift::Struct_Union
50
- ERRORCODE = 1
51
- PARAMETER = 2
52
-
53
- FIELDS = {
54
- ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode', :enum_class => Evernote::EDAM::Error::EDAMErrorCode},
55
- PARAMETER => {:type => ::Thrift::Types::STRING, :name => 'parameter', :optional => true}
56
- }
57
-
58
- def struct_fields; FIELDS; end
59
-
60
- def validate
61
- raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field errorCode is unset!') unless @errorCode
62
- unless @errorCode.nil? || Evernote::EDAM::Error::EDAMErrorCode::VALID_VALUES.include?(@errorCode)
63
- raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field errorCode!')
64
- end
65
- end
66
-
67
- ::Thrift::Struct.generate_accessors self
68
- end
69
-
70
- # This exception is thrown by EDAM procedures when a call fails as a result of
71
- # an a problem in the service that could not be changed through user action.
72
- #
73
- # errorCode: The numeric code indicating the type of error that occurred.
74
- # must be one of the values of EDAMErrorCode.
75
- #
76
- # message: This may contain additional information about the error
77
- class EDAMSystemException < ::Thrift::Exception
78
- include ::Thrift::Struct, ::Thrift::Struct_Union
79
- ERRORCODE = 1
80
- MESSAGE = 2
81
-
82
- FIELDS = {
83
- ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode', :enum_class => Evernote::EDAM::Error::EDAMErrorCode},
84
- MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message', :optional => true}
85
- }
86
-
87
- def struct_fields; FIELDS; end
88
-
89
- def validate
90
- raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field errorCode is unset!') unless @errorCode
91
- unless @errorCode.nil? || Evernote::EDAM::Error::EDAMErrorCode::VALID_VALUES.include?(@errorCode)
92
- raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field errorCode!')
93
- end
94
- end
95
-
96
- ::Thrift::Struct.generate_accessors self
97
- end
98
-
99
- # This exception is thrown by EDAM procedures when a caller asks to perform
100
- # an operation that does not exist. This may be thrown based on an invalid
101
- # primary identifier (e.g. a bad GUID), or when the caller refers to an object
102
- # by another unique identifier (e.g. a User's email address).
103
- #
104
- # identifier: the object identifier that was not found on the server.
105
- #
106
- # key: the value passed from the client in the identifier, which was not
107
- # found. E.g. the GUID of an object that was not found.
108
- class EDAMNotFoundException < ::Thrift::Exception
109
- include ::Thrift::Struct, ::Thrift::Struct_Union
110
- IDENTIFIER = 1
111
- KEY = 2
112
-
113
- FIELDS = {
114
- IDENTIFIER => {:type => ::Thrift::Types::STRING, :name => 'identifier', :optional => true},
115
- KEY => {:type => ::Thrift::Types::STRING, :name => 'key', :optional => true}
116
- }
117
-
118
- def struct_fields; FIELDS; end
119
-
120
- def validate
121
- end
122
-
123
- ::Thrift::Struct.generate_accessors self
124
- end
125
-
126
- end
127
- end
128
- end
@@ -1,240 +0,0 @@
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 'limits_types'
8
-
9
- module Evernote
10
- module EDAM
11
- module Limits
12
- EDAM_ATTRIBUTE_LEN_MIN = 1
13
-
14
- EDAM_ATTRIBUTE_LEN_MAX = 4096
15
-
16
- EDAM_ATTRIBUTE_REGEX = %q"^[^\\p{Cc}\\p{Zl}\\p{Zp}]{1,4096}$"
17
-
18
- EDAM_ATTRIBUTE_LIST_MAX = 100
19
-
20
- EDAM_ATTRIBUTE_MAP_MAX = 100
21
-
22
- EDAM_GUID_LEN_MIN = 36
23
-
24
- EDAM_GUID_LEN_MAX = 36
25
-
26
- EDAM_GUID_REGEX = %q"^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
27
-
28
- EDAM_EMAIL_LEN_MIN = 6
29
-
30
- EDAM_EMAIL_LEN_MAX = 255
31
-
32
- EDAM_EMAIL_LOCAL_REGEX = %q"^[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+(\\.[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+)*$"
33
-
34
- EDAM_EMAIL_DOMAIN_REGEX = %q"^[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*\\.([A-Za-z]{2,})$"
35
-
36
- EDAM_EMAIL_REGEX = %q"^[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+(\\.[A-Za-z0-9!#$%&'*+/=?^_`{|}~-]+)*@[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*\\.([A-Za-z]{2,})$"
37
-
38
- EDAM_TIMEZONE_LEN_MIN = 1
39
-
40
- EDAM_TIMEZONE_LEN_MAX = 32
41
-
42
- EDAM_TIMEZONE_REGEX = %q"^([A-Za-z_-]+(/[A-Za-z_-]+)*)|(GMT(-|\\+)[0-9]{1,2}(:[0-9]{2})?)$"
43
-
44
- EDAM_MIME_LEN_MIN = 3
45
-
46
- EDAM_MIME_LEN_MAX = 255
47
-
48
- EDAM_MIME_REGEX = %q"^[A-Za-z]+/[A-Za-z0-9._+-]+$"
49
-
50
- EDAM_MIME_TYPE_GIF = %q"image/gif"
51
-
52
- EDAM_MIME_TYPE_JPEG = %q"image/jpeg"
53
-
54
- EDAM_MIME_TYPE_PNG = %q"image/png"
55
-
56
- EDAM_MIME_TYPE_WAV = %q"audio/wav"
57
-
58
- EDAM_MIME_TYPE_MP3 = %q"audio/mpeg"
59
-
60
- EDAM_MIME_TYPE_AMR = %q"audio/amr"
61
-
62
- EDAM_MIME_TYPE_MP4_VIDEO = %q"video/mp4"
63
-
64
- EDAM_MIME_TYPE_INK = %q"application/vnd.evernote.ink"
65
-
66
- EDAM_MIME_TYPE_PDF = %q"application/pdf"
67
-
68
- EDAM_MIME_TYPE_DEFAULT = %q"application/octet-stream"
69
-
70
- EDAM_MIME_TYPES = Set.new([
71
- %q"image/gif",
72
- %q"image/jpeg",
73
- %q"image/png",
74
- %q"audio/wav",
75
- %q"audio/mpeg",
76
- %q"audio/amr",
77
- %q"application/vnd.evernote.ink",
78
- %q"application/pdf",
79
- %q"video/mp4",
80
- ])
81
-
82
- EDAM_COMMERCE_SERVICE_GOOGLE = %q"Google"
83
-
84
- EDAM_COMMERCE_SERVICE_PAYPAL = %q"Paypal"
85
-
86
- EDAM_COMMERCE_SERVICE_GIFT = %q"Gift"
87
-
88
- EDAM_COMMERCE_SERVICE_TRIALPAY = %q"TrialPay"
89
-
90
- EDAM_COMMERCE_SERVICE_TRIAL = %q"Trial"
91
-
92
- EDAM_COMMERCE_SERVICE_GROUP = %q"Group"
93
-
94
- EDAM_COMMERCE_SERVICE_CYBERSOURCE = %q"CYBERSRC"
95
-
96
- EDAM_COMMERCE_DEFAULT_CURRENCY_COUNTRY_CODE = %q"USD"
97
-
98
- EDAM_SEARCH_QUERY_LEN_MIN = 0
99
-
100
- EDAM_SEARCH_QUERY_LEN_MAX = 1024
101
-
102
- EDAM_SEARCH_QUERY_REGEX = %q"^[^\\p{Cc}\\p{Zl}\\p{Zp}]{0,1024}$"
103
-
104
- EDAM_HASH_LEN = 16
105
-
106
- EDAM_USER_USERNAME_LEN_MIN = 1
107
-
108
- EDAM_USER_USERNAME_LEN_MAX = 64
109
-
110
- EDAM_USER_USERNAME_REGEX = %q"^[a-z0-9]([a-z0-9_-]{0,62}[a-z0-9])?$"
111
-
112
- EDAM_USER_NAME_LEN_MIN = 1
113
-
114
- EDAM_USER_NAME_LEN_MAX = 255
115
-
116
- EDAM_USER_NAME_REGEX = %q"^[^\\p{Cc}\\p{Zl}\\p{Zp}]{1,255}$"
117
-
118
- EDAM_TAG_NAME_LEN_MIN = 1
119
-
120
- EDAM_TAG_NAME_LEN_MAX = 100
121
-
122
- EDAM_TAG_NAME_REGEX = %q"^[^,\\p{Cc}\\p{Z}]([^,\\p{Cc}\\p{Zl}\\p{Zp}]{0,98}[^,\\p{Cc}\\p{Z}])?$"
123
-
124
- EDAM_NOTE_TITLE_LEN_MIN = 1
125
-
126
- EDAM_NOTE_TITLE_LEN_MAX = 255
127
-
128
- EDAM_NOTE_TITLE_REGEX = %q"^[^\\p{Cc}\\p{Z}]([^\\p{Cc}\\p{Zl}\\p{Zp}]{0,253}[^\\p{Cc}\\p{Z}])?$"
129
-
130
- EDAM_NOTE_CONTENT_LEN_MIN = 0
131
-
132
- EDAM_NOTE_CONTENT_LEN_MAX = 5242880
133
-
134
- EDAM_APPLICATIONDATA_NAME_LEN_MIN = 3
135
-
136
- EDAM_APPLICATIONDATA_NAME_LEN_MAX = 32
137
-
138
- EDAM_APPLICATIONDATA_VALUE_LEN_MIN = 0
139
-
140
- EDAM_APPLICATIONDATA_VALUE_LEN_MAX = 4092
141
-
142
- EDAM_APPLICATIONDATA_ENTRY_LEN_MAX = 4095
143
-
144
- EDAM_APPLICATIONDATA_NAME_REGEX = %q"^[A-Za-z0-9_.-]{3,32}$"
145
-
146
- EDAM_APPLICATIONDATA_VALUE_REGEX = %q"^[^\\p{Cc}]{0,4092}$"
147
-
148
- EDAM_NOTEBOOK_NAME_LEN_MIN = 1
149
-
150
- EDAM_NOTEBOOK_NAME_LEN_MAX = 100
151
-
152
- EDAM_NOTEBOOK_NAME_REGEX = %q"^[^\\p{Cc}\\p{Z}]([^\\p{Cc}\\p{Zl}\\p{Zp}]{0,98}[^\\p{Cc}\\p{Z}])?$"
153
-
154
- EDAM_NOTEBOOK_STACK_LEN_MIN = 1
155
-
156
- EDAM_NOTEBOOK_STACK_LEN_MAX = 100
157
-
158
- EDAM_NOTEBOOK_STACK_REGEX = %q"^[^\\p{Cc}\\p{Z}]([^\\p{Cc}\\p{Zl}\\p{Zp}]{0,98}[^\\p{Cc}\\p{Z}])?$"
159
-
160
- EDAM_PUBLISHING_URI_LEN_MIN = 1
161
-
162
- EDAM_PUBLISHING_URI_LEN_MAX = 255
163
-
164
- EDAM_PUBLISHING_URI_REGEX = %q"^[a-zA-Z0-9.~_+-]{1,255}$"
165
-
166
- EDAM_PUBLISHING_URI_PROHIBITED = Set.new([
167
- %q"..",
168
- ])
169
-
170
- EDAM_PUBLISHING_DESCRIPTION_LEN_MIN = 1
171
-
172
- EDAM_PUBLISHING_DESCRIPTION_LEN_MAX = 200
173
-
174
- EDAM_PUBLISHING_DESCRIPTION_REGEX = %q"^[^\\p{Cc}\\p{Z}]([^\\p{Cc}\\p{Zl}\\p{Zp}]{0,198}[^\\p{Cc}\\p{Z}])?$"
175
-
176
- EDAM_SAVED_SEARCH_NAME_LEN_MIN = 1
177
-
178
- EDAM_SAVED_SEARCH_NAME_LEN_MAX = 100
179
-
180
- EDAM_SAVED_SEARCH_NAME_REGEX = %q"^[^\\p{Cc}\\p{Z}]([^\\p{Cc}\\p{Zl}\\p{Zp}]{0,98}[^\\p{Cc}\\p{Z}])?$"
181
-
182
- EDAM_USER_PASSWORD_LEN_MIN = 6
183
-
184
- EDAM_USER_PASSWORD_LEN_MAX = 64
185
-
186
- EDAM_USER_PASSWORD_REGEX = %q"^[A-Za-z0-9!#$%&'()*+,./:;<=>?@^_`{|}~\\[\\]\\\\-]{6,64}$"
187
-
188
- EDAM_NOTE_TAGS_MAX = 100
189
-
190
- EDAM_NOTE_RESOURCES_MAX = 1000
191
-
192
- EDAM_USER_TAGS_MAX = 100000
193
-
194
- EDAM_USER_SAVED_SEARCHES_MAX = 100
195
-
196
- EDAM_USER_NOTES_MAX = 100000
197
-
198
- EDAM_USER_NOTEBOOKS_MAX = 250
199
-
200
- EDAM_USER_RECENT_MAILED_ADDRESSES_MAX = 10
201
-
202
- EDAM_USER_MAIL_LIMIT_DAILY_FREE = 50
203
-
204
- EDAM_USER_MAIL_LIMIT_DAILY_PREMIUM = 200
205
-
206
- EDAM_USER_UPLOAD_LIMIT_FREE = 62914560
207
-
208
- EDAM_USER_UPLOAD_LIMIT_PREMIUM = 1073741824
209
-
210
- EDAM_NOTE_SIZE_MAX_FREE = 26214400
211
-
212
- EDAM_NOTE_SIZE_MAX_PREMIUM = 52428800
213
-
214
- EDAM_RESOURCE_SIZE_MAX_FREE = 26214400
215
-
216
- EDAM_RESOURCE_SIZE_MAX_PREMIUM = 52428800
217
-
218
- EDAM_USER_LINKED_NOTEBOOK_MAX = 100
219
-
220
- EDAM_NOTEBOOK_SHARED_NOTEBOOK_MAX = 250
221
-
222
- EDAM_NOTE_CONTENT_CLASS_LEN_MIN = 3
223
-
224
- EDAM_NOTE_CONTENT_CLASS_LEN_MAX = 32
225
-
226
- EDAM_HELLO_APP_CONTENT_CLASS_PREFIX = %q"evernote.hello."
227
-
228
- EDAM_FOOD_APP_CONTENT_CLASS_PREFIX = %q"evernote.food."
229
-
230
- EDAM_NOTE_CONTENT_CLASS_REGEX = %q"^[A-Za-z0-9_.-]{3,32}$"
231
-
232
- EDAM_CONTENT_CLASS_HELLO_ENCOUNTER = %q"evernote.hello.encounter"
233
-
234
- EDAM_CONTENT_CLASS_HELLO_PROFILE = %q"evernote.hello.profile"
235
-
236
- EDAM_CONTENT_CLASS_FOOD_MEAL = %q"evernote.food.meal"
237
-
238
- end
239
- end
240
- end