Class: Vcard::V3_0::PropertyValue::Float

Inherits:
Vobject::PropertyValue show all
Includes:
Comparable
Defined in:
lib/vobject/vcard/v3_0/propertyvalue.rb

Instance Attribute Summary

Attributes inherited from Vobject::PropertyValue

#errors, #norm, #type, #value

Instance Method Summary collapse

Methods inherited from Vobject::PropertyValue

#name, #to_norm

Constructor Details

#initialize(val) ⇒ Float

Returns a new instance of Float.



126
127
128
129
# File 'lib/vobject/vcard/v3_0/propertyvalue.rb', line 126

def initialize(val)
  self.value = val
  self.type = "float"
end

Instance Method Details

#<=>(another) ⇒ Object



122
123
124
# File 'lib/vobject/vcard/v3_0/propertyvalue.rb', line 122

def <=>(another)
  value <=> another.value
end

#to_hashObject



135
136
137
# File 'lib/vobject/vcard/v3_0/propertyvalue.rb', line 135

def to_hash
  value
end

#to_sObject



131
132
133
# File 'lib/vobject/vcard/v3_0/propertyvalue.rb', line 131

def to_s
  value
end