/[svn]/doc/docbase/instrument_scripts/nksp/reference/functions/nksp_exit_function.html
ViewVC logotype

Annotation of /doc/docbase/instrument_scripts/nksp/reference/functions/nksp_exit_function.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2732 - (hide annotations) (download) (as text)
Sun Apr 26 20:54:00 2015 UTC (8 years, 11 months ago) by schoenebeck
File MIME type: text/html
File size: 1457 byte(s)
* Initial import of doc.linuxsampler.org.

1 schoenebeck 2732 <html>
2     <head>
3     <meta name="author" content="Christian Schoenebeck">
4     <title>exit() function</title>
5     <meta name="description" content="Stops execution of the current event handler instance.">
6     </head>
7     <body>
8     <h1>exit()</h1>
9     <p>
10     Stops execution of the current event handler instance.
11     It does <b>not</b> stop execution of other
12     instances of the same event handler, nor does it stop execution of other
13     handlers of other event types, and especially it does <b>not</b> stop or
14     prevent further or future execution of your entire script! In other words,
15     you should rather see this function as a return statement, in case you are
16     familiar with other programming languages already.
17     </p>
18    
19     <h3>Function Prototype</h3>
20     <p/>
21     <code>
22     exit()
23     </code>
24    
25     <h3>Arguments</h3>
26     <p>None.</p>
27    
28     <h3>Return Value</h3>
29     <p>None.</p>
30    
31     <h3>Examples</h3>
32     <p/>
33     <code>
34     on init
35     declare $numberOfNotes
36     end on
37    
38     on note
39     $numberOfNotes := $numberOfNotes + 1
40    
41     select $numberOfNotes
42     case 1
43     message("First note was triggered!") { Will never be printed ! }
44     exit
45     case 2
46     message("Second note was triggered!") { Will never be printed ! }
47     exit
48     case 3
49     message("Third note was triggered!") { Will never be printed ! }
50     exit
51     end if
52    
53     message("The " & $numberOfNotes & "th note triggered.")
54     end on
55     </code>
56    
57     </body>
58     </html>

  ViewVC Help
Powered by ViewVC