Primitive computations such as arithmetic operators, method calls, etc. are combined to form method bodies by dataflow diagrams. The methods are then organized into classes, which are, in turn, organized into class hierarchies. In addition, Prograph provides the programmer with so-called persistent objects that can be stored in a Prograph database between different invocations of the program. We will now introduce some of the more interesting Prograph features by means of an example of topological sort algorithm on directed graphs. Graphs will be represented by adjacency lists, i.e. a graph is a list of lists, each of which corresponds to a node.
Methods consist of one or mores cases .
Each case of a method is a dataflow diagram that specifies how the case is to be executed. The edges of a flow diagram indicate how data propagates from the root of one operation to the terminals of the next, i.e. the order of execution is data-driven. The case number, as well as the total number of cases, is indicated in the title bar of the window containing the method's dataflow diagram. At least one of the roots or the terminals of the multiplex is annotated with an icon that indicates the type of the multiplex. The annotations on this multiplex indicate that output values on the loop roots will be passed to the loop terminals as input values for the next iteration.