15#define HAL_kInvalidHandle 0
76#define HAL_ENUM(name) enum name : int32_t
77#elif defined(__clang__)
78#define HAL_ENUM(name) \
79 enum name : int32_t; \
80 typedef enum name name; \
83#define HAL_ENUM(name) \
84 typedef int32_t name; \
95template <
typename CType,
int32_t CInval
id = HAL_kInval
idHandle>
104 Handle(
Handle&& rhs) : m_handle(rhs.m_handle) { rhs.m_handle = CInvalid; }
107 m_handle = rhs.m_handle;
108 rhs.m_handle = CInvalid;
112 operator CType()
const {
return m_handle; }
115 CType m_handle = CInvalid;
A move-only C++ wrapper around a HAL handle.
Definition: Types.h:96
Handle(Handle &&rhs)
Definition: Types.h:104
Handle & operator=(const Handle &)=delete
Handle(CType val)
Definition: Types.h:99
Handle & operator=(Handle &&rhs)
Definition: Types.h:106
Handle(const Handle &)=delete
HAL_Handle HAL_CompressorHandle
Definition: Types.h:27
HAL_Handle HAL_CANHandle
Definition: Types.h:51
HAL_Handle HAL_CTREPCMHandle
Definition: Types.h:67
HAL_CANHandle HAL_PDPHandle
Definition: Types.h:63
HAL_Handle HAL_SerialPortHandle
Definition: Types.h:49
int32_t HAL_Bool
Definition: Types.h:73
HAL_Handle HAL_SolenoidHandle
Definition: Types.h:47
int32_t HAL_Handle
Definition: Types.h:17
HAL_Handle HAL_PortHandle
Definition: Types.h:19
HAL_Handle HAL_DMAHandle
Definition: Types.h:57
HAL_Handle HAL_AnalogTriggerHandle
Definition: Types.h:25
HAL_Handle HAL_SimDeviceHandle
Definition: Types.h:53
HAL_Handle HAL_AnalogOutputHandle
Definition: Types.h:23
HAL_Handle HAL_FPGAEncoderHandle
Definition: Types.h:37
HAL_Handle HAL_DigitalPWMHandle
Definition: Types.h:33
HAL_Handle HAL_GyroHandle
Definition: Types.h:39
HAL_Handle HAL_EncoderHandle
Definition: Types.h:35
HAL_Handle HAL_DutyCycleHandle
Definition: Types.h:59
HAL_Handle HAL_PowerDistributionHandle
Definition: Types.h:65
HAL_Handle HAL_InterruptHandle
Definition: Types.h:41
HAL_Handle HAL_DigitalHandle
Definition: Types.h:31
HAL_Handle HAL_CounterHandle
Definition: Types.h:29
HAL_Handle HAL_REVPHHandle
Definition: Types.h:71
HAL_Handle HAL_RelayHandle
Definition: Types.h:45
HAL_Handle HAL_AnalogInputHandle
Definition: Types.h:21
HAL_Handle HAL_NotifierHandle
Definition: Types.h:43
HAL_Handle HAL_REVPDHHandle
Definition: Types.h:69
HAL_Handle HAL_AddressableLEDHandle
Definition: Types.h:61
HAL_Handle HAL_SimValueHandle
Definition: Types.h:55
WPILib Hardware Abstraction Layer (HAL) namespace.
Definition: ChipObject.h:40