Class: GmailSearchSyntax::AST::Operator

Inherits:
Node
  • Object
show all
Defined in:
lib/gmail_search_syntax/ast.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#==, #attributes

Constructor Details

#initialize(name, value) ⇒ Operator

Returns a new instance of Operator.



16
17
18
19
# File 'lib/gmail_search_syntax/ast.rb', line 16

def initialize(name, value)
  @name = name
  @value = value
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



14
15
16
# File 'lib/gmail_search_syntax/ast.rb', line 14

def name
  @name
end

#valueObject (readonly)

Returns the value of attribute value.



14
15
16
# File 'lib/gmail_search_syntax/ast.rb', line 14

def value
  @value
end

Instance Method Details

#inspectObject



21
22
23
# File 'lib/gmail_search_syntax/ast.rb', line 21

def inspect
  "#<Operator #{@name}: #{@value.inspect}>"
end