Skip to content
Ilya edited this page Nov 29, 2016 · 3 revisions

Macros sets for TBSM

Overview

Create the model from GUI TBSM very uncomfortably, special when need do many "copy" operations (GUI not support such operations).

This is project with m4 macros for create TBSM model. You are write config file by m4 syntax. m4 is parse this file and generate radshell. This radshell can be exports to TBSM software and creates service model for future used.

Version is alfa, but working. Can be running by any *nix platform with m4 packet. Windows can be used too, but m4 for Win install needs.

Contents

Use

  1. Create the file model-name.mc with definitions your model into dir RAD/radshell/
  2. Launch m4 by commands: m4 ../m4/radshell.m4 model-name.mc > model-name.radsh
  3. Export radsh to TBSM: cat model-name.radsh | rad_radshell

Syntax

Now support next commands:

Set template name and attribs

TEMPL_NAME(<template_name>)

where:

  • template_name - Name exists template for used into next command
TEMPL_ATTR(<rule_name>,<name_field-1>,<name_field-2>,...)

where:

  • rule_name - rule name in to template
  • name_field-1(2...) - field names from template It is macros will be set names attributes for fill in to service

Create service

SERVICE(<service_name>,<Display>,<Description>)

where:

  • service_name - instance name of the creating service
  • Display - display name field
  • Description - description name field

Set fields values for service

VALUES([<service_name>,][{0|1|2|3|...}], Value-1, Value-2, ...)

where:

  • service_name - name of service for setting
  • 0|1|2|3|... - number rules set
  • Value-1(2...) - value of field

to be continue...

More details see sampleService.mc file from distrib