The rest-python server handles properties differently based on where one is at in the system. This document mean to focus on the CF::PropertySet lists that accompany Devices and Components. For all others, see the associated documentation. Care was taken to keep the structures similar even if not all fields could be inferred.

General structure

{
    "id":       "propertyId",
    "name":     "propertyName",
    "kinds":    [],          /* configure, allocation, execparam, event, message */
    "scaType":  "simple",    /* simple, struct, simpleseq, structseq */
    "mode":     "readwrite", /* readonly, writeonly, readwrite */
    "value":    "",          /* Depends on scaType */
}

Representations of “value”

SIMPLE

{
    /* scaType: simple */
    "type":  "string",      /* or long, double, ulong, etc. */
    "value": "someValue"    /* representation matches type */
}

SIMPLESEQ

{
    /* scaType: simpleSeq */
    "type":  "string",      /* or long, double, ulong, etc. */
    value: [
        "value1",
        "value2"
        /* etc. each representation matching the type */
    ],
}

STRUCT

{
    /* scaType: struct */
    "value": [ /* Each field as a simple */ ]
}

STRUCTSEQ

{
    /* scaType: structSeq */
    "value": [ /* Each as a struct */ ],
}

Example

The following is an example of a configure event struct property where one of the fields is an enumeration and the other is a string. The field IDs are: struct_event_prop::field1 and struct_event_prop::field2.

{
    "id": "struct_event_prop"
    "name": "struct_event_prop", 
    "mode": "readwrite", 
    "scaType": "struct", 
    "kinds": ["configure", "event"], 
    "value": [
        {
            "enumerations": {"SOMETHING_ELSE": 1, "SOMETHING": 0}, 
            "kinds": ["configure", "event"], 
            "name": "field2", 
            "value": 0, 
            "scaType": "simple", 
            "mode": "readwrite", 
            "type": "ulong", 
            "id": "struct_event_prop::field2"
        }, 
        {
            "kinds": ["configure", "event"], 
            "name": "field1",
            "value": "test_value", 
            "scaType": "simple", 
            "mode": "readwrite", 
            "type": "string", 
            "id": "struct_event_prop::field1"
        }
    ], 
},