coldfusion

Topics related to coldfusion:

Getting started with coldfusion

This section provides an overview of what coldfusion is, and why a developer might want to use it.

It should also mention any large subjects within coldfusion, and link out to the related topics. Since the Documentation for coldfusion is new, you may need to create initial versions of those related topics.

CFLOOP How-To

Database Queries

Variables

How to invoke a private method dynamically

Use of <cfinvoke> or invoke() should be faster than evaluate()

cfquery

ColdFusion Arrays

In a synchronized array, more than two threads cannot access the array simultaneously. Other threads has to wait until the active thread completes its job, resulting in significant performance.

In 2016 ColdFusion release, you can use an unsynchronized array and let multiple threads access the same array object simultaneously.

Scopes in Coldfusion

Working with RegExp Replace callbacks

Because Coldfusion itself does not offer what we want, we make recourse to the variety of Java, which is — as we all know — on top of Coldfusion. Java offers us java.util.regex.Pattern.

So here is what we actually do:

  1. Invoke the Compile method from the Pattern Class object and passing the regex pattern to it (which probably deposits the regex pattern for later use).
  2. Invoke the Matcher method on what the Compile method returned and passing the string where the pattern should be executed.
  3. Test if matching was successfull by invoking the find method on what the Matcher method returned.

If matcher.find() returns true, we could say "That's it", but there is one little thing we have to consider: Java's Pattern object stores the groups and gives us access via another function, which is not always the best way for further processing and not that consistent regarding how other programming languages handle this case. Therefore we loop over matcher.group() so that we can pass an array containing the captured groups to the callback function. And now we can say: "That's it!"

Creating REST APIs in coldfusion