cameraEventType property
CameraEventType?
cameraEventType
Returns the value of the cameraEventType field. Returns null if the field is not defined in the message.
Implementation
CameraEventType? get cameraEventType {
final field = getField(CameraEventCameraEventTypeField.ID);
if (field != null && field.isValid()) {
var subField = field.getValidSubField(fields);
final value = field.getValue(subField: subField);
if (value == null) {
return null;
}
return CameraEventTypeExt.fromValue(value);
} else {
return null;
}
}
Sets the cameraEventType field with value
. Throws FieldNotDefinedError
if the field is not defined in the message.
Implementation
set cameraEventType(CameraEventType? value) {
final field = getField(CameraEventCameraEventTypeField.ID);
if (field != null) {
if (value == null) {
field.clear();
} else {
var subField = field.getValidSubField(fields);
field.setValue(0, value.value, subField);
}
} else {
throw FieldNotDefinedError(field!.name);
}
}