Module: FidorApi::Customer::Gender

Extended by:
Gender
Included in:
Gender
Defined in:
lib/fidor_api/customer.rb

Defined Under Namespace

Classes: Base, Female, Male, Unknonw

Constant Summary collapse

MAPPING =
{
  Male   => "m",
  Female => "f"
}

Instance Method Summary collapse

Instance Method Details

#for_api_value(api_value) ⇒ Object



22
23
24
# File 'lib/fidor_api/customer.rb', line 22

def for_api_value(api_value)
  MAPPING.key(api_value) || Unknonw
end

#object_to_string(object) ⇒ Object



26
27
28
# File 'lib/fidor_api/customer.rb', line 26

def object_to_string(object)
  MAPPING[object]
end