Skip to content

WebFramework markup

Semyon Gritsenko edited this page Nov 9, 2024 · 7 revisions

Parameters:

  • route - URL
  • loadType - One of value(initialization, dynamic). initialization value works with pages without saving user data, dynamic works with all pages, but it created for each user.
  • initParameters - JSON structured data. Used in init method to initialize Executor before running.

All executors must be described as follows:

{ 
  "ExecutorName": { 
    "route": "urlRoute", 
    "loadType": "initialization", 
    "initParameters": { 
      "key": "value", 
      "anotherKey": "anotherValue" 
    } 
  } 
}

Example:

{
  "Authorization": {
    "route": "authorization",
    "loadType": "initialization"
  },
  "DynamicForm": {
    "route": "dynamic/form",
    "loadType": "dynamic"
    "initParameters": {
      "firstType": "authorization",
      "secondType": "registration"
    }
  }
}

Webframework also supports route parameters. You can describe route as follow "route": "init/{string:variableName}". Now your executor manage all routes with /init/any_text. You can access to any_text through request variable in doGet, doPost, doDelete, doPut, doPatch.

Clone this wiki locally