Class: AddressForm::Address
- Inherits:
-
Struct
- Object
- Struct
- AddressForm::Address
- Defined in:
- lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb
Instance Attribute Summary collapse
-
#city ⇒ Object
Returns the value of attribute city.
-
#full_name ⇒ Object
Returns the value of attribute full_name.
-
#state ⇒ Object
Returns the value of attribute state.
-
#street ⇒ Object
Returns the value of attribute street.
-
#street2 ⇒ Object
Returns the value of attribute street2.
-
#zip_code ⇒ Object
Returns the value of attribute zip_code.
Instance Method Summary collapse
Instance Attribute Details
#city ⇒ Object
Returns the value of attribute city
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def city @city end |
#full_name ⇒ Object
Returns the value of attribute full_name
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def full_name @full_name end |
#state ⇒ Object
Returns the value of attribute state
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def state @state end |
#street ⇒ Object
Returns the value of attribute street
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def street @street end |
#street2 ⇒ Object
Returns the value of attribute street2
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def street2 @street2 end |
#zip_code ⇒ Object
Returns the value of attribute zip_code
4 5 6 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 4 def zip_code @zip_code end |
Instance Method Details
#state_code ⇒ Object
5 6 7 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 5 def state_code STATES.invert[state] end |
#state_code=(value) ⇒ Object
9 10 11 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 9 def state_code=(value) self.state = STATES[value] end |
#summary ⇒ Object
13 14 15 |
# File 'lib/glimmer-dsl-web/samples/hello/hello_glimmer_component_helper/address_form.rb', line 13 def summary to_h.values.map(&:to_s).reject(&:empty?).join(', ') end |