NetDebugConfig.getDebug( )


NetDebugConfig.getDebug( ) Method Flash 6

returns the current state of NetConnection debugging
   myConnection   .getDebugConfig(   id   ).getDebug( ) 

Returns

A Boolean indicating the current state of debugging in the Flash Remoting application.

Description

The getDebug( ) method returns the current state of debugging in Flash Remoting. Debugging can be on or off and can be set programmatically with the setDebug( ) method. When debugging is on, the NetConnection debugger receives events and logs messages. When debugging is off, the NetConnection debugger is inactive.

The NetDebug.as file must be included in order to use the getDebug( ) method.

Example

The following code shows the basic syntax of the getDebug( ) method:

 #include "NetServices.as" #include "NetDebug.as" if (connected == null) {   connected = true;   NetServices.setDefaultGatewayUrl("http://127.0.0.1/flashservices/gateway");   var my_conn = NetServices.createGatewayConnection( );   var my_service = my_conn.getService("com.oreilly.frdg.searchProducts");   trace(my_conn.getDebugConfig( ).getDebug( )); } 

The trace( ) statement displays the current state of debugging in this particular application, which should be on because it has not been turned off in the code.

Bugs

At the time of this writing, this method returns `undefined' in all cases. It has been removed from Macromedia's online documentation at http://livedocs.macromedia.com/flashremoting/mx/Using_Flash_Remoting_MX/asDict4.htm#91933 and should be considered unsupported until Macromedia updates their documentation.

See Also

The NetDebug object, Table 15-2 under the NetDebugConfig object, NetDebugConfig.setDebug( ) ; Chapter 13



Flash Remoting
Flash Remoting: The Definitive Guide
ISBN: 059600401X
EAN: 2147483647
Year: 2003
Pages: 239
Authors: Tom Muck

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net