Skip to content

Latest commit

 

History

History
55 lines (49 loc) · 11.2 KB

File metadata and controls

55 lines (49 loc) · 11.2 KB

class ControllerConfiguration

Member values

Member name Data type Description
handle ControllerHandle Controller identifier
name string Controller friendly name
active_mapping_handle MappingHandle Mapping that is active on this controller
analog_input_identifier_enum string Name that identifies the enum used to interpret the ‘analog_input_identifier’ field (for example in ControllerEvent). Thus 'analog_input_identifier_enum' shall take the name of an existing enum (ex. Xbox360AnalogInputIdentifier)
digital_input_identifier_enum string Name that identifies the enum used to interpret the ‘digital_input_identifier’ field (for example in ControllerEvent). Thus 'digital_input_identifier_enum' shall take the name of an existing enum (ex. Xbox360DigitalInputIdentifier, WristDigitalInputIdentifier)

Member functions

Function name Return type Input type Description
has_handle() const bool void Returns true if handle is set.
handle() const ControllerHandle& void Returns the current value of handle. If handle is not set, returns a ControllerHandle with none of its fields set (possibly handle::default_instance()).
mutable_handle() ControllerHandle * void Returns a pointer to the mutable ControllerHandle object that stores the field's value. If the field was not set prior to the call, then the returned ControllerHandle will have none of its fields set (i.e. it will be identical to a newly-allocated ControllerHandle). After calling this, has_handle() will return true and handle() will return a reference to the same instance of ControllerHandle.
clear_handle() void void Clears the value of the field. After calling this, has_handle() will return false and handle() will return the default value.
set_allocated_handle() void ControllerHandle * Sets the ControllerHandle object to the field and frees the previous field value if it exists. If the ControllerHandle pointer is not NULL, the message takes ownership of the allocated ControllerHandle object and has_ ControllerHandle() will return true. Otherwise, if the handle is NULL, the behavior is the same as calling clear_handle().
release_handle() ControllerHandle * void Releases the ownership of the field and returns the pointer of the ControllerHandle object. After calling this, caller takes the ownership of the allocated ControllerHandle object, has_handle() will return false, and handle() will return the default value.
name() const string& void Returns the current value of name. If name is not set, returns the empty string/empty bytes.
set_name() void const string& Sets the value of name. After calling this, name() will return a copy of value.
set_name() void string&& (C++11 and beyond): Sets the value of name, moving from the passed string. After calling this, name() will return a copy of value.
set_name() void const char* Sets the value of name using a C-style null-terminated string. After calling this, name() will return a copy of value.
mutable_name() string * void Returns a pointer to the mutable string object that stores name's value. If the field was not set prior to the call, then the returned string will be empty. After calling this, name() will return whatever value is written into the given string.
clear_name() void void Clears the value of name. After calling this, name() will return the empty string/empty bytes.
set_allocated_name() void string* Sets the string object to the field and frees the previous field value if it exists. If the string pointer is not NULL, the message takes ownership of the allocated string object. The message is free to delete the allocated string object at any time, so references to the object may be invalidated. Otherwise, if the value is NULL, the behavior is the same as calling clear_name().
release_name() string * void Releases the ownership of name and returns the pointer of the string object. After calling this, caller takes the ownership of the allocated string object and name() will return the empty string/empty bytes.
has_active_mapping_handle() const bool void Returns true if active_mapping_handle is set.
active_mapping_handle() const MappingHandle& void Returns the current value of active_mapping_handle. If active_mapping_handle is not set, returns a MappingHandle with none of its fields set (possibly active_mapping_handle::default_instance()).
mutable_active_mapping_handle() MappingHandle * void Returns a pointer to the mutable MappingHandle object that stores the field's value. If the field was not set prior to the call, then the returned MappingHandle will have none of its fields set (i.e. it will be identical to a newly-allocated MappingHandle). After calling this, has_active_mapping_handle() will return true and active_mapping_handle() will return a reference to the same instance of MappingHandle.
clear_active_mapping_handle() void void Clears the value of the field. After calling this, has_active_mapping_handle() will return false and active_mapping_handle() will return the default value.
set_allocated_active_mapping_handle() void MappingHandle * Sets the MappingHandle object to the field and frees the previous field value if it exists. If the MappingHandle pointer is not NULL, the message takes ownership of the allocated MappingHandle object and has_ MappingHandle() will return true. Otherwise, if the active_mapping_handle is NULL, the behavior is the same as calling clear_active_mapping_handle().
release_active_mapping_handle() MappingHandle * void Releases the ownership of the field and returns the pointer of the MappingHandle object. After calling this, caller takes the ownership of the allocated MappingHandle object, has_active_mapping_handle() will return false, and active_mapping_handle() will return the default value.
analog_input_identifier_enum() const string& void Returns the current value of analog_input_identifier_enum. If analog_input_identifier_enum is not set, returns the empty string/empty bytes.
set_analog_input_identifier_enum() void const string& Sets the value of analog_input_identifier_enum. After calling this, analog_input_identifier_enum() will return a copy of value.
set_analog_input_identifier_enum() void string&& (C++11 and beyond): Sets the value of analog_input_identifier_enum, moving from the passed string. After calling this, analog_input_identifier_enum() will return a copy of value.
set_analog_input_identifier_enum() void const char* Sets the value of analog_input_identifier_enum using a C-style null-terminated string. After calling this, analog_input_identifier_enum() will return a copy of value.
mutable_analog_input_identifier_enum() string * void Returns a pointer to the mutable string object that stores analog_input_identifier_enum's value. If the field was not set prior to the call, then the returned string will be empty. After calling this, analog_input_identifier_enum() will return whatever value is written into the given string.
clear_analog_input_identifier_enum() void void Clears the value of analog_input_identifier_enum. After calling this, analog_input_identifier_enum() will return the empty string/empty bytes.
set_allocated_analog_input_identifier_enum() void string* Sets the string object to the field and frees the previous field value if it exists. If the string pointer is not NULL, the message takes ownership of the allocated string object. The message is free to delete the allocated string object at any time, so references to the object may be invalidated. Otherwise, if the value is NULL, the behavior is the same as calling clear_analog_input_identifier_enum().
release_analog_input_identifier_enum() string * void Releases the ownership of analog_input_identifier_enum and returns the pointer of the string object. After calling this, caller takes the ownership of the allocated string object and analog_input_identifier_enum() will return the empty string/empty bytes.
digital_input_identifier_enum() const string& void Returns the current value of digital_input_identifier_enum. If digital_input_identifier_enum is not set, returns the empty string/empty bytes.
set_digital_input_identifier_enum() void const string& Sets the value of digital_input_identifier_enum. After calling this, digital_input_identifier_enum() will return a copy of value.
set_digital_input_identifier_enum() void string&& (C++11 and beyond): Sets the value of digital_input_identifier_enum, moving from the passed string. After calling this, digital_input_identifier_enum() will return a copy of value.
set_digital_input_identifier_enum() void const char* Sets the value of digital_input_identifier_enum using a C-style null-terminated string. After calling this, digital_input_identifier_enum() will return a copy of value.
mutable_digital_input_identifier_enum() string * void Returns a pointer to the mutable string object that stores digital_input_identifier_enum's value. If the field was not set prior to the call, then the returned string will be empty. After calling this, digital_input_identifier_enum() will return whatever value is written into the given string.
clear_digital_input_identifier_enum() void void Clears the value of digital_input_identifier_enum. After calling this, digital_input_identifier_enum() will return the empty string/empty bytes.
set_allocated_digital_input_identifier_enum() void string* Sets the string object to the field and frees the previous field value if it exists. If the string pointer is not NULL, the message takes ownership of the allocated string object. The message is free to delete the allocated string object at any time, so references to the object may be invalidated. Otherwise, if the value is NULL, the behavior is the same as calling clear_digital_input_identifier_enum().
release_digital_input_identifier_enum() string * void Releases the ownership of digital_input_identifier_enum and returns the pointer of the string object. After calling this, caller takes the ownership of the allocated string object and digital_input_identifier_enum() will return the empty string/empty bytes.

Parent topic: Base (C++)