Class: Seh::EventType::And

Inherits:
EventType
  • Object
show all
Defined in:
lib/seh/event_type.rb

Instance Method Summary collapse

Constructor Details

#initialize(*types) ⇒ And

Returns a new instance of And.



14
15
16
17
# File 'lib/seh/event_type.rb', line 14

def initialize *types
  @types = []
  types.each { |t| t = EventType.new t unless t.kind_of? EventType ; @types << t }
end

Instance Method Details

#match(types) ⇒ Object



19
20
21
22
# File 'lib/seh/event_type.rb', line 19

def match types
  @types.each { |t| return false unless t.match types }
  true
end