2 Copyright (c) 2000-2014 Ericsson Telecom AB
4 All rights reserved. This program and the accompanying materials
5 are made available under the terms of the Eclipse Public License v1.0
6 which accompanies this distribution, and is available at
7 http://www.eclipse.org/legal/epl-v10.html
11 <meta http-equiv=
"Content-Type" content=
"text/html; charset=utf-8">
12 <meta http-equiv=
"Content-Language" content=
"en-us">
15 <body bgcolor=
"#DAD3C5" vlink=
"#0094D2" link=
"#003258">
16 <table align=
"left" border=
"0" cellspacing=
"0" cellpadding=
"0" valign=top
>
18 <td width=
105 height=
40><a href=
"https://projects.eclipse.org/projects/tools.titan"><img src=
"../images/titan_transparent.gif" border=
0 width=
105 height=
40 align=
"left" alt=
"Titan"></a></td>
21 <table border=
"0" align=
"right" cellpadding=
"0" cellspacing=
"0">
23 <td><a href=
"../titan_main.html" alt=
"contents"><img border=
"0" src=
"../images/ao.jpg" width=
"53" height=
"40"></a></td>
24 <td><a href=
"../titan_index.html" alt=
"index"><img border=
"0" src=
"../images/up.jpg" width=
"53" height=
"40"></a></td>
25 <td><a href=
"start.html" alt=
"previous"><img border=
"0" src=
"../images/left.jpg" width=
"53" height=
"40"></a></td>
26 <td><a href=
"str2bit.html" alt=
"next"><img border=
"0" src=
"../images/right.jpg" width=
"53" height=
"40"></a></td>
34 <p>0.
<a href=
"#Terminating execution">Terminating execution
</a></p>
35 <p>1.
<a href=
"#Terminating a test component">Stopping components
</a></p>
36 <p>2.
<a href=
"#Starting a port">Stopping ports
</a></p>
37 <p>3.
<a href=
"#timer">Stopping timers
</a></p>
38 <p>4.
<a href=
"profiler.html#1">Stopping the profiler
</a></p>
40 <hr align=
"left" width=
"75%">
41 <h3>0.
<a name=
"Terminating execution">Terminating execution
</a></h3>
42 <p>The stop statement is used to terminate test execution. Whenever a stop statement is reached, the execution of the underlying testcase is immediately terminatef. The result of execution will be
44 <hr align=
"left" width=
"50%">
47 <table border=
"0" width=
"90%" bgcolor=
"#FFB599" cellpadding=
"4">
50 <h3 align=
"center"><font face=
"Courier New" color=
"#003258" size=
"5"><b>stop;
</b></font></h3>
56 <hr align=
"left" width=
"50%">
57 <p><a href=
"#Example1b">Examples:
</a></p>
58 <hr align=
"left" width=
"75%">
61 <h3>1.
<a name=
"Terminating a test component">Stopping components
</a></h3>
63 <li>When used in a test case, altstep or function that are executed on a test component, the keyword terminates the relevant test component;
</li>
64 <li>when used in the control part of a module or in a function used by the control part of a module, it terminates the execution of the module control part.
</li>
65 <li>When prefixed with a component reference, other than the own component will be stopped;
</li>
66 <li>when prefixed with the
<a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a> <a href=
"component.html"> <b><font
67 face=
"Courier New" color=
"#003258" size=
"4">component
</font></b> </a> keyword pair, all components except the main test component will be stopped.
</li>
69 <p>Related keywords:
</p>
71 <li><a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a></li>
72 <li><a href=
"component.html"> <b><font face=
"Courier New" color=
"#003258" size=
"4">component
</font></b> </a></li>
73 <li><a href=
"create.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">create
</font></b></a></li>
74 <li><a href=
"profiler.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">@profiler
</font></b></a></li>
76 <hr align=
"left" width=
"50%">
79 <table border=
"0" width=
"90%" bgcolor=
"#FFB599" cellpadding=
"4">
82 <h3 align=
"center">[
<i>component_reference
</i><font face=
"Courier New" color=
"#003258" size=
"5"><b>.
</b></font>]
<font face=
"Courier New" color=
"#003258" size=
"5"><b>stop;
</b></font>
91 <p>The optional
<i>component_reference
</i> (used when other than the own component should be stopped) is one of the following:
</p>
93 <li>a reference returned by the
<a href=
"create.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">create
</font></b></a> operation to refer to a given component,
</li>
94 <li>the keyword pair
<a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a> <a href=
"component.html"> <b><font
95 face=
"Courier New" color=
"#003258" size=
"4">component
</font></b> </a> when referring to all parallel test components (the command must be issued in the main test component),
</li>
96 <li>the keyword
<a href=
"self.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">self
</font></b></a> when referring to the own component,
</li>
97 <li>the keyword
<a href=
"mtc.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">mtc
</font></b></a> when referring to the main test component.
<br>
102 <p>The
<b><font face=
"Courier New" color=
"#003258" size=
"4">stop
</font> </b> keyword denotes that (a) component(s) should be stopped.
</p>
105 <hr align=
"left" width=
"50%">
106 <p>See
<a href=
"#Example 4:">Examples
</a></p>
107 <hr align=
"left" width=
"75%">
110 <h3>2.
<a name=
"Stopping a port">Stopping a port
</a></h3>
111 <hr align=
"left" width=
"50%">
112 <p>The keyword may be used to stop a
<a href=
"#Example 2a">port
</a>.
</p>
114 <li>The operation causes listening at the named ports to cease and disallows the sending operations.
</li>
115 <li>The port may be restarted by a subsequent start operation.
</li>
116 <li>It is possible to stop all defined ports.
</li>
118 <p>Related keywords:
</p>
120 <li><a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a></li>
121 <li><a href=
"port.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">port
</font></b></a></li>
123 <hr align=
"left" width=
"50%">
126 <table border=
"0" width=
"90%" bgcolor=
"#FFB599" cellpadding=
"4">
129 <h3 align=
"center"><i>port_reference
</i><font face=
"Courier New" color=
"#003258" size=
"5"><b>.stop;
</b></font></h3>
137 <p><i> port_reference
</i> points out the port to be stopped.
</p>
140 <p>the keywords
<b><font face=
"Courier New" color=
"#003258" size=
"4">all port
</font> </b> may be used to indicate that all defined ports must be stopped (see the
<a href=
"#Example 2b">example
146 <p>The
<b><font face=
"Courier New" color=
"#003258" size=
"4">stop
</font> </b> keyword introduces port stopping.
</p>
149 <hr align=
"left" width=
"75%">
150 <h3>3.
<a name=
"timer">Stopping
timers
</a></h3>
151 <hr align=
"left" width=
"50%">
152 <p>The keyword may be used to indicate that a
<a href=
"#timer_start">timer should stop running
</a>.
</p>
154 <li><a name=
"stop_all">The
</a> keyword
<a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a> may be used to
<a href=
"#default"> stop all timers
</a> that are
155 visible in the scope unit in which the operation has been called.
</li>
156 <li>Stopping an inactive timer is a valid operation, although it does not have any effect.
</li>
157 <li>Stopping an expired timer causes the entry for this timer in the timeout-list to be removed.
</li>
159 <p>Related keywords:
</p>
161 <li><a href=
"all.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">all
</font></b></a></li>
162 <li><a href=
"read.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">read
</font></b></a></li>
163 <li><a href=
"running.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">running
</font></b></a></li>
164 <li><a href=
"timer.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">timer
</font></b></a></li>
165 <li><a href=
"start.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">start
</font></b></a></li>
166 <li><a href=
"timeout.html"><b><font face=
"Courier New" color=
"#003258" size=
"4">timeout
</font></b></a></li>
168 <hr align=
"left" width=
"50%">
171 <table border=
"0" width=
"90%" bgcolor=
"#FFB599" cellpadding=
"4">
174 <h3 align=
"center">(
<i>timer_identifier
</i> |
<font face=
"Courier New" color=
"#003258" size=
"5"><b>all timer
</b></font> )
<font face=
"Courier New" color=
"#003258" size=
"5"><b>.stop
</b></font>
175 <font face=
"Courier New" color=
"#003258" size=
"5"><b>;
</b></font></h3>
183 <p><i>timer_identifier
</i> is the
name used to refer to the timer. It must begin with a letter, may contain letters, numbers and underscore characters.
</p>
186 <hr align=
"left" width=
"50%">
187 <p>It is possible to stop a member of an
<a href=
"#array">timer array
</a>.
</p>
188 <hr align=
"left" width=
"50%">
191 <table border=
"0" width=
"90%" bgcolor=
"#FFB599" cellpadding=
"4">
194 <h3 align=
"center"><font face=
"Courier New" color=
"#003258" size=
"5"><b></b></font> <i>timer_identifier
</i><font face=
"Courier New" color=
"#003258" size=
"5"><b>[
</b></font><i>array_index
</i><font
195 face=
"Courier New" color=
"#003258" size=
"5"><b>].stop;
</b></font></h3>
201 <div align=
"center"></div>
204 <p><i>timer_identifier
</i> is the
name used to refer to the timer. It must begin with a letter, may contain letters, numbers and underscore characters.
</p>
207 <p><i>array_index
</i> points out the timer to be stopped.
</p>
210 <p><a href=
"#timer_start">Examples
</a></p>
211 <hr align=
"left" width=
"50%">
212 <p><a name=
"Example 4:">Example
1a:
</a>
213 <p><font face=
"Courier New">self.stop;
</font>
214 <p>The own test component is terminated. (The command was issued in a test case, altstep or function that are executed on a test component).
</p>
215 <hr align=
"left" width=
"50%">
216 <p><a name=
"Example1b">Example
1b
</a>:
217 <p><font face=
"Courier New">stop;
</font>
218 <p>The test case execution is interrupted.
219 <hr align=
"left" width=
"50%">
220 <p><a name=
"Example 1c">Example
1c
</a>:
221 <p><font face=
"Courier New">vc_Hivatkozaas.stop;
</font>
222 <p>The component with the reference vc_Hivatkozaas is stopped.
</p>
223 <hr align=
"left" width=
"50%">
225 <p><font face=
"Courier New">all component.stop;
</font>
226 <p>All test components except the main test controller are stopped.
</p>
227 <hr align=
"left" width=
"50%">
229 <p><font face=
"Courier New">self.stop;
</font>
230 <p>The own test component is stopped. It has the same effect as in
<a href=
"#Example 4:">example
1a
</a></p>
231 <hr align=
"left" width=
"50%">
233 <p><font face=
"Courier New">mtc.stop;
</font>
234 <p>The main test component is stopped.
</p>
235 <hr align=
"left" width=
"50%">
236 <p><a name=
"Example 2a">Example
2a
</a>:
237 <p><font face=
"Courier New">Kapu_PCO.stop;
</font>
238 <p>The port Kapu_PCO will be stopped.
</p>
239 <hr align=
"left" width=
"50%">
240 <p><a name=
"Example 2b">Example
2b
</a>:
241 <p><font face=
"Courier New">all port.stop;
</font>
242 <p>All ports will be stopped.
</p>
243 <hr align=
"left" width=
"50%">
244 <p><a name=
"timer_start">Example
3a
</a>:
245 <p><font face=
"Courier New">T_soek.stop;
<br>
247 <p>The global timer T_soek is stopped provided that it was running, otherwise the command has no effect.
</p>
248 <hr align=
"left" width=
"50%">
249 <p><a name=
"default">Example
3b:
</a>
250 <p><font face=
"Courier New">all timer.stop;
<br>
252 <p>The local timer Tl_foerlorad is declared (
1st line) and stoped with a duration of
20 ms (
2nd line).
</p>
253 <hr align=
"left" width=
"50%">
254 <p><a name=
"array">Example
3c:
</a>
255 <p><font face=
"Courier New">timer Tl_Denfert[
2] := {-,
1E-1, -};
<br>
256 Tl_Denfert[
1].stop(
20E-3);
</font>
257 <p>The array of
local timers declared is called Tl_denfert and consists of three timers . The second timer has the default value of
100 ms, the others have no default value(
1st
258 line).
The second timer in the array is stoped for
20 ms, overwriting the default value of
100 ms (
2nd line).
</p>
259 <hr align=
"left" width=
"25%">
260 <hr align=
"left" width=
"25%">
261 <p><a HREF=
"BNF.html#stoptcstatement">BNF definition
</a> of
<font face=
"Courier New">component stop
</font></p>
262 <p><a HREF=
"BNF.html#stoptimerstatement">BNF definition
</a> of
<font face=
"Courier New">timer stop
</font></p>