Loading...
Searching...
No Matches

Structure representing a sensor measurement with type, values, and timestamp. More...

#include <com/navigine/idl/objc/NCSensorMeasurement.h>

Inherits NSObject.

Instance Methods

(nonnull instancetype) - initWithType:values:time:
 Default constructor for class NCSensorMeasurement.
 
(NSComparisonResult) - compare:
 

Class Methods

(nonnull instancetype) + sensorMeasurementWithType:values:time:
 Factory method for class NCSensorMeasurement.
 

Properties

NCSensorType type
 Type of the sensor.
 
NCVector3dvalues
 3D vector containing sensor measurement values
 
int64_t time
 Timestamp of the measurement in milliseconds.
 

Detailed Description

Structure representing a sensor measurement with type, values, and timestamp.

Referenced from MeasurementListener.

Definition at line 19 of file NCSensorMeasurement.h.

Method Documentation

◆ compare:

- (NSComparisonResult) compare: (nonnull NCSensorMeasurement *) other

◆ initWithType:values:time:

- (nonnull instancetype) initWithType: (NCSensorType) type
values: (nonnull NCVector3d *) values
time: (int64_t) time 

Default constructor for class NCSensorMeasurement.

◆ sensorMeasurementWithType:values:time:

+ (nonnull instancetype) sensorMeasurementWithType: (NCSensorType) type
values: (nonnull NCVector3d *) values
time: (int64_t) time 

Factory method for class NCSensorMeasurement.

Property Documentation

◆ time

- (int64_t) time
readnonatomicassign

Timestamp of the measurement in milliseconds.

Swift code snippet:

// Get measurement timestamp
let time = measurement.time
print("Measurement time: \‍(time) ms")

Objective C code snippet:

// Get measurement timestamp
long long time = measurement.time;
NSLog(@"Measurement time: %lld ms", time);

Definition at line 75 of file NCSensorMeasurement.h.

◆ type

- (NCSensorType) type
readnonatomicassign

Type of the sensor.

Swift code snippet:

// Get sensor type
let type = measurement.type
print("Sensor type: \‍(type)")

Objective C code snippet:

// Get sensor type
NCSensorType type = measurement.type;
NSLog(@"Sensor type: %ld", (long)type);

Definition at line 47 of file NCSensorMeasurement.h.

◆ values

- (NCVector3d*) values
readnonatomicassign

3D vector containing sensor measurement values

Swift code snippet:

// Get sensor values
let values = measurement.values
print("Sensor values - X: \‍(values.x), Y: \‍(values.y), Z: \‍(values.z)")

Objective C code snippet:

// Get sensor values
NCVector3d *values = measurement.values;
NSLog(@"Sensor values - X: %f, Y: %f, Z: %f", values.x, values.y, values.z);

Definition at line 61 of file NCSensorMeasurement.h.


The documentation for this class was generated from the following file: