Sha256: 91eaad89b962f0527cd5a08384791daae0501c9d699b34858f7aada169302c0a

Contents?: true

Size: 890 Bytes

Versions: 16

Compression:

Stored size: 890 Bytes

Contents

# frozen_string_literal: true

module EveOnline
  module ESI
    module Models
      class Killmail < Base
        def as_json
          {
            killmail_id: killmail_id,
            killmail_time: killmail_time,
            moon_id: moon_id,
            solar_system_id: solar_system_id,
            war_id: war_id
          }
        end

        def killmail_id
          options["killmail_id"]
        end

        def killmail_time
          killmail_time = options["killmail_time"]

          parse_datetime_with_timezone(killmail_time) if killmail_time
        end

        def moon_id
          options["moon_id"]
        end

        def solar_system_id
          options["solar_system_id"]
        end

        def war_id
          options["war_id"]
        end

        # def attackers
        # end
        #
        # def victim
        # end
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
eve_online-0.46.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.45.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.44.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.43.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.42.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.41.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.40.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.39.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.38.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.37.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.36.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.35.1 lib/eve_online/esi/models/killmail.rb
eve_online-0.35.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.34.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.33.0 lib/eve_online/esi/models/killmail.rb
eve_online-0.32.0 lib/eve_online/esi/models/killmail.rb