Class: ActionDispatch::Routing::ConsoleFormatter::Expanded

Inherits:
Base
  • Object
show all
Defined in:
actionpack/lib/action_dispatch/routing/inspector.rb

Instance Method Summary collapse

Methods inherited from Base

#header, #no_routes, #result

Constructor Details

#initialize(width: IO.console_size[1]) ⇒ Expanded

Returns a new instance of Expanded.



203
204
205
206
# File 'actionpack/lib/action_dispatch/routing/inspector.rb', line 203

def initialize(width: IO.console_size[1])
  @width = width
  super()
end

Instance Method Details

#section(routes) ⇒ Object



212
213
214
# File 'actionpack/lib/action_dispatch/routing/inspector.rb', line 212

def section(routes)
  @buffer << draw_expanded_section(routes)
end

#section_title(title) ⇒ Object



208
209
210
# File 'actionpack/lib/action_dispatch/routing/inspector.rb', line 208

def section_title(title)
  @buffer << "\n#{"[ #{title} ]"}"
end