Skip to content

Instantly share code, notes, and snippets.

@kevinswiber
Last active October 12, 2016 17:19
Show Gist options
  • Save kevinswiber/31bf59a9f77db2cbbb27 to your computer and use it in GitHub Desktop.
Save kevinswiber/31bf59a9f77db2cbbb27 to your computer and use it in GitHub Desktop.
Zetta Metadata to ALPS Mapping
{
"alps": {
"version": "1.0",
"descriptor": [
{
"id": "led-type",
"name": "led",
"type": "semantic",
"descriptor": [
{
"id": "led-id-property",
"name": "id",
"type": "semantic"
},
{
"id": "led-name-property",
"name": "name",
"type": "semantic"
},
{
"id": "led-type-property",
"name": "type",
"type": "semantic"
},
{
"id": "led-state-property",
"name": "state",
"type": "semantic"
},
{
"id": "led-state-stream",
"name": "state",
"type": "safe"
},
{
"id": "led-turn-on-transition",
"name": "turn-on",
"type": "unsafe",
"rt": "led-type"
},
{
"id": "led-turn-off-transition",
"name": "turn-off",
"type": "unsafe",
"rt": "led-type"
}
]
},
{
"id": "screen-type",
"name": "screen",
"descriptor": [
{
"id": "screen-message-property",
"name": "message",
"type": "semantic"
},
{
"id": "screen-id-property",
"name": "id",
"type": "semantic"
},
{
"id": "screen-name-property",
"name": "name",
"type": "semantic"
},
{
"id": "screen-type-property",
"name": "type",
"type": "semantic"
},
{
"id": "screen-state-property",
"name": "state",
"type": "semantic"
},
{
"id": "screen-state-stream",
"name": "state",
"type": "safe"
},
{
"id": "screen-message-stream",
"name": "message",
"type": "safe"
},
{
"id": "screen-change-transition",
"name": "change",
"type": "unsafe",
"rt": "screen-type",
"descriptor": [
{
"id": "screen-change-transition-message-field",
"name": "message",
"type": "semantic",
"href": "#html-text-input"
}
]
}
]
},
{
"id": "html-text-input",
"type": "semantic",
"ext": {
"id": "html-text-input-ext",
"href": "http://www.w3.org/TR/html-markup/input.text.html#input.text.attrs.value"
}
}
]
}
}
[
{
"type": "led",
"properties": [
"id",
"name",
"type",
"state"
],
"streams": [
"state"
],
"transitions": [
{
"name": "turn-on"
},
{
"name": "turn-off"
}
]
},
{
"type": "screen",
"properties": [
"message",
"id",
"name",
"type",
"state"
],
"streams": [
"state",
"message"
],
"transitions": [
{
"name": "change",
"fields": [
{
"name": "message",
"type": "text"
}
]
}
]
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment