class Pug::Interfaces::Action
Abstract interface representing an Action
Public Instance Methods
description()
click to toggle source
Optional description for the action @return [String] Action
description
# File lib/pug/interfaces/action.rb, line 15 def description '' end
execute(input)
click to toggle source
Entry point for Action
with provided input if any @param input [String] The optional input for the Action
@return [String] The output of running the Action
@note This can return nil if there is no output
# File lib/pug/interfaces/action.rb, line 30 def execute(input) # rubocop:disable UnusedMethodArgument raise NoMethodError end
name()
click to toggle source
requires_input?()
click to toggle source
Indicates if the action requires an input @return [Boolean] if input is required @note Defaults to false
# File lib/pug/interfaces/action.rb, line 22 def requires_input? false end