lib/nrser/types/type.rb
# Dumps a value of this type to "data" - structures and values suitable
# for transport and storage, such as dumping to JSON or YAML, etc.
# 
# @param [Object] value
#   Value of this type (though it is *not* checked).
# 
# @return [Object]
#   The data representation of the value.
# 
Dumps a value of this type to "data" - structures and values suitable
for transport and storage, such as dumping to JSON or YAML, etc.
Dumps a value of this type to " data " - structures and values suitable for transport and storage such as dumping to JSON or YAML etc .
def to_data value
    if @to_data.nil?
      raise NoMethodError, "#to_data not defined"
    end
    @to_data.call value
  end
def to_data value if @to_data . nil? raise NoMethodError , "#to_data not defined" end @to_data . call value end
Dumps a value of this type to "data" - structures and values suitable
for transport and storage, such as dumping to JSON or YAML, etc.
Dumps a value of this type to " data " - structures and values suitable for transport and storage such as dumping to JSON or YAML etc .
The data representation of the value.
The data representation of the value .
Object
value
<not_specific>
<not_specific>
value Value of this type (though it is *not* checked).
value Value of this type ( though it is * not * checked ) .