BoxLang 🚀 A New JVM Dynamic Language Learn More...
|:------------------------------------------------------: |
| ⚡︎ B o x L a n g ⚡︎
| Dynamic : Modular : Productive
|:------------------------------------------------------: |
Copyright Since 2023 by Ortus Solutions, Corp
www.boxlang.io | www.ortussolutions.com
This module will allow your ColdFusion (CFML) applications under Adobe or Lucee to run under BoxLang. This module will provide the necessary compatibility layer to run your applications under BoxLang.
If there are any issues, please report them to the BoxLang JIRA or the Module Issues repository.
Here are the available settings for the compat module:
settings = {
// The engine to mimick: adobe or lucee
engine = "lucee",
// JSON control character auto-escaping flag
// IF you turn to true, be aware that the entire JSON serialization will be escaped and be slower.
jsonEscapeControlCharacters = true,
// This simulates the query to empty value that Adobe/Lucee do when NOT in full null support
// We default it to true to simulate Adobe/Lucee behavior
queryNullToEmpty = true,
// The CF -> BL AST transpiler settings
// The transpiler is in the core, but will eventually live in this module, so the settings are here.
transpiler = {
// Turn foo.bar into foo.BAR
upperCaseKeys = true,
// Add output=true to functions and classes
forceOutputTrue = true,
// Merged doc comments into actual function, class, and property annotations
mergeDocsIntoAnnotations = true
}
}
The valid engines are adobe
or lucee
. By default the engine is lucee
. All module settings can be changed via the boxlang.json
in your configuration.
"modules" : {
"compat-cfml" : {
"disabled" : false,
"settings" : {
"engine" : "adobe",
// JSON control character auto-escaping flag
// IF you turn to true, be aware that the entire JSON serialization will be escaped and be slower.
jsonEscapeControlCharacters = true,
// This simulates the query to empty value that Adobe/Lucee do when NOT in full null support
// We default it to true to simulate Adobe/Lucee behavior
queryNullToEmpty = true,
// The CF -> BL AST transpiler settings
// The transpiler is in the core, but will eventually live in this module, so the settings are here.
transpiler = {
// Turn foo.bar into foo.BAR
upperCaseKeys = true,
// Add output=true to functions and classes
forceOutputTrue = true,
// Merged doc comments into actual function, class, and property annotations
mergeDocsIntoAnnotations = true
}
}
}
}
Depending on which engine you select an interceptor will be loaded that will seed the server
scope with the appropriate engine details.
The compat module will contribute the following built-in functions globally:
cacheClear
- Learn more here: https://cfdocs.org/cacheClearcacheCount
- Learn more here: https://cfdocs.org/cacheCountcacheGet
- Learn more here: https://cfdocs.org/cacheGetcacheGetAll
- Learn more here: https://cfdocs.org/cacheGetAllcacheGetAllIds
- Learn more here: https://cfdocs.org/cacheGetAllIdscacheGetAsOptional
- Learn more here: https://cfdocs.org/cacheGetAsOptionalcacheGetDefaultCacheName
- Learn more here: https://cfdocs.org/cacheGetDefaultCacheNamecacheGetEngineProperties
- Learn more here: https://cfdocs.org/cacheGetEnginePropertiescacheGetMetadata
- Learn more here: https://cfdocs.org/cacheGetMetadatacacheGetOrFail
- Learn more here: https://cfdocs.org/cacheGetOrFailcacheGetProperties
- Learn more here: https://cfdocs.org/cacheGetPropertiescacheGetSession
- Learn more here: https://cfdocs.org/cacheGetSessioncacheIdExists
- Learn more here: https://cfdocs.org/cacheIdExistscachePut
- Learn more here: https://cfdocs.org/cachePutcacheRegionExists
- Learn more here: https://cfdocs.org/cacheRegionExistscacheRegionNew
- Learn more here: https://cfdocs.org/cacheRegionNewcacheRegionRemove
- Learn more here: https://cfdocs.org/cacheRegionRemovecacheRemove
- Learn more here: https://cfdocs.org/cacheRemovecacheRemoveAll
- Learn more here: https://cfdocs.org/cacheRemoveAllcacheSetProperties
- Learn more here: https://cfdocs.org/cacheSetPropertiesdeleteClientVariable
- Learn more here: https://cfdocs.org/deleteClientVariablegetClientVariablesList
- Learn more here: https://cfdocs.org/getClientVariablesListgetComponentMetadata
- Learn more here: https://cfdocs.org/getComponentMetadatagetMetaData
- Learn more here: https://cfdocs.org/getMetaDatagetVariable
- Learn more here: https://cfdocs.org/getVariablesetVariable
- Learn more here: https://cfdocs.org/setVariablesystemOutput
- Learn more here: https://cfdocs.org/systemOutputBoxLang is a professional open-source project and it is completely funded by the community and Ortus Solutions, Corp. Ortus Patreons get many benefits like a cfcasts account, a FORGEBOX Pro account and so much more. If you are interested in becoming a sponsor, please visits our patronage page: https://patreon.com/ortussolutions
"I am the way, and the truth, and the life; no one comes to the Father, but by me (JESUS)" Jn 14:1-12
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
getMetadata()
with a DynamicObject
make sure the class is unwrappedclientManagement
setting to false
to avoid issues with Adobe/Lucee CFML enginesCFIDE
mapping for compatibility for orm
and scheduler
interfacesClient
scopestruckKeyExists()
transpilersgetTagData()
and getFunctionData()
lucee compatstoUnmodifiable
from toImmutable
cftoken
migration to comply with CFML engines.cfid
migration to comply with CFML engines.serializeJSON()
structGet()
and invalid paths not working with null
valuesstructGet()
not adhering to the actual Adobe CFML behaviorbx-compat-cfml
to better describe the module// The CF -> BL AST transpiler settings
// The transpiler is in the core, but will eventually live in this module, so the settings are here.
transpiler = {
// Turn foo.bar into foo.BAR
upperCaseKeys = true,
// Add output=true to functions and classes
forceOutputTrue = true,
// Merged doc comments into actual function, class, and property annotations
mergeDocsIntoAnnotations = true
}
getVariable()
, setVariable()
, getComponentMetadata()
, getMetaData()
, deleteClientVariable()
, getClientVariablesList()
queryNullToEmpty
is set to true, which is the defaultobjectLoad(), and objectSave()
aliases for objectSerialize()
and objectDeserialize()
respectively.engine
so you can chose "adobe" or "lucee" instead of the boolean operatorsboxlangVersion
property
$
box install bx-compat-cfml