Quick Reference: Local Properties and Global Properties
Local properties and global properties in SenseTalk let you set or change behaviors system-wide. For instance, you can set the numerical format for time or date values, and you can change the way SenseTalk scripts interact with files and file system objects. There are also a few special properties that affect the way an object is treated by SenseTalk.
Local Properties
SenseTalk local properties govern behavior locally within a handler. If they have not yet been set to a specific value within the current handler, they will have a default value as indicated for each property. When the value of one of these properties is set in a handler, it has that value only within the local handler. Handlers that called the local handler, or which are called by it, are not affected.
Determines whether text comparisons that don’t explicitly specify considering case or ignoring case are case sensitive or not; defaults to False. |
|
Controls which century two-digit years are assumed to belong to; defaults to the value of the defaultCenturyCutoff global property. |
|
Defines the delimiter used for text items; defaults to the value of the defaultItemDelimiter global property. |
|
the lineDelimiter | Defines the strings that can separate line items when evaluating a line chunk expression; defaults to the value of the defaultLineDelimiter global property. |
Determines whether a list inserted into another is nested in the other list or is inserted item by item; defaults to the value of the defaultListInsertionMode global property. |
|
Defines the format for displaying numbers; defaults to the value of the defaultNumberFormat global property. |
|
Defines the characters that separate words in text; defaults to the value of the defaultWordDelimiter global property. |
|
Controls how quotes are treated in word chunks; defaults to the value of the defaultWordQuotes global property. |
Global Properties
The following SenseTalk properties are global in scope. They can be changed by any handler at any time, and after they are changed their new value will be in effect from that point forward in all handlers.
Note: Most global properties have a standard initial setting at the start of script execution, as indicated in the discussion of that property. These standard values can be overridden by settings in the user defaults database for the host application, using the property name prefixed by ST. For example, the shellCommand property would be set using the name STShellCommand in the user defaults.
Controls the maximum size of internally generated text representations of values. |
|
the autoSaveDatabaseUpdates | Determines whether updates to databases are saved automatically. |
the backScripts | Special list of objects that receives messages after the target object as part of the message passing path. |
the booleanComparison | Controls how Boolean matches are made. |
Determines whether breakpoint commands are honored or ignored. |
|
the characterFiller | Specifies the behavior when a container is extended by storing into a character position that lies beyond the end of the container's contents. |
Set to 12 hour or 24 hour to control time formats. |
|
The format for displaying colors. |
|
the defaultCenturyCutoff | Controls which century two-digit years are assumed to belong to if the centuryCutoff local property is not set. |
the defaultDataFormat | Controls how values are represented when data is converted to text. |
Defines the default delimiter for text items. |
|
the defaultLineDelimiter | Defines the strings that can separate line items when evaluating a line chunk expression. |
the defaultListInsertionMode | Controls how items behave when you add a list of items to another list. |
Specifies the default format for displaying numbers. | |
the defaultQuoteFormat | Specifies how values in the listFormat and the propertyListFormat global properties are quoted when converted to text. |
Controls the encoding used when reading and writing text strings in files. |
|
Specifies the default delimiter characters for words. |
|
Defines the default quote characters for word chunks. |
|
Controls how duplicate keys in property lists are handled. |
|
The value of the end constant, returned by iterators when they have no more values to return. |
|
Controls how variables are evaluated in do, send, value() or merge() expressions (whether as local, global, or universal variables); defaults to Local. |
|
Contains information about an exception thrown in the context of the latest try block; otherwise, is empty. |
|
Returns the current working folder in the file system. |
|
Determines whether folder names are returned with a slash at the end. |
|
Special list of objects that receives messages before the target object as part of the message passing path. |
|
the lineFiller | Provides the line delimiter to use when a container is extended by storing into a line number position that lies beyond the end of the container's contents. |
Controls formatting of displayed lists. |
|
Determines whether pattern searches can overlap or be nested. | |
The defined colors accessible by name. |
|
the objectContainsItemDefinition | Controls how operators or functions access keys and values within a property list. |
Toggles between line mode and text mode (default) for pattern searches. | |
Controls the maximum time taken on any single pattern search. | |
Contains a property list with the definitions of all predefined variables. |
|
Controls formatting of displayed property lists. | |
Specifies the maximum time (in seconds) that a read or open socket command will take before timing out. |
|
Contains a list of the most recent the result values. |
|
Controls the maximum number of items in the resultHistory. |
|
Sets the command line shell to be used by the shell() function. |
|
Determines whether accessing the contents of a nonexistent file throws an exception or returns an empty value. |
|
When set to True, accessing an undefined property of an object throws an exception rather than returning an empty value. |
|
When set to True, accessing the value of a local variable that has not been declared or stored into throws an exception instead of returning the variable’s name. |
|
the suiteVariables | Contains a property list of user-defined suite-wide variables. |
Determines whether an exception is thrown when an operation that sets the result returns an error. |
|
A property list defining all of the available date/time formats. |
|
A list of formats used in recognizing date and time values. |
|
the treeFormat | Defines the way XML trees are formatted. |
the treeInputFormat | Specifies whether text nodes are joined when a change is made to a tree. |
Controls the access permissions for newly created files. |
|
Determines whether accessed URLs can be cached for later reuse; the default, True, allows caching. |
|
Specifies the lowest URL status value that is treated as an error. |
|
Specifies the maximum time (in seconds) that a URL request will take before timing out. |
|
|
|
the wordFiller | Specifies the behavior when a container is extended by storing into a word position that lies beyond the end of the container's contents. |
Special Properties
There are several object properties with special meaning to SenseTalk. Some of these properties are “hidden” in the sense that they are not listed by the keys or values functions and will not appear in the default text representation of an object, but they can be directly accessed as properties of an object.
These special properties affect the way an object is treated by SenseTalk. These properties show up as ordinary properties of your object but have special meaning.
asText | The asText property, if set for an object, is used as the text representation of the object if it does not handle an “asText” function message. |
asTextFormat | If an object has neither an “asText” function handler nor an asText property, SenseTalk checks for an asTextFormat property. If this property is set for an object, its value is used as a format string to generate the text representation of the object using the merge function. |
objectType | Setting an object’s objectType property identifies it as a particular type of object for the is a operator. |
script properties | See Script Properties for a complete description. |