Class: JSONP3::GtExpression

Inherits:
InfixExpression show all
Defined in:
lib/json_p3/filter.rb

Overview

A > expression.

Instance Attribute Summary

Attributes inherited from InfixExpression

#left, #right

Attributes inherited from Expression

#token

Instance Method Summary collapse

Methods inherited from InfixExpression

#==, #hash, #initialize

Methods inherited from Expression

#initialize

Constructor Details

This class inherits a constructor from JSONP3::InfixExpression

Instance Method Details

#evaluate(context) ⇒ Object



283
284
285
# File 'lib/json_p3/filter.rb', line 283

def evaluate(context)
  JSONP3.lt?(@right.evaluate(context), @left.evaluate(context))
end

#to_sObject



287
288
289
# File 'lib/json_p3/filter.rb', line 287

def to_s
  "#{@left} > #{@right}"
end