Nadja von Reitzenstein Čerpnjak d7c26ed4c1 Add traits
2024-04-16 14:37:41 +02:00

32 lines
1.1 KiB
Cap'n Proto

@0xccad643c8c6f6b25;
using import "traits.capnp".TraitSuper;
using import "utils.capnp".Fallible;
using import "utils.capnp".Duration;
using import "traits_error.capnp".TraitError;
# OID for this trait: 1.3.6.1.4.1.61783.612.1.2
# │ │ │ │
# RLKM UG PEN ╯ │ │ │
# │ │ │
# FabAccess subtree ╯ │ │
# │ │
# Traits ╯ │
# │
# Doorable ╯
interface TraitDoorable extends (TraitSuper) {
getState @0 () -> StateDoorable;
unlock @1 () -> Fallible(TraitDoorable, TraitError(StateDoorable));
unlockTemp @2 ( time :Duration ) -> Fallible(TraitDoorable, TraitError(StateDoorable));
lock @3 () -> Fallible(TraitDoorable, TraitError(StateDoorable));
}
struct StateDoorable {
union {
Closed @0 :Void;
Open @1 :Void;
TempOpen @2 :Void;
}
}