Sha256: 2cf7a0b1ed1eb2e27e62a5b1da43ae57dcbbeb4cce10fbac59e7140120ed72ad

Contents?: true

Size: 1.19 KB

Versions: 41

Compression:

Stored size: 1.19 KB

Contents

module Access
  class Report

    def self.all_usage(options = {})
      # Internal Admin only Call
      Access::Api.new.all_usage options
    end

    def self.usage(options = {})
      # Internal Admin only Call
      Access::Api.new.usage options
    end

    def self.usage_other(key, options = {})
      # Internal Admin only Call
      Access::Api.new.usage_other key, options
    end

    def self.member_query_frequent(member, options = {})
      Access::Api.new.member_query_frequent member, options
    end

    def self.member_query_recent(member, options = {})
      Access::Api.new.member_query_recent member, options
    end

    def self.member_location_frequent(member, options = {})
      Access::Api.new.member_location_frequent member, options
    end

    def self.member_location_recent(member, options = {})
      Access::Api.new.member_location_recent member, options
    end

    def self.process_batch(chunk)
      chunk.map { |data| new(data) }
    end

    def initialize(values)
      self.class.class_eval {attr_reader *values.keys }
      values.each do |attribute_name, attribute_value|
        self.instance_variable_set("@#{attribute_name}", attribute_value)
      end
    end

  end
end

Version data entries

41 entries across 41 versions & 1 rubygems

Version Path
access-2.0.28 lib/access/report.rb
access-2.0.27 lib/access/report.rb
access-2.0.26 lib/access/report.rb
access-2.0.25 lib/access/report.rb
access-2.0.24 lib/access/report.rb
access-2.0.23 lib/access/report.rb
access-2.0.22 lib/access/report.rb
access-2.0.21 lib/access/report.rb
access-2.0.20 lib/access/report.rb
access-2.0.19 lib/access/report.rb
access-2.0.18 lib/access/report.rb
access-2.0.17 lib/access/report.rb
access-2.0.15 lib/access/report.rb
access-2.0.14 lib/access/report.rb
access-2.0.13 lib/access/report.rb
access-2.0.11 lib/access/report.rb
access-2.0.10 lib/access/report.rb
access-2.0.9 lib/access/report.rb
access-2.0.8 lib/access/report.rb
access-2.0.7 lib/access/report.rb