setInterval
, setTimeout
or setImmediate
. For example, a route script employing an HTTP callout might look like the following.ECMAScript 5/5.1
compliant. You can also use many ES2015
features and some decorators. The following babel plugins are enabled for that reason.decorators
are built-in and can be imported using the decorators-{decoratorName}
convention like in this example: autobind, decorate, deprecate, enumerable, extendDescriptor, lazyInitialize, nonconfigurable, nonenumerable, override, readonly
require
and defined using module.exports
. Imports and exports are also supported.c_utils
, defined as:trace
property or the getCurrentStackTrace
global function. A stack trace is also provided with calls to the logger
or console
modules.console
, consts
, org
and script
auto-globals are always guaranteed to be available, though console printing only works on the development servers.bool
(Boolean)bool
(Boolean)level
(Number)bool
(Boolean)identifier
(String) The locale identifier, which consists of a 2 or 3 letter language tag optionally followed by a region separated by _
. For example, en
, en_US
, en_UK
, etc.bool
(Boolean)bool
(Boolean)level
(Number)"modified"
may also be used to return an object containing just the modified properties. Otherwise, simply the _id
of the updated document is returned.bool
(Boolean)identifier
(String) The locale identifier, which consists of a 2 or 3 letter language tag optionally followed by a region separated by _
. For example, en
, en_US
, en_UK
, etc.kInvalidArgument
will be returned with the reason "Pushed document has an _id and/or updated document is missing an _id."bool
(Boolean)pathPrefix()
option. For example, org.objects.c_object.updateOne({_id: _id}).pathDelete("c_docs.5a2c44f836412438e4c372c2.c_array.bar");
removes "bar" from the c_array string array in the c_docs document array.path
(String) Optional. Overrides pathPrefix()
.c_parent.updateOne({_id: parentId}, {$push: [{c_name: 'new child'}]}).pathPrefix('c_children').execute()
creates a new c_child instance through the c_parent object's c_children list property.path
(String)path
(String) Optional. Overrides pathPrefix()
.body
(Object) The value(s) to push.path
(String) Optional. Overrides pathPrefix()
.body
(Object) The value(s) to update.bool
(Boolean)bool
(Boolean)level
(Number)bool
(Boolean)