class GLI::Commands::Doc::DocumentListener
Interface for a listener that is called during various parts of the doc process
Public Class Methods
# File lib/gli/commands/doc.rb, line 57 def initialize(global_options,options,arguments,app) @global_options = global_options @options = options @arguments = arguments @app = app end
Public Instance Methods
Called before processing begins
# File lib/gli/commands/doc.rb, line 64 def beginning abstract! end
Gives you a command in the current context and creates a new context of this command
# File lib/gli/commands/doc.rb, line 124 def command(name,aliases,desc,long_desc,arg_name,arg_options) abstract! end
Called at the start of commands for the current context
# File lib/gli/commands/doc.rb, line 99 def commands abstract! end
Gives you the name of the current command in the current context
# File lib/gli/commands/doc.rb, line 119 def default_command(name) abstract! end
Ends a command, and “pops” you back up one context
# File lib/gli/commands/doc.rb, line 129 def end_command(name) abstract! end
Called when all commands for the current context have been vended
# File lib/gli/commands/doc.rb, line 104 def end_commands abstract! end
Called when all options for the current context have been vended
# File lib/gli/commands/doc.rb, line 94 def end_options abstract! end
Called when processing has completed
# File lib/gli/commands/doc.rb, line 69 def ending abstract! end
Gives you a flag in the current context
# File lib/gli/commands/doc.rb, line 109 def flag(name,aliases,desc,long_desc,default_value,arg_name,must_match,type) abstract! end
Called at the start of options for the current context
# File lib/gli/commands/doc.rb, line 89 def options abstract! end
Gives you the program description
# File lib/gli/commands/doc.rb, line 74 def program_desc(desc) abstract! end
Gives you the program long description
# File lib/gli/commands/doc.rb, line 79 def program_long_desc(desc) abstract! end
Gives you a switch in the current context
# File lib/gli/commands/doc.rb, line 114 def switch(name,aliases,desc,long_desc,negatable) abstract! end
Gives you the program version
# File lib/gli/commands/doc.rb, line 84 def version(version) abstract! end
Private Instance Methods
# File lib/gli/commands/doc.rb, line 134 def abstract! raise "Subclass must implement" end