Class: GoogleFormInput

Inherits:
Object
  • Object
show all
Defined in:
lib/google_form_input.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(input_type, label, name) ⇒ GoogleFormInput

Returns a new instance of GoogleFormInput.



4
5
6
7
8
# File 'lib/google_form_input.rb', line 4

def initialize(input_type, label, name)
  @input_type = input_type
  @label = label
  @name = name
end

Instance Attribute Details

#input_typeObject (readonly)

Returns the value of attribute input_type.



2
3
4
# File 'lib/google_form_input.rb', line 2

def input_type
  @input_type
end

#labelObject (readonly)

Returns the value of attribute label.



2
3
4
# File 'lib/google_form_input.rb', line 2

def label
  @label
end

#nameObject (readonly)

Returns the value of attribute name.



2
3
4
# File 'lib/google_form_input.rb', line 2

def name
  @name
end

#valueObject

Returns the value of attribute value.



2
3
4
# File 'lib/google_form_input.rb', line 2

def value
  @value
end

Instance Method Details

#to_paramObject



14
15
16
# File 'lib/google_form_input.rb', line 14

def to_param
  {@name => @value}
end