Class: SyntaxTree::CLI::Options

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

Overview

This represents all of the options that can be passed to the CLI. It is responsible for parsing the list and then returning the file paths at the end.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(print_width: DEFAULT_PRINT_WIDTH) ⇒ Options

Returns a new instance of Options.



255
256
257
# File 'lib/syntax_tree/cli.rb', line 255

def initialize(print_width: DEFAULT_PRINT_WIDTH)
  @print_width = print_width
end

Instance Attribute Details

Returns the value of attribute print_width.



253
254
255
# File 'lib/syntax_tree/cli.rb', line 253

def print_width
  @print_width
end

Instance Method Details

#parse(arguments) ⇒ Object



259
260
261
# File 'lib/syntax_tree/cli.rb', line 259

def parse(arguments)
  parser.parse(arguments)
end