Class: Lrama::Counterexamples::Triple

Inherits:
Object
  • Object
show all
Defined in:
lib/lrama/counterexamples/triple.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(state_item, precise_lookahead_set) ⇒ Triple

Returns a new instance of Triple.



12
13
14
15
# File 'lib/lrama/counterexamples/triple.rb', line 12

def initialize(state_item, precise_lookahead_set)
  @state_item = state_item
  @precise_lookahead_set = precise_lookahead_set
end

Instance Attribute Details

#precise_lookahead_setObject (readonly) Also known as: l

: Bitmap::bitmap



7
8
9
# File 'lib/lrama/counterexamples/triple.rb', line 7

def precise_lookahead_set
  @precise_lookahead_set
end

Instance Method Details

#inspectObject Also known as: to_s



35
36
37
# File 'lib/lrama/counterexamples/triple.rb', line 35

def inspect
  "#{state.inspect}. #{item.display_name}. #{l.to_s(2)}"
end

#itemObject Also known as: itm



24
25
26
# File 'lib/lrama/counterexamples/triple.rb', line 24

def item
  @state_item.item
end

#stateObject Also known as: s



18
19
20
# File 'lib/lrama/counterexamples/triple.rb', line 18

def state
  @state_item.state
end

#state_itemObject



30
31
32
# File 'lib/lrama/counterexamples/triple.rb', line 30

def state_item
  @state_item
end