UNPKG

5.05 kBYAMLView Raw
1---
2"$schema": "http://json-schema.org/draft-04/schema"
3id: 'graph.json'
4title: 'FBP graph'
5description: |
6 A graph of FBP processes and connections between them.
7 This is the primary way of specifying FBP programs.
8name: "graph"
9type: "object"
10additionalProperties: false
11properties:
12 caseSensitive:
13 type: "boolean"
14 description: "Whether the graph port identifiers should be treated as case-sensitive"
15 properties:
16 type: "object"
17 description: "User-defined properties attached to the graph."
18 additionalProperties: true
19 properties:
20 name:
21 type: "string"
22 description: "Name of the graph"
23 environment:
24 type: "object"
25 description: "Information about the execution environment for the graph"
26 additionalProperties: true
27 required: ['type']
28 properties:
29 type:
30 type: "string"
31 description: "Runtime type the graph is for"
32 example: "noflo-nodejs"
33 content:
34 type: "string"
35 description: "HTML fixture for browser-based graphs"
36 description:
37 type: "string"
38 description: "Graph description"
39 icon:
40 type: "string"
41 description: "Name of the icon that can be used for depicting the graph"
42 inports:
43 type:
44 - object
45 - undefined
46 description: "Exported inports of the graph"
47 additionalProperties: true
48 patternProperties:
49 "[a-z0-9]+":
50 type: "object"
51 properties:
52 process:
53 type: "string"
54 port:
55 type: "string"
56 metadata:
57 type: "object"
58 additionalProperties: true
59 required: []
60 properties:
61 x:
62 type: integer
63 description: "X coordinate of a graph inport"
64 y:
65 type: integer
66 description: "Y coordinate of a graph inport"
67 outports:
68 type:
69 - object
70 - undefined
71 description: "Exported outports of the graph"
72 additionalProperties: true
73 patternProperties:
74 "[a-z0-9]+":
75 type: "object"
76 properties:
77 process:
78 type: "string"
79 port:
80 type: "string"
81 metadata:
82 type: "object"
83 required: []
84 additionalProperties: true
85 properties:
86 x:
87 type: integer
88 description: "X coordinate of a graph outport"
89 y:
90 type: integer
91 description: "Y coordinate of a graph outport"
92 groups:
93 type: "array"
94 description: "List of groups of processes"
95 items:
96 type: "object"
97 additionalProperties: false
98 properties:
99 name:
100 type: "string"
101 nodes:
102 type: "array"
103 items:
104 type: "string"
105 metadata:
106 type: object
107 additionalProperties: true
108 required: []
109 properties:
110 description:
111 type: string
112 processes:
113 type: "object"
114 description: |
115 The processes of this graph.
116 Each process is an instance of a component.
117 additionalProperties: false
118 patternProperties:
119 "[a-zA-Z0-9_]+":
120 type: "object"
121 properties:
122 component:
123 type: "string"
124 metadata:
125 type: "object"
126 additionalProperties: true
127 required: []
128 properties:
129 x:
130 type: integer
131 description: "X coordinate of a graph node"
132 y:
133 type: integer
134 description: "Y coordinate of a graph node"
135 connections:
136 type: "array"
137 description: |
138 Connections of the graph.
139 A connection either connects ports of two processes, or specifices an IIP as initial input packet to a port.
140 items:
141 type: "object"
142 additionalProperties: false
143 properties:
144 src:
145 type: "object"
146 additionalProperties: false
147 properties:
148 process:
149 type: "string"
150 port:
151 type: "string"
152 index:
153 type: integer
154 tgt:
155 type: "object"
156 additionalProperties: false
157 properties:
158 process:
159 type: "string"
160 port:
161 type: "string"
162 index:
163 type: integer
164 data: {}
165 metadata:
166 type: "object"
167 additionalProperties: true
168 required: []
169 properties:
170 route:
171 type: integer
172 description: "Route identifier of a graph edge"
173 schema:
174 type: string
175 format: "uri"
176 description: "JSON schema associated with a graph edge"
177 secure:
178 type: boolean
179 description: "Whether edge data should be treated as secure"