User Guide
1086 Chapter 8: ColdFusion Java CFX Reference
Syntax
public Query getQuery()
Example
The following example retrieves a query that was passed to a tag. If no query was passed, an
exception is thrown:
Query query = request.getQuery() ;
if ( query == null )
{
throw new Exception(
"Missing QUERY parameter. " +
"You must pass a QUERY parameter in "
"order for this tag to work correctly." ) ;
}
getSetting
Description
Retrieves the value of a global custom tag setting. Custom tag settings are stored in the
CustomTags section of the ColdFusion Registry key.
Returns the value of the custom tag setting. If no setting of that name exists, an empty string is
returned.
Category
Request interface
Syntax
public String getSetting(String name)
Parameters
Usage
All custom tags implemented in Java share a registry key for storing settings. To avoid name
conflicts, preface the names of settings with the name of your custom tag class. For example, the
code below retrieves the value of a setting named VerifyAddress for a custom tag class named
MyCustomTag:
String strVerify = request.getSetting("MyCustomTag.VerifyAddress") ;
if ( Boolean.valueOf(strVerify) )
{
// Do address verification...
}
Parameter Description
name The name of the setting to retrieve (case-insensitive)