Service browser

The HTML service browser allows you to see the classes that are currently available in the services folder, to retrieve argument and usage informatino, to generate the methodTable, and to generate stub ActionScript code.

You can give the service browser a spin live here.

Setting up the service browser

Open browser/config.inc.php in a text editor. You need to change the $cfg variable to reflect your installation.

The default value (empty string) will browse the default services directory and will search your include path.

Browsing the services

Load the /flashservices/browser/ URL in your favorite browser. On the left-hand side, you will see the services that are available, as well as a MethodTable link. By clicking on one of the services, you can get a full description of its methods. You will also notice two textfields with AS2 and AS1 stub code which you can use as a template for your projects. By clicking on the MethodTable link, you can generate the methodTable for your class based on JavaDoc and your method’s signature, as outlined here.

Modifying the code templates

You can add a code template to the browser/templates directory and it will automatically be detected. Look at as2.php and as2.tpl to see how this works (starting with 1.0 MS2). You can use this feature to generate scaffolds adjusted to your coding style.

 

 

 

 


© amfphp.org | Disclaimer | Conditions of use