Syclo Data Markup Language

When synchronizing data between the mobile application and the back end system, it is necessary to have access to the mobile application’s data values. This access is provided in Agentry using the Syclo Data Markup Language, or SDML. The SDML is a markup language consisting of tags that provide access to the data values of the mobile application. Additionally, the SDML includes a full set of functions, or function tags, that can be used to perform logical operations in relation to this values or to drive the overall logic the Agentry Server will execute against the back end system.

The SDML tags used during synchronization are a part of the text within the scripts for step definitions defined for SQL Database, HTTP-XML, and File system connection types. Also, the synchronization components of data tables and complex tables for each of these system connection types can contain SDML. In addition to SQL Step definitions, other .sql script files run by the Server may also contain SDML tags. Steps defined for Java Virtual Machine system connections also include the ability to access SDML tags, but these tags may not be contained directly in the source code of the Java Steplet files used by these steps.

The Agentry Server will pre-process the script files of steps containing SDML markup. This processing is referred to as tag expansion. Each tag within the script is expanded, with the value it represents replacing the tag at the exact position of that tag within the file. Function tags are expanded with the results of their expansion being placed in the exact position of the function call within the file. Once the tag expansion has completed, the resulting text is submitted to the back end system for processing.

The two categories of tags within the SDML are data tags and function tags. Data tags represent data values available to the script file based on when it is executed. This information must be known when writing the script in which the SDML will be contained. For step definitions the values in scope are dictated by the step usage definition running them. For .sql scripts run by the server, but not a part of the step definition, the values in scope will vary depending on how that script is used. Certain values are globally available, such as the user ID as entered by the user to log into the Agentry Client.

Function tags are globally available, with certain exceptions. Function tags provide the logical, mathematical, string manipulation, and other similar functionality to the SDML. Function tags can take values passed in as arguments, parameters, or expressions. These values are processed by the function during tag expansion, with the resulting value of the function call being placed within the script.

Following is a basic example of a simple SQL statement containing SDML data tags:
SELECT	
	A.FIELD1,
	B.FIELD2,
	C.FIELD3,
FROM	
	TABLEA A,
	TABLEB B,
	TABLEC C
WHERE
	A.NAME = ‘<<user.agentryID>>’	AND
	A.ACCTNUM = ‘<<object.acctnum>>’	AND 
	B.ACCTNUM = A.ACCTNUM 	AND 
	C.ACCTNUM = B.ACCTNUM

In this example, the value <<user.agentryID>> is replaced with the user ID as entered when the user logged into the Agentry Client. The data tag<<object.acctnum>> will be replaced with the value of the acctnum property of the object currently being processed.