J | F | T | r | a | c | e |
User Guide
JFTrace is a program that presents trace output from JavaFrame applications. This document describes how to use JFTrace and the possibilities to search and filter transition records. When a filter is applied, the output from a JavaFrame application is presented in a table showing elapsed time, input signal, name of state machine, current state, transition behavior, next state. The next sections will show how to proceed.
The first action a user must take is to select input method. There are two input methods to JFTrace, file and socket. Both methods are selected from the File menu.
Select Open File to read a trace file from the filesystem. The file chooser let you navigate in the file system to select a trace file produced by JavaFrame. Below the separator in the pop-up menu, the last opened files are displayed. JFTrace will save a hot file list with references to the last 8 selected file names.
Select Open Input Socket to obtain a socket connection. A dialog box will let you specify a port number. The port number must be the same as you have specified in the Trace-object in the JavaFrame-application. In the included examples the port number is specified as a run-time parameter to JavaFrame application (e.g. -remote localhost:54321).
NOTE: It is important to start the JFTrace and select the socket input before a JavaFrame application starts to send trace output. |
After an input file is selected or a socket connection is established, a search form is displayed. The fields in search form correspond to fields in the trace output and you can selectively search for records by specifying a search string. You can search the trace output in two ways, either based on sub-string matching or based on regular expressions. Both search methods are case sensitive. A blank field in the search form will match all trace output for that field. Likewise, if you don't specify a filter (i.e. just press the Apply Filter button), all trace output will be displayed in the trace table. Tick off the checkbox Use regular expression if you want to set up a filter based on regular expressions. The filter is activated by pressing the Apply Filter button and the filtered trace will be shown in a table.
Extended regular expression can then be specified in the form. The regular expression must match the whole field. Empty field(s) will match everything and equal to the regular expression ".*". The following meta-characters will be used as operators in the regular expression.
Positional operators | |
^ | Matches at the beginning of a line |
$ | Matches at the end of a line |
One-Character Operator | |
. (dot) |
Matches any single character |
Repeating Operators | |
* |
Matches the null string or any number of repetitions of the preceding expression |
+ |
Matches one or more repetitions of the preceding expression |
? |
Matches the preceding expression or the null string |
{m} | Matches exactly m repetitions of the preceding expression |
{m,n} | Matches between m and n repetitions of the preceding expression, inclusive |
{m,} | Matches m or more repetitions of the preceding expression |
Alternation operator | |
a|b |
Matches whatever the expression a would match, or whatever the expression b would match |
|
List operators |
[abc] | matches any character in the set a, b or c |
[^abc] | matches any character not in the set a, b or c |
[a-z] | matches any character in the range a to z, inclusive |
Note! If you want to explicit search any of the meta-characters above the characters must be escaped by '\' .
When pressing the Apply Filter button the filtered trace records will be shown in a table. The displayed trace record(s) is a result of and-operation (conjunction) of all field search match expressions. This applies also when you do not use regular expression.
If you use a socket connection as input, you can change
filter on the fly by specifying a new filter and press the Apply
Filter button.
In case you previously have selected a file and search the file, you can
specify a new filter and press the Apply Filter button. The
file will then be reopened and searched again.
When pressing the Clear Table button, all the data in the table will be deleted.
When pressing the Clear Form button, all fields will be cleared in the form.
When pressing the Exit button, the application exits.
The filtered trace is shown as a table. In the heading of
the window, the origin and date of the trace is displayed.
The state names in JavaFrame 2.0 and higher is shown as
composite states with '^' as a separator between enclosing states. The
state name start with the innermost state,
e.g. innerCompositeState^outerCompositeState^OutermostCompositeState
.
There are six columns in table.
Time |
Elapsed time in milliseconds since start up. |
State Machine |
Name of state machine instance |
Current State |
Name of the current state. |
Input |
Name of the input message. After the "=" , displays the content of the message. |
Transition behaviour |
Lists the transition behaviour. The following transition behaviour is displayed :
This message: ### Error in transition ### will be displayed if the transition error is detected in the trace. |
Next State | Name of the next state of the
state machine. Otherwise, Save transitions are displayed as Saved. or Default transitions are marked with Default transition . |
A log window will be displayed below the buttons in the filter window when you start searching. The log window display error messages.
The menu choice Table gives options to save trace data:
The menu choice View provides functionality to select individual columns.
The menu choice View can turn off and on each
individual column.
Note! When a column is turned on again, it will always appear
as the last column.