Package io.openems.common.channel
Enum Class PersistencePriority
- All Implemented Interfaces:
Serializable
,Comparable<PersistencePriority>
,Constable
The
PersistencePriority
is used by...
- Timedata.Rrd4j: persist Channel values locally
- Controller.Api.MQTT: transmit Channel values via MQTT
- Controller.Api.Backend: transmit Channel values to OpenEMS Backend
These services use the PersistencePriority
to distinguish whether a
value of a Channel should be:
- persisted/transmitted in high resolution (e.g. once per second)
- persisted/transmitted in low resolution (e.g. aggregated to 5 minutes values)
- not persisted
The PersistencePriority
of a Channel may be set via
AbstractDoc::persistencePriority(). Defaults are:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionChannels with at least this priority are by default (if not configured differently)...Channels with at least this priority are by default (if not configured differently)...Channels with at least this priority are by default (if not configured differently)...VERY_HIGH
is reserved for Channels of the `Core.Sum` Component.Channels with at least this priority are by default (if not configured differently)... -
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isAtLeast
(PersistencePriority other) Is thisPersistencePriority
at least as high as the givenPersistencePriority
?.boolean
isLowerThan
(PersistencePriority other) Is thisPersistencePriority
at lower than the givenPersistencePriority
?.static PersistencePriority
Returns the enum constant of this class with the specified name.static PersistencePriority[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
VERY_LOW
Channels with at least this priority are by default (if not configured differently)...- Timedata.Rrd4j: not persisted
- Controller.Api.MQTT: transmitted in high resolution
- Controller.Api.Backend: not transmitted
-
LOW
Channels with at least this priority are by default (if not configured differently)...- Controller.Api.Backend: transmitted as aggregated values (via
AggregatedDataNotification
)
- Controller.Api.Backend: transmitted as aggregated values (via
-
MEDIUM
Channels with at least this priority are by default (if not configured differently)...- Timedata.Rrd4j: persisted as aggregated values
-
HIGH
Channels with at least this priority are by default (if not configured differently)...- Controller.Api.Backend: transmitted in high resolution (via
TimestampedDataNotification
), i.e. on every change or at least once every 5 minutes
- Controller.Api.Backend: transmitted in high resolution (via
-
VERY_HIGH
VERY_HIGH
is reserved for Channels of the `Core.Sum` Component.
-
-
Field Details
-
DEFAULT_PERSISTENCE_PRIORITY
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
isAtLeast
Is thisPersistencePriority
at least as high as the givenPersistencePriority
?.- Parameters:
other
- the givenPersistencePriority
- Returns:
- true if this is equal or higher than other
-
isLowerThan
Is thisPersistencePriority
at lower than the givenPersistencePriority
?.- Parameters:
other
- the givenPersistencePriority
- Returns:
- true if this is strictly lower than other
-