Class: Treequel::Filter::NotComponent

Inherits:
Component
  • Object
show all
Defined in:
lib/treequel/filter.rb

Overview

A filtercomp that negates the filter it contains.

Instance Method Summary collapse

Methods inherited from Component

inherited, #inspect, #promiscuous?

Constructor Details

#initialize(filter) ⇒ NotComponent

Create an negation component of the specified filter.



134
135
136
# File 'lib/treequel/filter.rb', line 134

def initialize( filter )
	@filter = filter
end

Instance Method Details

#to_sObject

Return the stringified filter form of the receiver.



139
140
141
# File 'lib/treequel/filter.rb', line 139

def to_s
	return '!' + @filter.to_s
end