Class: Unit::Authorization::GetRequest

Inherits:
Object
  • Object
show all
Defined in:
lib/unit/models/authorization/get_request.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(authorization_id, include_non_authorized = nil) ⇒ GetRequest

Returns a new instance of GetRequest.

Parameters:

  • authorization_id (String)
  • include_non_authorized (Boolean) (defaults to: nil)


12
13
14
15
# File 'lib/unit/models/authorization/get_request.rb', line 12

def initialize(authorization_id, include_non_authorized = nil)
  @authorization_id = authorization_id
  @include_non_authorized = include_non_authorized
end

Instance Attribute Details

#authorization_idObject (readonly)

Returns the value of attribute authorization_id.



8
9
10
# File 'lib/unit/models/authorization/get_request.rb', line 8

def authorization_id
  @authorization_id
end

#include_non_authorizedObject (readonly)

Returns the value of attribute include_non_authorized.



8
9
10
# File 'lib/unit/models/authorization/get_request.rb', line 8

def include_non_authorized
  @include_non_authorized
end

Instance Method Details

#to_hashObject



17
18
19
# File 'lib/unit/models/authorization/get_request.rb', line 17

def to_hash
  { 'filter[includeNonAuthorized]': include_non_authorized }.compact
end