The ColdFusion Services Browser lets you view all of the CFCs and web services on your computer.

Use the Services Browser

  1. In Flash Builder or Eclipse, select Window > Show View > Other.
  2. Select ColdFusion > Services Browser.
    The Services Browser can do the following:
  • Browse components
  • Manage web services

Browsing components

The Service Browser lists the following components:

  • Components that the ColdFusion component browser listsThe ColdFusion component browser is located at cf_root/wwwroot/CFIDE/componentutils/componentdoc.cfm.
  • Components that are located in any directories specified in the ColdFusion Administrator Mappings page
  • Components that are located in any directories specified in the ColdFusion Administrator Custom Tag paths page
    You can restrict the list of CFCs according to whether the functions in a CFC are remote, public, or private. 
    A sample element of the list appears as follows:
Component list
Component list

The first line of the listing contains the path. The second line includes the name of the CFC. The next two lines contain the names of the functions in the CFC. The function name is followed by any argument, a colon, then the type of the return value. The listing echo(echoString):STRING indicates that the echo function has an argument named echoString, and that it returns a string. The myCFC CFC appears as follows:

<cffunction name="echo" output="No" returntype="string">
<cfargument name="echoString" required="Yes">
<cfreturn "echo: #arguments[1]#">
</cffunction>

<cffunction name="getArtists" returntype="query" hint="query the database and return the
results.">
<cfquery name="artists" datasource="cfcodeexplorer">
select *
from artists
</cfquery>
<cfreturn artists>
</cffunction>
</cfcomponent>

Managing web services

The Services Browser lets you manage a list of web services by adding or deleting WSDL URLs from a list. In addition, when you are editing a ColdFusion file, you can use the Services Browser to generate CFML code to invoke a web service or to create a web service object. Similarly, when you are editing an ActionScript file, you can use the Services Browser to generate ActionScript.
To view the list of web services, click the Show Web Services button in the top right corner of the Services Browser view.

Add a web service to the list
  1. Right-click in the Services Browser view.
  2. Select Add WSDL.
  3. Enter a valid WSDL URL.
  4. Click OK.
Delete a web service from the list
  1. Right-click in the Services Browser view.
  2. Select Delete WSDL.
Invoke a web service in ColdFusion
  1. Place your mouse pointer where you want to insert the code.
  2. View the list of web services.
  3. Highlight a web service or a method in a web service and right-click.
  4. Select Insert CFInvoke.
    The code that the Service Browser generates appears in the ColdFusion file. The following is an example of the code that the Service Browser generates:
webservice="http://arcweb.esri.com/services/v2/MapImage.wsdl"
method="convertMapCoordToPixelCoord"
returnVariable="convertMapCoordToPixelCoord" >
<cfinvokeargument name="mapCoord" type="" />
<cfinvokeargument name="viewExtent" type="" />
<cfinvokeargument name="mapImageSize" type="" />
</cfinvoke>

Create a web service object in ColdFusion

 

  1. Place your mouse pointer where you want to insert the code.
  2. View the list of web services.
  3. Highlight a web service or a method in a web service and right-click.
  4. Select Insert CFInvoke.
    The code that the Service Browser generates appears in the ColdFusion file. The following is an example of the code that the Service Browser generates:
createObject("webservice", "http://arcweb.esri.com/services/v2/MapImage.wsdl").convertMapCoordToPixelCoord(mapCoord, viewExtent, mapImageSize);

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