rename types in Petri Net formalism to prevent naming collisions when merging with 'Port' formalism

This commit is contained in:
Joeri Exelmans 2024-11-22 15:20:16 +01:00
parent 6ac8e30747
commit 5962a476c0
10 changed files with 69 additions and 69 deletions

View file

@ -1,11 +1,11 @@
# Places, transitions, arcs (and only one kind of arc)
Connectable:Class { abstract = True; }
PNConnectable:Class { abstract = True; }
arc:Association (Connectable -> Connectable)
pn_arc:Association (PNConnectable -> PNConnectable)
Place:Class
Transition:Class
PNPlace:Class
PNTransition:Class
:Inheritance (Place -> Connectable)
:Inheritance (Transition -> Connectable)
:Inheritance (PNPlace -> PNConnectable)
:Inheritance (PNTransition -> PNConnectable)

View file

@ -1,13 +1,13 @@
# A place has a number of tokens, and that's it.
PlaceState:Class
PlaceState_numTokens:AttributeLink (PlaceState -> Integer) {
PNPlaceState:Class
PNPlaceState_numTokens:AttributeLink (PNPlaceState -> Integer) {
name = "numTokens";
optional = False;
constraint = `"numTokens cannot be negative" if get_value(get_target(this)) < 0 else None`;
}
of:Association (PlaceState -> Place) {
pn_of:Association (PNPlaceState -> PNPlace) {
# one-to-one
source_lower_cardinality = 1;
source_upper_cardinality = 1;