Class: Gapic::Presenters::SamplePresenter::RequestField

Inherits:
Object
  • Object
show all
Defined in:
lib/gapic/presenters/sample_presenter.rb

Overview

Representation of a request field.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(field) ⇒ RequestField

Returns a new instance of RequestField.



62
63
64
65
66
67
68
69
# File 'lib/gapic/presenters/sample_presenter.rb', line 62

def initialize field
  @field = field["field"]
  @value = convert field["value"]
  @input_parameter = field["input_parameter"]
  @comment = field["comment"]
  @comment = nil if @comment&.empty?
  @value_is_file = field["value_is_file"]
end

Instance Attribute Details

#comment ⇒ Object (readonly)

Returns the value of attribute comment.



61
62
63
# File 'lib/gapic/presenters/sample_presenter.rb', line 61

def comment
  @comment
end

#field ⇒ Object (readonly)

Returns the value of attribute field.



61
62
63
# File 'lib/gapic/presenters/sample_presenter.rb', line 61

def field
  @field
end

#input_parameter ⇒ Object (readonly)

Returns the value of attribute input_parameter.



61
62
63
# File 'lib/gapic/presenters/sample_presenter.rb', line 61

def input_parameter
  @input_parameter
end

#value ⇒ Object (readonly)

Returns the value of attribute value.



61
62
63
# File 'lib/gapic/presenters/sample_presenter.rb', line 61

def value
  @value
end

#value_is_file ⇒ Object (readonly)

Returns the value of attribute value_is_file.



61
62
63
# File 'lib/gapic/presenters/sample_presenter.rb', line 61

def value_is_file
  @value_is_file
end