Class: Cb::Models::State

Inherits:
ApiResponseModel show all
Defined in:
lib/cb/models/implementations/state.rb

Instance Attribute Summary collapse

Attributes inherited from ApiResponseModel

#api_response

Instance Method Summary collapse

Methods inherited from ApiResponseModel

#initialize

Constructor Details

This class inherits a constructor from Cb::Models::ApiResponseModel

Instance Attribute Details

#keyObject

Returns the value of attribute key.



4
5
6
# File 'lib/cb/models/implementations/state.rb', line 4

def key
  @key
end

#valueObject

Returns the value of attribute value.



4
5
6
# File 'lib/cb/models/implementations/state.rb', line 4

def value
  @value
end

Instance Method Details

#required_fieldsObject



12
13
14
# File 'lib/cb/models/implementations/state.rb', line 12

def required_fields
  ['StateId', 'StateName']
end

#set_model_propertiesObject



6
7
8
9
10
# File 'lib/cb/models/implementations/state.rb', line 6

def set_model_properties
  @key = api_response['StateId']
  @value = api_response['StateName']

end