Class: Yarr::Command::ListMethodName

Inherits:
List
  • Object
show all
Defined in:
lib/yarr/command/list.rb

Overview

handles 'list si%' like commands

Instance Attribute Summary

Attributes inherited from Base

#ast, #irc

Class Method Summary collapse

Methods inherited from List

#handle, #response

Methods included from Concern::ASTDigger

#digger

Methods included from Concern::Responder

#advice

Methods inherited from Base

#handle, #initialize

Constructor Details

This class inherits a constructor from Yarr::Command::Base

Class Method Details

.match?(ast) ⇒ Boolean

Can we handle the given AST?

Parameters:

  • ast (hash)

    parsed AST

Returns:

  • (Boolean)

93
94
95
# File 'lib/yarr/command/list.rb', line 93

def self.match?(ast)
  ast[:command] == 'list' && ast.key?(:method_name)
end