Class: ShellCardManagementApIs::EIDAccess

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/shell_card_management_ap_is/models/eid_access.rb

Overview

EIDAccess Model.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#to_hash, #to_json

Constructor Details

#initialize(col_co_id = SKIP, col_co_code = SKIP, account_group_id = SKIP) ⇒ EIDAccess

Returns a new instance of EIDAccess.



51
52
53
54
55
56
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 51

def initialize(col_co_id = SKIP, col_co_code = SKIP,
                = SKIP)
  @col_co_id = col_co_id unless col_co_id == SKIP
  @col_co_code = col_co_code unless col_co_code == SKIP
  @account_group_id =  unless  == SKIP
end

Instance Attribute Details

#account_group_idString

Identifier for the EID account group configured for the user.

Returns:

  • (String)


22
23
24
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 22

def 
  @account_group_id
end

#col_co_codeInteger

Collecting company Code

Returns:

  • (Integer)


18
19
20
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 18

def col_co_code
  @col_co_code
end

#col_co_idString

Collecting company id.

Returns:

  • (String)


14
15
16
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 14

def col_co_id
  @col_co_id
end

Class Method Details

.from_hash(hash) ⇒ Object

Creates an instance of the object from a hash.



59
60
61
62
63
64
65
66
67
68
69
70
71
72
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 59

def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  col_co_id = hash.key?('ColCoId') ? hash['ColCoId'] : SKIP
  col_co_code = hash.key?('ColCoCode') ? hash['ColCoCode'] : SKIP
   =
    hash.key?('AccountGroupId') ? hash['AccountGroupId'] : SKIP

  # Create object from extracted values.
  EIDAccess.new(col_co_id,
                col_co_code,
                )
end

.namesObject

A mapping from model property names to API property names.



25
26
27
28
29
30
31
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 25

def self.names
  @_hash = {} if @_hash.nil?
  @_hash['col_co_id'] = 'ColCoId'
  @_hash['col_co_code'] = 'ColCoCode'
  @_hash['account_group_id'] = 'AccountGroupId'
  @_hash
end

.nullablesObject

An array for nullable fields



43
44
45
46
47
48
49
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 43

def self.nullables
  %w[
    col_co_id
    col_co_code
    account_group_id
  ]
end

.optionalsObject

An array for optional fields



34
35
36
37
38
39
40
# File 'lib/shell_card_management_ap_is/models/eid_access.rb', line 34

def self.optionals
  %w[
    col_co_id
    col_co_code
    account_group_id
  ]
end