Sha256: 45e352a9f1bb8aa6aad84420d3c459821586304b8343a9ba9a7c2b525a5cf03c

Contents?: true

Size: 724 Bytes

Versions: 2

Compression:

Stored size: 724 Bytes

Contents

# frozen_string_literal: true

require 'forwardable'

module EveOnline
  module ESI
    class UniverseConstellation < Base
      extend Forwardable

      API_ENDPOINT = 'https://esi.evetech.net/v1/universe/constellations/%<constellation_id>s/?datasource=%<datasource>s'

      attr_reader :id

      def initialize(options)
        super

        @id = options.fetch(:id)
      end

      def_delegators :model, :as_json, :constellation_id, :name, :region_id,
                     :systems, :position

      def model
        @model ||= Models::Constellation.new(response)
      end

      def scope; end

      def url
        format(API_ENDPOINT, constellation_id: id, datasource: datasource)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
eve_online-0.22.0 lib/eve_online/esi/universe_constellation.rb
eve_online-0.21.0 lib/eve_online/esi/universe_constellation.rb