class Gapic::Schema::RequestParameter
Encapsulates information that is parsed from a single command line parameter from the plugin_opt command line
Attributes
config_name[R]
config_value[R]
input_name[R]
input_str[R]
input_value[R]
Public Class Methods
new(input_str, input_name, input_value, config_name, config_value)
click to toggle source
@param input_str
[String] the input string containing parameter and value
that the parameter and value were parsed from
@param input_name
[String] the name of the parameter as found in the input
can be an alias to a known config parameter name
@param input_value
[String] the unescaped input value of the parameter as found in the input @param config_name
[String] the known config parameter name as matched during parsing @param config_value
[String,Array,Hash] the parsed and deserialized config value
# File lib/gapic/schema/request_parameter.rb, line 35 def initialize input_str, input_name, input_value, config_name, config_value @input_str = input_str @input_name = input_name @input_value = input_value @config_name = config_name @config_value = config_value end
Public Instance Methods
to_config_h()
click to toggle source
The hash of config name-value @return [Hash {String => String, Array, Hash}]
# File lib/gapic/schema/request_parameter.rb, line 51 def to_config_h { config_name => config_value } end
to_input_h()
click to toggle source
The hash of input name-value @return [Hash {String => String}]
# File lib/gapic/schema/request_parameter.rb, line 45 def to_input_h { input_name => input_value } end