No edit summary |
No edit summary |
||
Line 48: | Line 48: | ||
Example | Example | ||
probcli my.mch ... | |||
=== -no<x> === | === -no<x> === | ||
Line 60: | Line 60: | ||
Example | Example | ||
probcli my.mch ... | |||
=== -bf === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| proceed breadth-first | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -df === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| proceed depth-first | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== --timeout <N> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| Timeout in ms for model checking and refinement checking | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -t === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| trace check (associated .trace file must exist) | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -init === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| initialise specification | |||
|} | |||
Example | |||
probcli my.mch -init | |||
=== -cbc <OPNAME> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| constraint-based invariant checking for an operation (also use <OPNAME>=all) | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -cbc_deadlock === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| constraint-based deadlock checking (also use -cbc_deadlock_pred PRED) | |||
|} | |||
=== -cbc_deadlock_pred <<PRED>> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -strict === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| raise error if mc finds counter example or trace checking fails | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -expcterr <ERR> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| expect error to occur (<ERR>=cbc,mc,ltl,...) | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -i === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| interactive animation | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -eval === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| start interactive read-eval-loop | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -c === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| print coverage statistics | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -cc <Nr> <Nr> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| print and check coverage statistics | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -p <PREF> <VAL> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| set Preference to Value | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -card <GS> <VAL> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| set scope of B deferred set | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -goal <PRED> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| set GOAL predicate for model checker | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -s <PORT> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| start socket server on given port | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -ss === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| start socket server on port 9000 | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -sf === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| start socket server on some free port | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -l <LogFile> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| log activities in <LogFile> | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -ll === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| log activities in /tmp/prob_cli_debug.log | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -lg <LogFile> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| analyse <LogFile> using gnuplot | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -pp <FILE> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| pretty-print internal representation to <FILE> | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -ppf <FILE> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| pretty-print internal representation to <FILE>, force printing of all type infos | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -v === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| verbose | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -version === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| print version information | |||
|} | |||
Example | |||
probcli.exe -version | |||
ProB Command Line Interface | |||
VERSION 1.3.3-final3 ($Rev: 7316 $) | |||
$LastChangedDate: 2011-03-09 17:14:00 +0100 (Mi, 09 Mrz 2011) $ | |||
Prolog: SICStus 4.1.3 (x86-win32-nt-4): Wed Sep 22 21:41:09 WEDT 2010 | |||
=== -assertions === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| check ASSERTIONS | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -properties === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| check PROPERTIES | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -rc === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| runtime checking of types/pre-/post-conditions | |||
|} | |||
Example | |||
probcli my.mch ... | |||
=== -ltlfile <FILE> === | |||
Description | |||
{| style="color:black; background-color:#FFFFEF; border:1px solid lightgray;" cellpadding="10" cellspacing="0" width="100%" | |||
| check LTL formulas in file <FILE> | |||
|} | |||
Example | |||
probcli my.mch ... | |||
== Some probcli examples == | == Some probcli examples == |
The command-line version of ProB offers many of the feature of the standalone Tcl/Tk Version via the command-line. As such, you can run ProB from your shell scripts or in your Makefiles.
The following conventions are used in this guide:
<replaceme> | All values that should be replaced with some value are shown withing < > |
line breaks | Command synopsis for command may be broken up on several lines. When typing commands enter all option on the same line. |
probcli [--help] <filename> [ <options> ]
Note that the stand-alone Tcl/Tk version also supports a limited form of command-line preferences:
However, the comand-line version of ProB, called probcli, provides more features. It also does not depend on Tcl/Tk and can therefore be run on systems without Tcl/Tk.
Description
model check; checking at most <nr> states |
Example
probcli my.mch ...
Description
<x>=dead,inv,goal,ass (for model check) |
Example
probcli my.mch ...
Description
proceed breadth-first |
Example
probcli my.mch ...
Description
proceed depth-first |
Example
probcli my.mch ...
Description
Timeout in ms for model checking and refinement checking |
Example
probcli my.mch ...
Description
trace check (associated .trace file must exist) |
Example
probcli my.mch ...
Description
initialise specification |
Example
probcli my.mch -init
Description
constraint-based invariant checking for an operation (also use <OPNAME>=all) |
Example
probcli my.mch ...
Description
constraint-based deadlock checking (also use -cbc_deadlock_pred PRED) |
Description
Example
probcli my.mch ...
Description
raise error if mc finds counter example or trace checking fails |
Example
probcli my.mch ...
Description
expect error to occur (<ERR>=cbc,mc,ltl,...) |
Example
probcli my.mch ...
Description
interactive animation |
Example
probcli my.mch ...
Description
start interactive read-eval-loop |
Example
probcli my.mch ...
Description
print coverage statistics |
Example
probcli my.mch ...
Description
print and check coverage statistics |
Example
probcli my.mch ...
Description
set Preference to Value |
Example
probcli my.mch ...
Description
set scope of B deferred set |
Example
probcli my.mch ...
Description
set GOAL predicate for model checker |
Example
probcli my.mch ...
Description
start socket server on given port |
Example
probcli my.mch ...
Description
start socket server on port 9000 |
Example
probcli my.mch ...
Description
start socket server on some free port |
Example
probcli my.mch ...
Description
log activities in <LogFile> |
Example
probcli my.mch ...
Description
log activities in /tmp/prob_cli_debug.log |
Example
probcli my.mch ...
Description
analyse <LogFile> using gnuplot |
Example
probcli my.mch ...
Description
pretty-print internal representation to <FILE> |
Example
probcli my.mch ...
Description
pretty-print internal representation to <FILE>, force printing of all type infos |
Example
probcli my.mch ...
Description
verbose |
Example
probcli my.mch ...
Description
print version information |
Example
probcli.exe -version ProB Command Line Interface VERSION 1.3.3-final3 ($Rev: 7316 $) $LastChangedDate: 2011-03-09 17:14:00 +0100 (Mi, 09 Mrz 2011) $ Prolog: SICStus 4.1.3 (x86-win32-nt-4): Wed Sep 22 21:41:09 WEDT 2010
Description
check ASSERTIONS |
Example
probcli my.mch ...
Description
check PROPERTIES |
Example
probcli my.mch ...
Description
runtime checking of types/pre-/post-conditions |
Example
probcli my.mch ...
Description
check LTL formulas in file <FILE> |
Example
probcli my.mch ...
To load a file My.mch, setup the constants and initialize it do:
probcli -init My.mch
To load a file M.mch, setup the constants, initialize and then check all assertions with Atelier-B's default values for MININT and MAXINT and an increased timeout of 5 seconds do:
probcli -init -assertions -p MAXINT 2147483647 -p MININT -2147483647 -p TIME_OUT 5000 M.mch