lib/pas.rb in pas-0.0.1 vs lib/pas.rb in pas-0.0.2

- old
+ new

@@ -1,13 +1,31 @@ -require 'active_resource' -require 'active_support' -require 'openssl' -require 'base64' -require 'pas/version' -require 'pas/resource' -require 'pas/member' -require 'pas/member_tracker' +module PAS + require 'active_resource' + require 'active_support' + require 'openssl' + require 'base64' -class PAS - cattr_accessor :api_access_key - cattr_accessor :api_token + autoload :Connection, 'pas/connection' + autoload :Resource, 'pas/resource' + autoload :Session, 'pas/session' + autoload :Member, 'pas/member' + autoload :MemberTracker, 'pas/member_tracker' + + class << self + + def config + @config ||= { + :api_access_key => "", + :api_token => "", + :domain_name => "https://publisher.pokeraffiliatesolutions.com/" + } + end + + end + + class Error < RuntimeError; end + class DisabledMethodError < PAS::Error + def initialize + super "This method is disabled for this Resource" + end + end end \ No newline at end of file