class FormtasticTristateRadio::Configuration
Configuration
block pattern
@see thoughtbot.com/blog/mygem-configure-block @see brandonhilkert.com/blog/ruby-gem-configuration-patterns/
Attributes
unset_key[R]
@!attribute [r] unset_key
@return [Symbol, String] the value of <var>@unset_key</var>
Public Class Methods
new()
click to toggle source
# File lib/formtastic_tristate_radio/configuration.rb, line 24 def initialize @unset_key = :null end
Public Instance Methods
unset_key=(value)
click to toggle source
@return [Symbol, String, Integer] value that was passed into the method
@raise [TypeError] because no other types seem to make sence here
# File lib/formtastic_tristate_radio/configuration.rb, line 37 def unset_key=(value) fail TypeError, "`unset_key` must be a Symbol, String or Integer" unless [Symbol, String, Integer].include? value.class @unset_key = value end