class ZoneShape

August 13, 2019 ยท View on GitHub

Member values

Member nameData typeDescription
shape_typeuint32Shape type
originPointOrigin of the protection zone shape from reference (in meters)
orientationRotationMatrixRotation matrix to provide shape orientation
dimensionsfloat32Shape size measurement (in meters). If rectangular prism: x, y and z dimensions. If cylinder: radius and height. If sphere: radius
envelope_thicknessfloat32Thickness of envelop around shape (in meters). The envelop is of same shape type as the shape at its center.

Member functions

Function nameReturn typeInput typeDescription
shape_type() constuint32voidReturns the current value of shape_type. If the shape_type is not set, returns 0.
set_shape_type()voiduint32Sets the value of shape_type. After calling this, shape_type() will return value.
clear_shape_type()voidvoidClears the value of shape_type. After calling this, shape_type() will return the empty string/empty bytes.
has_origin() constboolvoidReturns true if origin is set.
origin()const Point&voidReturns the current value of origin. If origin is not set, returns a Point with none of its fields set (possibly origin::default_instance()).
mutable_origin()Point *voidReturns a pointer to the mutable Point object that stores the field's value. If the field was not set prior to the call, then the returned Point will have none of its fields set (i.e. it will be identical to a newly-allocated Point). After calling this, has_origin() will return true and origin() will return a reference to the same instance of Point.
clear_origin()voidvoidClears the value of the field. After calling this, has_origin() will return false and origin() will return the default value.
set_allocated_origin()voidPoint *Sets the Point object to the field and frees the previous field value if it exists. If the Point pointer is not NULL, the message takes ownership of the allocated Point object and has_ Point() will return true. Otherwise, if the origin is NULL, the behavior is the same as calling clear_origin().
release_origin()Point *voidReleases the ownership of the field and returns the pointer of the Point object. After calling this, caller takes the ownership of the allocated Point object, has_origin() will return false, and origin() will return the default value.
has_orientation() constboolvoidReturns true if orientation is set.
orientation()const RotationMatrix&voidReturns the current value of orientation. If orientation is not set, returns a RotationMatrix with none of its fields set (possibly orientation::default_instance()).
mutable_orientation()RotationMatrix *voidReturns a pointer to the mutable RotationMatrix object that stores the field's value. If the field was not set prior to the call, then the returned RotationMatrix will have none of its fields set (i.e. it will be identical to a newly-allocated RotationMatrix). After calling this, has_orientation() will return true and orientation() will return a reference to the same instance of RotationMatrix.
clear_orientation()voidvoidClears the value of the field. After calling this, has_orientation() will return false and orientation() will return the default value.
set_allocated_orientation()voidRotationMatrix *Sets the RotationMatrix object to the field and frees the previous field value if it exists. If the RotationMatrix pointer is not NULL, the message takes ownership of the allocated RotationMatrix object and has_ RotationMatrix() will return true. Otherwise, if the orientation is NULL, the behavior is the same as calling clear_orientation().
release_orientation()RotationMatrix *voidReleases the ownership of the field and returns the pointer of the RotationMatrix object. After calling this, caller takes the ownership of the allocated RotationMatrix object, has_orientation() will return false, and orientation() will return the default value.
dimensions_size() constintvoidReturns the number of elements currently in the field.
dimensions() constintint indexReturns the element at the given zero-based index. Calling this method with index outside of [0, dimensions_size()) yields undefined behavior.
set_dimensions()void(int index, int32 value)Sets the value of the element at the given zero-based index.
add_dimensions()void(int32 value)Appends a new element to the field with the given value.
clear_dimensions()voidvoidRemoves all elements from the field. After calling this, dimensions_size() will return zero.
dimensions() constconst RepeatedField<int32>&voidReturns the underlying RepeatedField that stores the field's elements. This container class provides STL-like iterators and other methods.
mutable_dimensions()RepeatedField<int32>*voidReturns a pointer to the underlying mutable RepeatedField that stores the field's elements. This container class provides STL-like iterators and other methods.
envelope_thickness()float32voidReturns the current value of envelope_thickness. If the envelope_thickness is not set, returns 0.
set_envelope_thickness()voidfloat32Sets the value of envelope_thickness. After calling this, envelope_thickness() will return value.
clear_envelope_thickness()voidvoidClears the value of envelope_thickness. After calling this, envelope_thickness() will return 0.

Parent topic: Base (C++)