Class: Eco::CLI::Config::UseCases::CaseConfig

Inherits:
Struct
  • Object
show all
Defined in:
lib/eco/cli/config/use_cases.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#callbackObject

Returns the value of attribute callback

Returns:

  • (Object)

    the current value of callback



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def callback
  @callback
end

#casenameObject

Returns the value of attribute casename

Returns:

  • (Object)

    the current value of casename



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def casename
  @casename
end

#cases_configObject

Returns the value of attribute cases_config

Returns:

  • (Object)

    the current value of cases_config



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def cases_config
  @cases_config
end

#descriptionObject

Returns the value of attribute description

Returns:

  • (Object)

    the current value of description



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def description
  @description
end

#optionObject

Returns the value of attribute option

Returns:

  • (Object)

    the current value of option



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def option
  @option
end

#typeObject

Returns the value of attribute type

Returns:

  • (Object)

    the current value of type



8
9
10
# File 'lib/eco/cli/config/use_cases.rb', line 8

def type
  @type
end

Instance Method Details

#add_option(arg, desc = nil, &block) ⇒ Object



9
10
11
12
# File 'lib/eco/cli/config/use_cases.rb', line 9

def add_option(arg, desc = nil, &block)
  core_config.options_set.add(arg, desc, namespace: option, &block)
  self
end