Class: Gisele::Analysis::Ghmsc
- Inherits:
-
Object
- Object
- Gisele::Analysis::Ghmsc
- Includes:
- Mixin::BddManagement
- Defined in:
- lib/gisele/analysis/ghmsc.rb
Instance Attribute Summary collapse
-
#ast ⇒ Object
writeonly
Sets the attribute ast.
-
#glts ⇒ Object
writeonly
Sets the attribute glts.
-
#graph ⇒ Object
writeonly
Sets the attribute graph.
-
#session ⇒ Object
readonly
Returns the value of attribute session.
-
#source ⇒ Object
Returns the value of attribute source.
Instance Method Summary collapse
- #c0 ⇒ Object
- #c0=(c0) ⇒ Object
-
#initialize(session) {|_self| ... } ⇒ Ghmsc
constructor
A new instance of Ghmsc.
- #merge(other) ⇒ Object (also: #|)
- #to_ast ⇒ Object
- #to_dot ⇒ Object
- #to_glts ⇒ Object
- #to_graph ⇒ Object
Methods included from Mixin::BddManagement
#bdd, #bdd_interface, #cudd_manager, #one, #with_bdd, #zero
Constructor Details
#initialize(session) {|_self| ... } ⇒ Ghmsc
Returns a new instance of Ghmsc.
5 6 7 8 |
# File 'lib/gisele/analysis/ghmsc.rb', line 5 def initialize(session, &bl) @session = session yield(self) if bl end |
Instance Attribute Details
#ast=(value) ⇒ Object (writeonly)
Sets the attribute ast
26 27 28 |
# File 'lib/gisele/analysis/ghmsc.rb', line 26 def ast=(value) @ast = value end |
#glts=(value) ⇒ Object (writeonly)
Sets the attribute glts
40 41 42 |
# File 'lib/gisele/analysis/ghmsc.rb', line 40 def glts=(value) @glts = value end |
#graph=(value) ⇒ Object (writeonly)
Sets the attribute graph
31 32 33 |
# File 'lib/gisele/analysis/ghmsc.rb', line 31 def graph=(value) @graph = value end |
#session ⇒ Object (readonly)
Returns the value of attribute session.
9 10 11 |
# File 'lib/gisele/analysis/ghmsc.rb', line 9 def session @session end |
#source ⇒ Object
Returns the value of attribute source.
11 12 13 |
# File 'lib/gisele/analysis/ghmsc.rb', line 11 def source @source end |
Instance Method Details
#c0 ⇒ Object
13 14 15 16 17 |
# File 'lib/gisele/analysis/ghmsc.rb', line 13 def c0 with_bdd session.c0 do |s_c0| (@c0 || one) & s_c0 end end |
#c0=(c0) ⇒ Object
19 20 21 |
# File 'lib/gisele/analysis/ghmsc.rb', line 19 def c0=(c0) @c0 = session.bdd(c0) end |
#merge(other) ⇒ Object Also known as: |
46 47 48 49 50 |
# File 'lib/gisele/analysis/ghmsc.rb', line 46 def merge(other) Ghmsc.new(session) do |g| g.glts = to_glts | other.to_glts end end |
#to_ast ⇒ Object
23 24 25 |
# File 'lib/gisele/analysis/ghmsc.rb', line 23 def to_ast @ast ||= Gisele.ast(source) end |
#to_dot ⇒ Object
42 43 44 |
# File 'lib/gisele/analysis/ghmsc.rb', line 42 def to_dot to_graph.to_dot end |