Skip to content

Commit

Permalink
allow rentry & subnets
Browse files Browse the repository at this point in the history
  • Loading branch information
stackdump committed Nov 27, 2023
1 parent 5c575eb commit 6f6f427
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
10 changes: 8 additions & 2 deletions model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,15 @@ export interface Guard {
export interface Transition extends TypeAnnotation{
metaType: "transition";
label: string;
delta: Vector;
role: RoleDef;
guards: Map<string, Guard>; // REVIEW: difference w/ pflow-eth imp. which uses single guard vector
delta: Vector;
guards: Map<string, Guard>;
allowReentry: boolean;
position: Position;
subnet?: {
m: Model;
type: "entry" | "exit";
};
}

export interface Arc extends TypeAnnotation {
Expand Down Expand Up @@ -129,6 +134,7 @@ export function newModel({schema, declaration, type}: ModelOptions): Model {
function fn(label: string, role: RoleDef, position: Position): TxNode {
const transition: Transition = {
metaType: "transition",
allowReentry: false,
label,
role,
position,
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pflow-dev/metamodel",
"version": "0.4.0",
"version": "0.5.0",
"main": "/index.js",
"types": "/index.d.ts",
"description": "create workflows and petriNets with a DSL",
Expand Down

0 comments on commit 6f6f427

Please sign in to comment.