Sha256: f160dd98f9ae470bc5033bddd8c943387b52c50c2a0834e2728f39a6cca84702

Contents?: true

Size: 310 Bytes

Versions: 24

Compression:

Stored size: 310 Bytes

Contents

module JsonApiClient
  module Helpers
    module Parsable
      extend ActiveSupport::Concern

      included do
        class_attribute :parser
        self.parser = Parser
      end

      module ClassMethods
        def parse(data)
          parser.parse(self, data)
        end
      end

    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
json_api_client-0.9.6 lib/json_api_client/helpers/parsable.rb
json_api_client-0.9.5 lib/json_api_client/helpers/parsable.rb
json_api_client-0.9.4 lib/json_api_client/helpers/parsable.rb
json_api_client-0.9.3 lib/json_api_client/helpers/parsable.rb
json_api_client-0.9.2 lib/json_api_client/helpers/parsable.rb
json_api_client-0.9.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.8.1 lib/json_api_client/helpers/parsable.rb
json_api_client-0.8.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.7.1 lib/json_api_client/helpers/parsable.rb
json_api_client-0.7.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.6.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.5.1 lib/json_api_client/helpers/parsable.rb
json_api_client-0.5.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.4.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.3.1 lib/json_api_client/helpers/parsable.rb
json_api_client-0.3.0 lib/json_api_client/helpers/parsable.rb
json_api_client-0.2.4 lib/json_api_client/helpers/parsable.rb
json_api_client-0.2.3 lib/json_api_client/helpers/parsable.rb
json_api_client-0.2.2 lib/json_api_client/helpers/parsable.rb
json_api_client-0.2.1 lib/json_api_client/helpers/parsable.rb