This article is an overview of the'AstroZero' platform JavaScript standard library.
For more information on the features of the'AstroZero' JavaScript engine, please read:
AstroZero JavaScript Engine Introduction
Before reading each specific standard library usage, read the following topic to give you an idea of how to invoke the AstroZero
script:
How does use Action to invoke scripts?
The context
library provides basic information for obtaining the execution context of the system, such as
getUserName
, getUserId
, getLocale
getToken
getTimeZone
, tenant time zone getOrganizationTimeZone
-......sys
provides the ability to invoke some common operations of the system engine, such as:
invokeSimpleBo
.inovkeFlow
sendEvent
, sendDelayEvent
sendEmail
sendRest
-......date
is a complex library. Its complexity lies not in the use of interfaces, but in the use of the AstroZero
time zone.
For details, see Time Processing.
error
defines the error handling mechanism of the AstroZero
platform.
runtime
provides some runtime-related functions, such as:
sleep
stack
Supports basic http
client functions.
Uploading files using multipart/form-data
is supported in the following scenarios:
Example of uploading a file to the
Supports common encryption and decryption functions, such as:
AES CBC
, AES GCM
RSA
MD5
, SHA1
, SHA256
-......For details, see crypto Usage Example.
##Database
The object
encapsulates the CRUD
operation of the object engine. For details, see the following:
object Usage Example
sql
encapsulates SQL statements. For details, see:
sql Usage Example
For details about the syntax of sql
, see sql Syntax.
Other databases involved in database operations:
How to do unit testing, please refer to the document: