Schemas for wifi and user settings utilities
This commit is contained in:
parent
cad76e1d2a
commit
64a87feba6
3 changed files with 41 additions and 3 deletions
|
@ -3,8 +3,9 @@ WidgetType
|
|||
horizontal´³refµ„³Sizing„„´³named³vertical´³refµ„³Sizing„„„„„³SortKey´³orµµ±double´³atom³Double„„µ±string´³atom³String„„„„³LeafType´³orµµ±blank´³lit³blank„„µ±text´³lit³text„„µ±slider´³lit³slider„„µ±image´³lit³image„„µ±icon´³lit³icon„„„„³NodeType´³orµµ±column´³lit³column„„µ±row´³lit³row„„„„³WidgetId³any³ Attribute´³rec´³lit³ attribute„´³tupleµ´³named³id´³refµ„³WidgetId„„´³named³key´³atom³Symbol„„´³named³value³any„„„„³
|
||||
WidgetType´³orµµ±NodeType´³refµ„³NodeType„„µ±LeafType´³refµ„³LeafType„„„„³WindowTitle´³rec´³lit³window-title„´³tupleµ´³named³title´³atom³String„„„„„³WidgetInstance´³rec´³lit³widget-instance„´³tupleµ´³named³id´³refµ„³WidgetId„„´³named³instance´³embedded³any„„„„„³WindowCloseable´³rec´³lit³window-closeable„´³tupleµ„„„„³embeddedType€„„µ³mime„´³schema·³version‘³definitions·³Value´³rec´³lit³mime„´³tupleµ´³named³type´³atom³Symbol„„´³named³data´³atom³
|
||||
ByteString„„„„„„³embeddedType€„„µ³time„´³schema·³version‘³definitions·³Stamp´³rec´³lit³rfc3339„´³tupleµ´³named³value´³atom³String„„„„„„³embeddedType€„„µ³audio„´³schema·³version‘³definitions·³Sink´³orµµ±speaker´³lit³speaker„„µ±headset´³lit³headset„„µ±earpiece´³lit³earpiece„„„„³Source´³orµµ±speakerphone´³lit³speakerphone„„µ±headset´³lit³headset„„µ±handset´³lit³handset„„„„³SinkMapping´³rec´³lit³alsa-sink-mapping„´³tupleµ´³named³abstract´³refµ„³Sink„„´³named³concrete´³atom³String„„„„„³HeadsetSpeakerPresent´³rec´³lit³headset-speaker-present„´³tupleµ„„„³HeadsetMicrophonePresent´³rec´³lit³headset-microphone-present„´³tupleµ„„„„³embeddedType€„„µ³hayes„´³schema·³version‘³definitions·³Result´³rec´³lit³result„´³tupleµ´³named³text´³atom³String„„´³named³tag´³refµ„³MaybeString„„´³named³fields´³refµ„³MaybeStrings„„„„„³MaybeString´³orµµ±present´³atom³String„„µ±absent´³lit€„„„„³MaybeStrings´³orµµ±present´³seqof´³atom³String„„„µ±absent´³lit€„„„„³ModemPresent´³rec´³lit³modem„´³tupleµ´³lit³hayes„´³named³
|
||||
devicePath´³atom³String„„´³named³ dataspace´³embedded´³refµ„³InternalProtocol„„„„„„³
CommandResult´³rec´³lit³command-result„´³tupleµ´³named³commandText´³atom³String„„´³named³results´³seqof´³refµ„³Result„„„´³named³finalResult´³atom³String„„„„„³ExecuteCommand´³rec´³lit³execute-command„´³tupleµ´³named³commandText´³atom³String„„´³named³replyTo´³refµ„³CommandContinuation„„„„„³InternalProtocol³any³CommandContinuation´³orµµ±replyWanted´³embedded´³refµ„³
CommandResult„„„µ±
fireAndForget´³lit€„„„„³UnsolicitedResultCode´³rec´³lit³unsolicited„´³tupleµ´³named³result´³refµ„³Result„„„„„„³embeddedType€„„µ³network„´³schema·³version‘³definitions·³Route´³rec´³lit³route„´³tupleµ´³named³
addressFamily´³refµ„³
AddressFamily„„´³named³destination´³refµ„³RouteDestination„„´³named³priority´³atom³
SignedInteger„„´³named³
typeOfService´³atom³
SignedInteger„„´³named³
interfaceName´³refµ„³RouteInterface„„´³named³gateway´³refµ„³Gateway„„„„„³Gateway´³orµµ±addr´³atom³String„„µ±none´³lit€„„„„³ Interface´³rec´³lit³ interface„´³tupleµ´³named³name´³atom³String„„´³named³index´³atom³
SignedInteger„„´³named³type´³refµ„³
InterfaceType„„´³named³administrativeState´³refµ„³AdministrativeState„„´³named³operationalState´³refµ„³OperationalState„„´³named³carrier´³refµ„³CarrierState„„´³named³linkAddr´³atom³String„„„„„³CarrierState´³orµµ± noCarrier´³lit³
|
||||
no-carrier„„µ±carrier´³lit³carrier„„„„³DefaultRoute´³rec´³lit³
default-route„´³tupleµ´³named³
addressFamily´³refµ„³
AddressFamily„„„„„³
AddressFamily´³orµµ±ipv4´³lit³ipv4„„µ±ipv6´³lit³ipv6„„µ±other´³atom³
SignedInteger„„„„³
InterfaceType´³orµµ±loopback´³lit³loopback„„µ±normal´³lit³normal„„µ±wireless´³lit³wireless„„„„³RouteInterface´³orµµ±name´³atom³String„„µ±none´³lit€„„„„³OperationalState´³orµµ±unknown´³lit³unknown„„µ±down´³lit³down„„µ±lowerLayerDown´³lit³lower-layer-down„„µ±testing´³lit³testing„„µ±dormant´³lit³dormant„„µ±up´³lit³up„„„„³RouteDestination´³orµµ±default´³lit³default„„µ±prefix´³rec´³lit³prefix„´³tupleµ´³named³net´³atom³String„„´³named³bits´³atom³
SignedInteger„„„„„„„„³AdministrativeState´³orµµ±unknown´³lit³unknown„„µ±down´³lit³down„„µ±up´³lit³up„„„„„³embeddedType€„„µ³ telephony„´³schema·³version‘³definitions·³CallId´³atom³
SignedInteger„³Address´³rec´³lit³address„´³tupleµ´³named³
|
||||
devicePath´³atom³String„„´³named³ dataspace´³embedded´³refµ„³InternalProtocol„„„„„„³
CommandResult´³rec´³lit³command-result„´³tupleµ´³named³commandText´³atom³String„„´³named³results´³seqof´³refµ„³Result„„„´³named³finalResult´³atom³String„„„„„³ExecuteCommand´³rec´³lit³execute-command„´³tupleµ´³named³commandText´³atom³String„„´³named³replyTo´³refµ„³CommandContinuation„„„„„³InternalProtocol³any³CommandContinuation´³orµµ±replyWanted´³embedded´³refµ„³
CommandResult„„„µ±
fireAndForget´³lit€„„„„³UnsolicitedResultCode´³rec´³lit³unsolicited„´³tupleµ´³named³result´³refµ„³Result„„„„„„³embeddedType€„„µ³network„´³schema·³version‘³definitions·³Route´³rec´³lit³route„´³tupleµ´³named³
addressFamily´³refµ„³
AddressFamily„„´³named³destination´³refµ„³RouteDestination„„´³named³priority´³atom³
SignedInteger„„´³named³
typeOfService´³atom³
SignedInteger„„´³named³
interfaceName´³refµ„³RouteInterface„„´³named³gateway´³refµ„³Gateway„„„„„³Gateway´³orµµ±addr´³atom³String„„µ±none´³lit€„„„„³Hotspot´³rec´³lit³hotspot„´³tupleµ´³named³
interfaceName´³atom³String„„´³named³ssid´³atom³String„„´³named³authentication´³refµ„³WifiAuthentication„„„„„³ Interface´³rec´³lit³ interface„´³tupleµ´³named³name´³atom³String„„´³named³index´³atom³
SignedInteger„„´³named³type´³refµ„³
InterfaceType„„´³named³administrativeState´³refµ„³AdministrativeState„„´³named³operationalState´³refµ„³OperationalState„„´³named³carrier´³refµ„³CarrierState„„´³named³linkAddr´³atom³String„„„„„³CarrierState´³orµµ± noCarrier´³lit³
|
||||
no-carrier„„µ±carrier´³lit³carrier„„„„³DefaultRoute´³rec´³lit³
default-route„´³tupleµ´³named³
addressFamily´³refµ„³
AddressFamily„„„„„³HotspotState´³rec´³lit³
hotspot-state„´³tupleµ´³named³
interfaceName´³atom³String„„´³named³ssid´³atom³String„„´³named³stationCount´³atom³
SignedInteger„„„„„³
AddressFamily´³orµµ±ipv4´³lit³ipv4„„µ±ipv6´³lit³ipv6„„µ±other´³atom³
SignedInteger„„„„³
InterfaceType´³orµµ±loopback´³lit³loopback„„µ±normal´³lit³normal„„µ±wireless´³lit³wireless„„„„³
MobileDataApn´³rec´³lit³mobile-data-apn„´³tupleµ´³named³apn´³atom³String„„„„„³RouteInterface´³orµµ±name´³atom³String„„µ±none´³lit€„„„„³WifiAssociation´³rec´³lit³wifi-association„´³tupleµ´³named³
interfaceName´³atom³String„„´³named³ssid´³atom³String„„´³named³state´³refµ„³WifiAssociationState„„„„„³OperationalState´³orµµ±unknown´³lit³unknown„„µ±down´³lit³down„„µ±lowerLayerDown´³lit³lower-layer-down„„µ±testing´³lit³testing„„µ±dormant´³lit³dormant„„µ±up´³lit³up„„„„³RouteDestination´³orµµ±default´³lit³default„„µ±prefix´³rec´³lit³prefix„´³tupleµ´³named³net´³atom³String„„´³named³bits´³atom³
SignedInteger„„„„„„„„³SavedWifiNetwork´³rec´³lit³saved-wifi-network„´³tupleµ´³named³ssid´³atom³String„„´³named³authentication´³refµ„³WifiAuthentication„„´³named³priority´³atom³Double„„„„„³WifiAuthentication´³orµµ±open´³lit³open„„µ±psk´³rec´³lit³psk„´³tupleµ´³named³password´³atom³String„„„„„„µ±other³any„„„³AdministrativeState´³orµµ±unknown´³lit³unknown„„µ±down´³lit³down„„µ±up´³lit³up„„„„³SelectedWifiNetwork´³rec´³lit³selected-wifi-network„´³tupleµ´³named³
interfaceName´³atom³String„„´³named³ssid´³atom³String„„´³named³authentication´³refµ„³WifiAuthentication„„„„„³AvailableAccessPoint´³rec´³lit³available-ap„´³tupleµ´³named³
interfaceName´³atom³String„„´³named³ssid´³atom³String„„„„„³WifiAssociationState´³orµµ±
|
||||
inProgress´³lit³in-progress„„µ±ready´³lit³ready„„„„„³embeddedType€„„µ³ telephony„´³schema·³version‘³definitions·³CallId´³atom³
SignedInteger„³Address´³rec´³lit³address„´³tupleµ´³named³
|
||||
numberType´³refµ„³
|
||||
NumberType„„´³named³number´³atom³String„„„„„³CallType´³orµµ±voice´³lit³voice„„µ±data´³lit³data„„µ±fax´³lit³fax„„„„³ CallState´³orµµ±hold´³lit³hold„„µ±original´³lit³original„„µ±connect´³lit³connect„„µ±incoming´³lit³incoming„„µ±waiting´³lit³waiting„„µ±end´³lit³end„„µ±alerting´³lit³alerting„„„„³ PlaceCall´³rec´³lit³
|
||||
place-call„´³tupleµ´³named³
|
||||
|
@ -14,6 +15,6 @@ call-state
|
|||
AnswerCall´³rec´³lit³answer-call„´³tupleµ´³named³callId´³atom³
SignedInteger„„„„„³
|
||||
NumberType´³orµµ±unknown´³lit³unknown„„µ±
international´³lit³
international„„µ±national´³lit³national„„µ±gsm0338´³lit³gsm0338„„„„³PeerRinging´³rec´³lit³peer-ringing„´³tupleµ„„„³SmsDelivery´³rec´³lit³sms-delivery„´³tupleµ´³named³smsc´³refµ„³Address„„´³named³peer´³refµ„³Address„„´³named³ timestamp´³refµ³time„³Stamp„„´³named³body´³atom³String„„„„„³ModemPresent´³rec´³lit³modem„´³tupleµ´³named³type´³atom³Symbol„„´³named³
|
||||
devicePath´³atom³String„„´³named³ dataspace´³embedded³any„„„„„³PhoneRinging´³rec´³lit³
phone-ringing„´³tupleµ„„„³ReleaseCause´³orµµ±unassignedNumber´³lit³unassignedNumber„„µ±normal´³lit³normal„„µ±busy´³lit³busy„„µ±noUserResponding´³lit³noUserResponding„„µ±callRejected´³lit³callRejected„„µ±destinationOutOfOrder´³lit³destinationOutOfOrder„„µ±normalUnspecified´³lit³normalUnspecified„„µ±incompatibleDestination´³lit³incompatibleDestination„„„„³Speakerphone´³rec´³lit³speakerphone„´³tupleµ„„„³
CallDirection´³orµµ±mo´³lit³mo„„µ±mt´³lit³mt„„„„³CallIdSelector´³orµµ±specificCall´³atom³
SignedInteger„„µ±allCalls´³lit³all„„„„³CallInProgress´³rec´³lit³call-in-progress„´³tupleµ„„„³DisconnectCall´³rec´³lit³disconnect-call„´³tupleµ´³named³callId´³refµ„³CallIdSelector„„´³named³cause´³refµ„³ReleaseCause„„„„„³SmsTransmission´³rec´³lit³sms-transmission„´³tupleµ´³named³smsc´³refµ„³Address„„´³named³peer´³refµ„³Address„„´³named³body´³atom³String„„´³named³continuation´³embedded´³lit³ok„„„„„„„³embeddedType€„„µ³soundEffects„´³schema·³version‘³definitions·³
|
||||
AlertSound´³rec´³lit³alert-sound„´³tupleµ´³named³data´³refµ³mime„³Value„„„„„³ContinuousSound´³rec´³lit³continuous-sound„´³tupleµ´³named³data´³refµ³mime„³Value„„„„„³AlertSoundPlaying´³rec´³lit³alert-sound-playing„´³tupleµ„„„³ContinuousSoundPlaying´³rec´³lit³continuous-sound-playing„´³tupleµ„„„„³embeddedType€„„µ³usersAndGroups„´³schema·³version‘³definitions·³Spec´³orµµ±userAccount´³lit³user„„µ±
systemAccount´³lit³system„„µ±id´³atom³
SignedInteger„„„„³Group´³rec´³lit³grent„´³tupleµ´³dict·³gid´³named³gid´³atom³
SignedInteger„„³name´³named³name´³atom³String„„„„„„„³Account´³rec´³lit³pwent„´³tupleµ´³dict·³gid´³named³gid´³atom³
SignedInteger„„³uid´³named³uid´³atom³
SignedInteger„„³home´³named³home´³atom³String„„³info´³named³info´³atom³String„„³name´³named³name´³atom³String„„³shell´³named³shell´³atom³String„„„„„„„³EnsureGroup´³rec´³lit³ensure-group„´³tupleµ´³named³name´³atom³String„„´³named³spec´³refµ„³Spec„„„„„³GroupMember´³rec´³lit³group-member„´³tupleµ´³named³uid´³atom³
SignedInteger„„´³named³gid´³atom³
SignedInteger„„„„„³
EnsureAccount´³rec´³lit³ensure-account„´³tupleµ´³named³name´³atom³String„„´³named³spec´³refµ„³Spec„„„„„„³embeddedType€„„µ³samsungGalaxyS7„´³schema·³version‘³definitions·³ FmtPacket´³rec´³lit³fmt„´³tupleµ´³named³body´³embedded³any„„„„„³ RfsPacket´³rec´³lit³rfs„´³tupleµ´³named³body´³embedded³any„„„„„³ModemPacket´³orµµ±in´³rec´³lit³
|
||||
AlertSound´³rec´³lit³alert-sound„´³tupleµ´³named³data´³refµ³mime„³Value„„„„„³ContinuousSound´³rec´³lit³continuous-sound„´³tupleµ´³named³data´³refµ³mime„³Value„„„„„³AlertSoundPlaying´³rec´³lit³alert-sound-playing„´³tupleµ„„„³ContinuousSoundPlaying´³rec´³lit³continuous-sound-playing„´³tupleµ„„„„³embeddedType€„„µ³userSettings„´³schema·³version‘³definitions·³Value´³rec´³lit³user-setting„´³tupleµ´³named³item³any„„„„³Action´³orµµ±assert´³rec´³lit³assert„´³tupleµ´³named³item³any„„„„„µ±retract´³rec´³lit³retract„´³tupleµ´³named³item³any„„„„„„„³Command´³rec´³lit³user-settings-command„´³tupleµ´³named³action´³refµ„³Action„„´³named³reply´³refµ„³CommandContinuation„„„„„³CommandReply´³lit³done„³CommandContinuation´³orµµ±replyWanted´³embedded´³refµ„³CommandReply„„„µ±
fireAndForget´³lit€„„„„„³embeddedType€„„µ³usersAndGroups„´³schema·³version‘³definitions·³Spec´³orµµ±userAccount´³lit³user„„µ±
systemAccount´³lit³system„„µ±id´³atom³
SignedInteger„„„„³Group´³rec´³lit³grent„´³tupleµ´³dict·³gid´³named³gid´³atom³
SignedInteger„„³name´³named³name´³atom³String„„„„„„„³Account´³rec´³lit³pwent„´³tupleµ´³dict·³gid´³named³gid´³atom³
SignedInteger„„³uid´³named³uid´³atom³
SignedInteger„„³home´³named³home´³atom³String„„³info´³named³info´³atom³String„„³name´³named³name´³atom³String„„³shell´³named³shell´³atom³String„„„„„„„³EnsureGroup´³rec´³lit³ensure-group„´³tupleµ´³named³name´³atom³String„„´³named³spec´³refµ„³Spec„„„„„³GroupMember´³rec´³lit³group-member„´³tupleµ´³named³uid´³atom³
SignedInteger„„´³named³gid´³atom³
SignedInteger„„„„„³
EnsureAccount´³rec´³lit³ensure-account„´³tupleµ´³named³name´³atom³String„„´³named³spec´³refµ„³Spec„„„„„„³embeddedType€„„µ³samsungGalaxyS7„´³schema·³version‘³definitions·³ FmtPacket´³rec´³lit³fmt„´³tupleµ´³named³body´³embedded³any„„„„„³ RfsPacket´³rec´³lit³rfs„´³tupleµ´³named³body´³embedded³any„„„„„³ModemPacket´³orµµ±in´³rec´³lit³
|
||||
from-modem„´³tupleµ´³named³packet³any„„„„„µ±out´³rec´³lit³to-modem„´³tupleµ´³named³packet³any„„„„„„„³ModemPresent´³rec´³lit³modem„´³tupleµ´³lit³samsung-galaxy-s7„´³named³
|
||||
devicePath´³atom³String„„´³named³ dataspace´³embedded´³refµ„³InternalProtocol„„„„„„³ExecuteCommand´³rec´³lit³execute-command„´³tupleµ´³named³command´³refµ„³ FmtPacket„„´³named³replyTo´³refµ„³CommandContinuation„„„„„³InternalProtocol³any³CommandContinuation´³orµµ±replyWanted´³embedded´³refµ„³ FmtPacket„„„µ±
fireAndForget´³lit€„„„„„³embeddedType€„„„„
|
|
@ -71,3 +71,30 @@ Gateway =
|
|||
.
|
||||
|
||||
DefaultRoute = <default-route @addressFamily AddressFamily> .
|
||||
|
||||
AvailableAccessPoint = <available-ap @interfaceName string @ssid string> .
|
||||
WifiAssociation = <wifi-association @interfaceName string @ssid string @state WifiAssociationState> .
|
||||
WifiAssociationState = @inProgress =in-progress / =ready .
|
||||
|
||||
SelectedWifiNetwork = <selected-wifi-network @interfaceName string @ssid string @authentication WifiAuthentication> .
|
||||
|
||||
Hotspot = <hotspot @interfaceName string @ssid string @authentication WifiAuthentication> .
|
||||
HotspotState = <hotspot-state @interfaceName string @ssid string @stationCount int> .
|
||||
|
||||
;---------------------------------------------------------------------------
|
||||
; User settings
|
||||
|
||||
MobileDataApn = <mobile-data-apn @apn string> .
|
||||
|
||||
SavedWifiNetwork = <saved-wifi-network
|
||||
@ssid string
|
||||
@authentication WifiAuthentication
|
||||
@priority double> .
|
||||
WifiAuthentication =
|
||||
/ ; No authentication necessary: open network
|
||||
=open
|
||||
/ ; Pre-shared key (WPA2-PSK etc)
|
||||
<psk @password string>
|
||||
/ ; Other, not-yet-implemented
|
||||
@other any
|
||||
.
|
||||
|
|
10
protocols/schemas/userSettings.prs
Normal file
10
protocols/schemas/userSettings.prs
Normal file
|
@ -0,0 +1,10 @@
|
|||
version 1 .
|
||||
|
||||
; Assertion.
|
||||
Command = <user-settings-command @action Action @reply CommandContinuation> .
|
||||
CommandContinuation = @replyWanted #!CommandReply / @fireAndForget #f .
|
||||
CommandReply = =done .
|
||||
Action = <assert @item any> / <retract @item any> .
|
||||
|
||||
; Assertion.
|
||||
Value = <user-setting @item any> .
|
Loading…
Reference in a new issue