RTMP/E

 removeApp(appName:String) : Object

HTTP

 http://www.example.com:1111/admin/removeApp?auser=username&apswd=password&appName=name

Removes the specified application or instance of an application from the virtual host. First, all instances of the specified application are unloaded. Then the application directory is removed from the virtual host. If you specify an instance of an application, only that instance is unloaded and removed, and all streams and shared objects for that instance are deleted.

Availability

Flash Communication Server 1.0.

Parameters

appName

A String indicating the name of the application or instance of the application you want to remove, in the form application_name[/instance_name].

auser

A String indicating the user name of the administrator.

apswd

A String indicating the password of the administrator.

Returns

RTMP/E

If the call succeeds, the server sends a reply information object with a level property of status and a code property of NetConnection.Call.Success.

If the call fails, the server sends a reply information object with a level property of error and a code property of NetConnection.Admin.Command.Failed or a more specific value, if available. Some objects might also have a description property that contains a string describing the cause of the failure.

HTTP

If the call succeeds, it returns XML with the following structure:

 <result>   <level></level>   <code></code>   <timestamp></timestamp>  </result>

If the call fails, it returns XML with the following structure:

 <result>   <level></level>   <code></code>   <description></description>   <timestamp></timestamp>  </result>

The XML elements contain the same information as the Object properties returned in an RTMP/E call.

Note: The timestamp response over HTTP is formatted differently on Windows (9/23/2007 6:16:40 PM) and Linux (Sun 23 Sep 2007 06:16:40 PM IST).

Example

The following example shows how you remove the entire application ChatApp and then shows how you remove a specific instance Instance1 of an application ChatApp.

 nc_admin = new NetConnection(); 
 nc_admin.connect("rtmp://localhost:1111/admin", "JGarcia", "ezcabby1"); 
  
 /* Removes the application along with all instances of the application */ 
  
 nc_admin.call("removeApp", new onRemoveApp(), "ChatApp"); 
  
 /* Removes only the specified instance */ 
  
 nc_admin.call("removeApp", new onRemoveApp(), "ChatApp/Instance1");

See also

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License  Twitter™ and Facebook posts are not covered under the terms of Creative Commons.

Legal Notices   |   Online Privacy Policy