Class: AppleID::IdToken::RealUserStatus

Inherits:
Object
  • Object
show all
Defined in:
lib/apple_id/id_token/real_user_status.rb

Defined Under Namespace

Classes: UndefinedStatus

Constant Summary collapse

STATUSES =
[
  :unsupported,
  :unknown,
  :likely_real
]

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ RealUserStatus

Returns a new instance of RealUserStatus.



13
14
15
# File 'lib/apple_id/id_token/real_user_status.rb', line 13

def initialize(value)
  self.value = value
end

Instance Attribute Details

#valueObject

Returns the value of attribute value.



5
6
7
# File 'lib/apple_id/id_token/real_user_status.rb', line 5

def value
  @value
end

Instance Method Details

#statusObject



23
24
25
# File 'lib/apple_id/id_token/real_user_status.rb', line 23

def status
  STATUSES[value] or raise UndefinedStatus
end