class Pione::PNML::Arc
‘Arc` is a class represents arcs in PT-net.
Public Instance Methods
from_place_to_transition?()
click to toggle source
Return true if the arc has the direction from place to transition.
# File lib/pione/pnml/pnml-model.rb, line 391 def from_place_to_transition? net.places.any? {|p| p.id == source_id} and net.transitions.any? {|t| t.id == target_id} end
from_transition_to_place?()
click to toggle source
Return true if the arc has the direction from transition to place.
# File lib/pione/pnml/pnml-model.rb, line 386 def from_transition_to_place? net.transitions.any? {|t| t.id == source_id} and net.places.any? {|p| p.id == target_id} end
inspect()
click to toggle source
# File lib/pione/pnml/pnml-model.rb, line 395 def inspect "#<Pione::PNML::Arc id=%s source_id=%s target_id=%s>" % [id.inspect, source_id.inspect, target_id.inspect] end