public class G4LTL
extends java.lang.Object
"G4LTL is a standalone tool and a Java library for automatically generating controllers realizing linear temporal logic (LTL).
See http://sourceforge.net/projects/g4ltl/
This class uses classes defined in $PTII/lib/g4ltl.jar. See $PTII/lib/g4ltl-license.htm.
This class defines static methods for generating moml and updating models based on the contents of an LTL file.
Constructor and Description |
---|
G4LTL() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
generateMoML(java.io.File ltlFile,
int optionTechnique,
int unrollSteps,
boolean findStrategy,
NamedObj context)
Given a Linear Temporal Logic (LTL) file, generate the
corresponding MoML and update the MoML.
|
static g4ltl.utility.ResultLTLSynthesis |
synthesizeFromFile(g4ltl.SolverUtility solver,
java.io.File ltlFile,
int optionTechnique,
int unrollSteps,
boolean findStrategy)
Given a Linear Temporal Logic (LTL) file, generate the
corresponding MoML.
|
static java.lang.String |
updateModel(java.lang.String updatedMoML,
NamedObj context)
Update the model with MoML that was presumably generated by
generateMoML().
|
public static g4ltl.utility.ResultLTLSynthesis synthesizeFromFile(g4ltl.SolverUtility solver, java.io.File ltlFile, int optionTechnique, int unrollSteps, boolean findStrategy) throws java.lang.Exception
solver
- The G4LTL Solver to use.ltlFile
- The ltl file.optionTechnique
- and integer where 0 means CoBeuchi, 1 means BeuchiunrollSteps
- The number of unroll steps.findStrategy
- True if a strategy should be found, false if a counter-strategy should
be found. Typically a strategy is found first and then if the result does not contain a "<",
this method is called with findStrategy set to false to find a counter-strategy.java.lang.Exception
- If thrown while synthesizing.public static java.lang.String generateMoML(java.io.File ltlFile, int optionTechnique, int unrollSteps, boolean findStrategy, NamedObj context) throws java.lang.Exception
This is the main entry point for non-gui use of the g4ltl package. If finding a strategy fails the gui may want to ask the user if they want to find a counter strategy.
ltlFile
- The ltl file.optionTechnique
- and integer where 0 means CoBeuchi, 1 means BeuchiunrollSteps
- The number of unroll steps.findStrategy
- True if a strategy should be found, false if a counter-strategy should
be found. If a strategy cannot be found, then a counter-strategy is searched for.context
- The context for the change. One way to get the
context is by calling basicGraphFrame.getModel().java.lang.Exception
- If thrown while synthesizing.public static java.lang.String updateModel(java.lang.String updatedMoML, NamedObj context) throws java.lang.Exception
updatedMoML
- The moml from generateMoML()context
- The context for the change. One way to get the
context is by calling basicGraphFrame.getModel().java.lang.Exception
- If thrown while synthesizing.