O'Reilly logo

Programming ColdFusion MX, 2nd Edition by Rob Brooks-Bilson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Advanced CFC Topics

I mentioned several advanced CFC topics briefly earlier in this chapter. These topics included introspection, inheritance, CFC security, and assigning component instances to shared variable scopes. This section presents a more detailed exploration of each of these topics.

Introspection

One of the coolest features of CFCs is that they are self-documenting. All of the various tag attributes we discussed throughout the chapter, along with any user-defined attributes, are available as component metadata. This metadata exists as a ColdFusion structure that can be used for all sorts of purposes. ColdFusion MX comes with a tool called the CFC Explorer that you can use to introspect any CFC on your ColdFusion server. To use the CFC Explorer, simply fire up a browser and enter the URL to the CFC you want to introspect. You should be presented with the CFC Explorer login screen shown in Figure 22-3.

ColdFusion Administrator RDS password prompt for accessing the CFC Explorer

Figure 22-3. ColdFusion Administrator RDS password prompt for accessing the CFC Explorer

You’ll need to enter the RDS password for the server to use the CFC browser Once you’ve entered a valid RDS password, ColdFusion MX allows you to proceed to the CFC Explorer. The CFC Explorer displays a nicely formatted screen containing the component’s metadata, including the component’s name, path on the server, properties, and methods. A sample CFC Explorer screen is shown in Figure 22-4 ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required