Defines the builder to configure a datastream of IoT datamodel. With this builder you can configure a datastream
addQrating(qrating)
Set the qrating attribute. Use {Qrating} utility for create this object
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| qrating |
Object |
❌ |
|
Retorna
Tip
build()
Build a Datastream json object
Retorna
Tip
Tipo: Object
Datastream json object
Ejemplos
ogapi.DatastreamsBuilder().build()
withAccess(access)
Set the access object. Possible values: [READ, WRITE], [READ], [WRITE], []
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| access |
Array |
❌ |
|
Retorna
Tip
withDescription(description)
Set the description attribute
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| description |
string |
❌ |
|
Retorna
Tip
withId(id)
Set the id attribute
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| id |
string |
❌ |
required field |
Retorna
Tip
withName(name)
Set the name attribute
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| name |
string |
❌ |
required field |
Retorna
Tip
withPeriod(period)
Set the period attribute. Possible values: PULSE, CUMULATIVE, INSTANT
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| period |
string |
❌ |
required field |
Retorna
Tip
withSchema(schema)
Set the schema object attribute.
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| schema |
Object |
❌ |
|
Retorna
Tip
withStorage(period, total)
Set the storage object.
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| period |
string |
❌ |
|
| total |
number |
❌ |
|
Retorna
Tip
Set the tags attribute.
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| tags |
Array |
❌ |
|
Retorna
Tip
withUnit(type, label, symbol)
Set the unit object attribute
Parámetros
| Nombre |
Tipo |
Opcional |
Descripción |
| type |
string |
❌ |
required field |
| label |
string |
❌ |
required field |
| symbol |
string |
❌ |
required field |
Retorna
Tip