Class QN2MATLAB
Network with the LINE MATLAB API.
Port of matlab/src/io/QN2MATLAB.m: the script defines model, the cell arrays
node and jobclass, and a routing cell array P read from sn.rtnodes,
in the same three blocks and with the same comments as the MATLAB generator. Processes are written
from their first two moments by the same rules as QN2JAVA.
Differences from the MATLAB text, each made so the script rebuilds the same model: a number that
MATLAB's %f or %d would round is printed in full; a scheduling weight other than 1
(DPS, GPS and their priority variants) is passed to setService, as QN2JAVA.m already
does; a Fork's tasks-per-link other than 1 is restored through setTasksPerLink. Node types
MATLAB would silently omit (Cache, Logger, Place, Transition) are refused by name instead.
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringReturns the generated script for a model named aftermodel.getName().static StringReturns the generated script.static voidwrite(Network model, String modelName, PrintStream out) Writes the generated script to a stream (e.g.static voidWrites the generated script to a writer, which is flushed but not closed.static voidWrites the generated script tofilename, overwriting it.
-
Method Details
-
generate
Returns the generated script for a model named aftermodel.getName(). -
generate
Returns the generated script. -
write
Writes the generated script to a stream (e.g.System.out), which is flushed but not closed. -
write
Writes the generated script to a writer, which is flushed but not closed. -
write
Writes the generated script tofilename, overwriting it.
-