Class: Vcard::V4_0::PropertyValue::Gender
Instance Attribute Summary
#errors, #norm, #type, #value
Instance Method Summary
collapse
#<=>, #name, #to_norm
Constructor Details
#initialize(val) ⇒ Gender
Returns a new instance of Gender.
316
317
318
319
|
# File 'lib/vobject/vcard/v4_0/propertyvalue.rb', line 316
def initialize(val)
self.value = val
self.type = "text"
end
|
Instance Method Details
#to_hash ⇒ Object
327
328
329
|
# File 'lib/vobject/vcard/v4_0/propertyvalue.rb', line 327
def to_hash
value
end
|
#to_s ⇒ Object
321
322
323
324
325
|
# File 'lib/vobject/vcard/v4_0/propertyvalue.rb', line 321
def to_s
ret = value[:sex]
ret << ";#{value[:gender]}" if !value[:gender].empty?
ret
end
|