Sha256: 60c3c3d623d66f305c7d353d4e76c1a4931c1a9490c0ae207d9c9ef0b5885801

Contents?: true

Size: 769 Bytes

Versions: 1

Compression:

Stored size: 769 Bytes

Contents

require_relative "../base_item"

module Greeve
  module Character
    # Mailing lists the character is a member of.
    #
    # @see https://eveonline-third-party-documentation.readthedocs.io/en/latest/xmlapi/character/char_mailinglists.html
    class MailingLists < Greeve::BaseItem
      endpoint "char/MailingLists"

      rowset :mailing_lists, xpath: "eveapi/result/rowset[@name='mailingLists']" do
        attribute :list_id,      xpath: "@listID",      type: :integer
        attribute :display_name, xpath: "@displayName", type: :string
      end

      # @param character_id [Integer] EVE character ID
      def initialize(character_id, opts = {})
        opts[:query_params] = { "characterID" => character_id }
        super(opts)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
greeve-1.0.0 lib/greeve/character/mailing_lists.rb