MACROMEDIA FLASH MEDIA SERVER 2-CLIENT-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR FLASH MEDIA SERVER 2 Manuale Utente Pagina 9

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 172
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 8
6
SERVER-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR ADOBE MEDIA SERVER 5.0.1
Server-Side ActionScript Language Reference
Last updated 7/2/2013
function callback1(){trace("interval called"); }
setInterval(callback1, 1000);
The following example also uses a named function, callback2(), to send the message "interval called" to the
server log, but it passes the message to the function as a parameter:
function callback2(s){
trace(s);
}
setInterval(callback2, 1000, "interval called");
The following example uses the second syntax:
var a = new Object();
a.displaying=displaying;
setInterval(a.displaying, 3000);
displaying = function(){
trace("Hello World");
}
The previous example calls the displaying() method every 3 seconds and sends the message "Hello World" to the
server log.
See also
clearInterval()
trace()
trace(expression)
Evaluates an expression and displays the value. You can use the trace() function to debug a script, to record
programming notes, or to display messages while testing a file. The
trace() function is similar to the alert()
function in JavaScript.
The expression appears in the Live Log panel of the Administration Console; it is also published to the
application.xx.log file located in a subdirectory of the RootInstall\logs folder. For example, if an application is called
myVideoApp, the application log for the default application instance would be located here:
RootInstall\logs\_defaultVHost_\myVideoApp\_definst_.
Availability
Flash Communication Server 1
Parameters
expression Any valid expression. The values in expression are converted to strings if possible.
Application class
Every instance of a Adobe Media Server application has an Application object, which is a single instance of the
Application class. You don’t need to use a constructor function to create an Application object; it is created
automatically when an application is instantiated by the server.
Vedere la pagina 8
1 2 3 4 5 6 7 8 9 10 11 12 13 14 ... 171 172

Commenti su questo manuale

Nessun commento