Module: Mashery
- Defined in:
- lib/mashery.rb,
lib/mashery/key.rb,
lib/mashery/rails.rb,
lib/mashery/config.rb,
lib/mashery/member.rb,
lib/mashery/service.rb,
lib/mashery/version.rb,
lib/mashery/generator.rb,
lib/mashery/exceptions.rb,
lib/mashery/rpc_client.rb,
lib/mashery/rest_client.rb,
lib/mashery/query_builder.rb,
lib/mashery_rails/version.rb,
lib/mashery/rpc_client/base.rb,
lib/mashery/rest_client/query.rb,
lib/mashery/rpc_client/response.rb
Defined Under Namespace
Classes: Config, ConfigMissing, Engine, InstallGenerator, InvalidDateRange, Key, Member, MissingConfig, NoClassGiven, ParamMissing, QueryBuilder, QueryParamMissing, RestClient, RpcClient, Service, UnknownFormat
Constant Summary
collapse
- VERSION =
"0.6.6"
- @@config =
nil
Class Method Summary
collapse
Class Method Details
.activity(activity_type, service_id, options) ⇒ Object
52
53
54
|
# File 'lib/mashery.rb', line 52
def self.activity(activity_type, service_id, options)
Mashery.rest.activity(activity_type, service_id, options)
end
|
.config ⇒ Object
31
32
33
34
|
# File 'lib/mashery.rb', line 31
def self.config
raise Mashery::ConfigMissing.new unless @@config.present?
@@config
end
|
.config=(other) ⇒ Object
36
37
38
|
# File 'lib/mashery.rb', line 36
def self.config=(other)
@@config = other
end
|
.load_config!(yaml_file) ⇒ Object
.load_rails_config! ⇒ Object
2
3
4
5
6
7
8
|
# File 'lib/mashery/rails.rb', line 2
def self.load_rails_config!
if File.exists? rails_config
load_config! rails_config
else
end
end
|
.rails_config ⇒ Object
10
11
12
|
# File 'lib/mashery/rails.rb', line 10
def self.rails_config
Rails.root.join("config", "mashery.yml")
end
|
.rpc ⇒ Object
44
45
46
|
# File 'lib/mashery.rb', line 44
def self.rpc
Mashery::RpcClient.new
end
|