Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents
minLevel3
outlinetrue
stylenone

Introduction

The FacetScript Language is one of the Atomic Domain Languages (ADLs).  It is a low-level high-performance scripting language natively executed by the TQLEngine A-Stack without any additional compilation besides initial parsing.

List of Commands

FacetScript language, as well as other domain-specific languages used in Atomiton TQLEngine A-Stack stack, is not bound to a specific syntax. Any syntax capable of expressing structure can be used to represent language constructs. Out of the box, both XML and JSON can be used.

Since JSON does not have a concept of attributes, it follows that the compiler does not make any distinction between XML elements and attributes either. That is, any XML attribute can be given as an element and any element with text value can be given as an attribute. JSON also does not allow multiple entries of the same name so these must be expressed as JSON arrays.

Recommended syntax to use is XML.


Command NameDescriptionExample
ProcessKeyword

<ProcessKeyword key=“…” value=”…”> FS command. This new command is intended to make it easier to work with macros which are composed/determined at run time rather than hardcoded in your code. As the name suggests,

<ProcessKeyword key=”MyMacro”>

  <Value>..MyMacroArgs..</Value>

</ProcessKeyword>


Will be evaluated as


<MyMacro>

  ..MyMacroArgs..

</MyMacro>

i.e. it allows you compose a macro call (or any other FS instruction for that matter) on a fly passing the tag name as a parameter

  • <ProcessWith namespace=”…”> FS command is intended to make it easier to work with qualified macro names. Recall that all macros share the same global namespace and if you have macros with the same name defined at different points/facets of your pipeline then the only way is to use qualified names. Thus


<ProcessWith namespace=”MyNamespace”>

  <MyMacro>

    ..MyMacroArgs..

  </MyMacro>

</ProcessWith>


Will effectively execute as


  < MyNamespace.MyMacro>

    ..MyMacroArgs..

  </MyNamespace.MyMacro>


i.e. it will assign given namespace to the enclosed tags.

  • Both ProcessKeyword and UnknownKeyword instructions now also accept “namespace” and “keyword” parameters where key will be computed as namespace.keyword with proper delimiters. Note that “key” parameter if given takes precedence.

<ProcessKeyword key=”MyMacro”>

  <Value>..MyMacroArgs..</Value>

</ProcessKeyword>


Will be evaluated as


<MyMacro>

  ..MyMacroArgs..

</MyMacro>