fromNativeValue static method
- dynamic value
Gets a possible PrintJobColorMode instance from a native value.
Implementation
static PrintJobColorMode? fromNativeValue(dynamic value) {
if (value != null) {
try {
return PrintJobColorMode.values.firstWhere(
(element) => element.toNativeValue() == value,
);
} catch (e) {
return null;
}
}
return null;
}