def to_recipe
      method_name       = :"#{self.type}_to_recipe"
      custom_to_recipe  = self.send(method_name) rescue {}

      { 'name'      => self.name,
        'type'      => self.type,
        'required'  => self.required?,
        'unique'    => self.unique?,
        'localized' => self.localized?,
        'default'   => self.default }.merge(custom_to_recipe)
    end
def to_recipe
      method_name       = :"#{self.type}_to_recipe"
      custom_to_recipe  = self.send(method_name) rescue {}

      { 'name'      => self.name,
        'type'      => self.type,
        'required'  => self.required?,
        'unique'    => self.unique?,
        'localized' => self.localized?,
        'default'   => self.default }.merge(custom_to_recipe)
    end
Returns the information (name, type, required, ...etc) needed to build
 the custom class.
 That will be stored into the target instance.

 @return [ Hash ] The hash