Sha256: 512faf86009a6506636e82db27a70921b1d7a313487706f1b915815804ea425d

Contents?: true

Size: 595 Bytes

Versions: 6

Compression:

Stored size: 595 Bytes

Contents

# frozen_string_literal: true

require 'avm/eac_gitlab_base0/api/base_entity'
require 'eac_rest/api'
require 'eac_ruby_utils/core_ext'

module Avm
  module EacGitlabBase0
    class Api < ::EacRest::Api
      class Member < ::Avm::EacGitlabBase0::Api::BaseEntity
        FIELDS = %w[id name username state avatar_url web_url access_level expires_at].freeze

        FIELDS.each do |field|
          define_method field do
            data.fetch(field)
          end
        end

        def to_s
          [name, username, state, access_level].join(' / ')
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
eac_tools-0.84.0 sub/avm-eac_gitlab_base0/lib/avm/eac_gitlab_base0/api/member.rb
eac_tools-0.83.0 sub/avm-eac_gitlab_base0/lib/avm/eac_gitlab_base0/api/member.rb
eac_tools-0.82.0 sub/avm-eac_gitlab_base0/lib/avm/eac_gitlab_base0/api/member.rb
avm-eac_gitlab_base0-0.4.0 lib/avm/eac_gitlab_base0/api/member.rb
eac_tools-0.81.0 sub/avm-eac_gitlab_base0/lib/avm/eac_gitlab_base0/api/member.rb
avm-eac_gitlab_base0-0.3.0 lib/avm/eac_gitlab_base0/api/member.rb