Skip to content

[Back to Parameters]

Text

A widget that allows users to enter text and offers a mode for an enriched editor with syntax highlighting.

Key Type Required Default Description UPM/TD
readOnly bool ❌ false If true, parameter will not be editable. ❌
editor enum ❌ plaintext Specifies the syntax of the parameter value.
The editor UI will be customized based on this setting,
including syntax highlighting and validation in some cases.
✔1
trimWhitespace bool ❌ false If true, whitespace will be trimmed from the beginning and end of the parameter value. ✔
showInlineEditor bool ❌ false If true, the editor UI will be displayed directly in the parameter dialog.2 ✔
showEditButton bool ❌ true If true, a button to open the editor dialog will appear next to the line edit. ✔
showArithmeticEditor bool ❌ false If true, an option to show the arithmetic editor will be added to the parameter context menu. ✔
regexSettings obj ❌ ➖ An object of settings applicable when editor is regex. ✔
sqlSettings obj ❌ ➖ An object of settings applicable when editor is sql. ✔
urlSettings obj ❌ ➖ An object of settings applicable when editor is url. ✔
webSocketSettings obj ❌ ➖ An object of settings applicable when editor is webSocket. ✔1
xQuerySettings obj ❌ ➖ An object of settings applicable when editor is xquery. ✔
runnable bool ❌ false Internal only: If true, the parameter value is a valid executable script. ❌

Editor Syntaxes

  • plaintext
  • gquery
  • html
  • json
  • java
  • javascript
  • pce
  • python
  • raster
  • regex
  • rstats
  • sql
  • tcl
  • websocket
  • xml
  • xquery
  • url

regexSettings

Key Type Required Default Description UPM/TD
contains bool ❌ false Specifies whether the regex should match strings that contain the regex. If false, regex will only look for exact matches. ❌
caseSensitive bool/parameter3 ❌ false If true, regex will be evaluated as case-sensitive. ❌
testString str ❌ ➖ The name of another parameter to save test strings from the editor dialog to, allowing them to be preserved between dialog sessions. ✔

Deprecated

Key Type Required Default Description
useRegex obj ❌ ➖ A deprecated dynamic property. Should only be set on parameters migrated from certain deprecated GUI types.

sqlSettings

Key Type Required Default Description UPM/TD
mode enum:
sql, where
❌ sql Specifies whether the parameter value is a WHERE clause or full SQL statement. If sql, drag and drop produces SELECT statements by default. ✔
format str ❌4 ➖ Format shortname. ✔
dataset str ❌5 ➖ A specific DB connection/file to read table schema from.4 ✔

Deprecated

Key Type Required Default Description
connectionParams obj ❌ ➖ An object containing reader parameter values for the specified format.
startTableExpanded str ❌ ➖ A table name to expand by default when the editor dialog is opened.

urlSettings

Key Type Required Default Description UPM/TD
validSchemes arr(str) ❌ ➖ A list of valid url schemes. ✔

webSocketSettings

Key Type Required Default Description UPM/TD
webSocketOpen bool ❌ false Enables accordion menu options for websocket open preambles. ❌
webSocketSend bool ❌ false Enables accordion menu options for websocket send preambles. ❌

xQuerySettings

Key Type Required Default Description UPM/TD
getFunctions bool ❌ false Enables accordion menu options for read-only (get, list, contains) functions. ✔
processFunctions bool ❌ false Enables accordion menu options for process functions. ✔
setFunctions bool ❌ false Enables accordion menu options for write-only (set, append) functions. ✔
geometryFunctions bool ❌ false Enables accordion menu options for geometry related functions. ✔
sampleGeneration bool ❌ false If true, a button to generate an XML template will be added to the editor dialog. ✔
noBraces bool ❌ false Specifies whether enabled functions will be wrapped in braces or not. ❌
json bool ❌ false If true, enabled xml functions are replaced with json equivalents. ✔

Example

{
  "name": "sometext",
  "type": "text",
  "valueType": "string",
  "prompt": "New Attribute Name"
}

Parameter References

When a property supports parameter references, its value can be either a constant value, or a reference to another parameter in the form of an object containing the key "parameter" with the value being the name of the referenced parameter.

Example

Constant Value:

{
  "exampleOption": "stringValue"
}

Parameter Reference:

{
  "exampleOption": { "parameter" : "MY_PARAM" }
}

  1. websocket option available in Transformer Designer only. 

  2. Incompatible with gquery and regex editor types. 

  3. Referenced parameter must have a value of either "yes" or "no" (case-insensitive) 

  4. Required when dataset and/or startTableExpanded is specified. 

  5. Required when connectionParams and/or startTableExpanded is specified.