Sha256: 1e362231faeb17c17efdc70f19dabb327e472c16c6204a0c2c2026cb462bdba7

Contents?: true

Size: 576 Bytes

Versions: 1

Compression:

Stored size: 576 Bytes

Contents

module Ecoportal
  module API
    class V1
      class PersonSchemas
        attr_reader :client
        def initialize(client)
          @client = client
        end

        def each(params: {}, &block)
          get_all.each(&block)
          self
        end

        def get_all
          response = @client.get("/person_schemas")
          Common::WrappedResponse.new(response, person_schema_class)
        end

        private

        def person_schema_class
          V1::PersonSchema
        end
      end
    end
  end
end

require 'ecoportal/api/v1/person_schema'

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ecoportal-api-0.1.1 lib/ecoportal/api/v1/person_schemas.rb