Versions Compared

Key

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

...

Deleted: the model instance is removed. This is done by a DeleteAll query (need conformation).

In ThingModels and AppModels, model lifecycle is closely linked to the workflow lifecycle (DataModels do not have Actions or workflows).

...

Code Block
languagexml
titleModel Instantiation
linenumberstrue
<Create format="version,current"> <!-- This will create -->
   <TempSensor>
            <peripheral>serial</peripheral>
            <baudrate>115200</baudrate>
            <interfacePort>/dev/cu.usbserial-AL01C0ME</interfacePort>
            <interface>serial</interface>
            <format>ascii</format>
            <operation>receive</operation>
            <uniqueId>76522</uniqueId>
            <payload>$Null()</payload>
            <tempValue>$Null()</tempValue>
    </TempSensor>
</Save>

 

Models are defined by using ThingModel, AppModel or DataModel types.

Code Block
languagexml
titleThingModel
linenumberstrue
<ThingModel Name="TempSensor" combines="TempFacetSerial">
       <Sid Name="sensorId" />
</ThingModel>

 

 

Once Model For update and delete, see common CRUD operations on models.

Once definitions are deployed in the engine, engine creates the meta data for the models maintains models, instances and application blueprints in the storage defined in the deployment script.

...