Class PackedHistoricalQualifiedValue
- java.lang.Object
-
- com.inductiveautomation.ignition.gateway.history.PackedHistoricalQualifiedValue
-
- All Implemented Interfaces:
HistoricalData
,HistoricalTagValue
,java.io.Serializable
public class PackedHistoricalQualifiedValue extends java.lang.Object implements HistoricalTagValue
An implementation of historical tag value that stores the enums packed together as an integer.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface com.inductiveautomation.ignition.gateway.history.HistoricalTagValue
TAG_DATA_SIGNITURE
-
-
Constructor Summary
Constructors Constructor Description PackedHistoricalQualifiedValue(TagPath path, DataTypeClass typeClass, InterpolationMode queryMode, TimestampSource tsSource, QualifiedValue value)
PackedHistoricalQualifiedValue(TagPath path, DataTypeClass typeClass, InterpolationMode queryMode, TimestampSource tsSource, java.lang.Object value, DataQuality quality)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
This is overridden in a particular way - we don't take value into account! This implementation is relied on to detect multiple values for a given time, which we can't have.boolean
equals(java.lang.Object value, boolean includeTimestamp)
int
getDataCount()
This is a fairly ambiguous number, but basically indicates how many rows will ultimately be inserted in the database.protected int
getField(int field)
HistoryFlavor
getFlavor()
The very broad "flavor" designator, used to get the data to the correct sink.InterpolationMode
getInterpolationMode()
java.lang.String
getLoggerName()
Returns the name of the logger that should be notified when something happens to this data.DataQuality
getQuality()
java.lang.String
getSignature()
The signature is a static string that describes this data as uniquely as possible.TagPath
getSource()
java.util.Date
getTimestamp()
TimestampSource
getTimestampSource()
DataTypeClass
getTypeClass()
java.lang.Object
getValue()
int
hashCode()
This hashCode function is implemented according to the same constraints as equals aboveprotected void
setField(int field, int value)
java.lang.String
toString()
-
-
-
Constructor Detail
-
PackedHistoricalQualifiedValue
public PackedHistoricalQualifiedValue(TagPath path, DataTypeClass typeClass, InterpolationMode queryMode, TimestampSource tsSource, java.lang.Object value, DataQuality quality)
-
PackedHistoricalQualifiedValue
public PackedHistoricalQualifiedValue(TagPath path, DataTypeClass typeClass, InterpolationMode queryMode, TimestampSource tsSource, QualifiedValue value)
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object value, boolean includeTimestamp)
-
getQuality
public DataQuality getQuality()
- Specified by:
getQuality
in interfaceHistoricalTagValue
-
getTimestamp
public java.util.Date getTimestamp()
- Specified by:
getTimestamp
in interfaceHistoricalTagValue
-
getValue
public java.lang.Object getValue()
- Specified by:
getValue
in interfaceHistoricalTagValue
-
getFlavor
public HistoryFlavor getFlavor()
Description copied from interface:HistoricalData
The very broad "flavor" designator, used to get the data to the correct sink. That is, different sinks support different types of data, and this is used to match them up.- Specified by:
getFlavor
in interfaceHistoricalData
-
getSignature
public java.lang.String getSignature()
Description copied from interface:HistoricalData
The signature is a static string that describes this data as uniquely as possible. This will be used to group data in the data cache (for example, when displaying quarantined data), as well as uniquely identifying cacheable schemas, etc.Basically, the golden rule is that if two pieces of data have the same signature, the came from the same place, and are going to the same place, and in theory could be grouped together (note: they won't be, that is done with the
GroupableData
interface).- Specified by:
getSignature
in interfaceHistoricalData
-
getDataCount
public int getDataCount()
Description copied from interface:HistoricalData
This is a fairly ambiguous number, but basically indicates how many rows will ultimately be inserted in the database. Used for judging transaction size.- Specified by:
getDataCount
in interfaceHistoricalData
-
getLoggerName
public java.lang.String getLoggerName()
Description copied from interface:HistoricalData
Returns the name of the logger that should be notified when something happens to this data. If null or empty, notifications won't occur (errors, however, may still be logged to the general logger).- Specified by:
getLoggerName
in interfaceHistoricalData
-
getSource
public TagPath getSource()
- Specified by:
getSource
in interfaceHistoricalTagValue
-
getTypeClass
public DataTypeClass getTypeClass()
- Specified by:
getTypeClass
in interfaceHistoricalTagValue
-
getInterpolationMode
public InterpolationMode getInterpolationMode()
- Specified by:
getInterpolationMode
in interfaceHistoricalTagValue
-
getTimestampSource
public TimestampSource getTimestampSource()
- Specified by:
getTimestampSource
in interfaceHistoricalTagValue
-
getField
protected int getField(int field)
-
setField
protected void setField(int field, int value)
-
equals
public boolean equals(java.lang.Object obj)
This is overridden in a particular way - we don't take value into account! This implementation is relied on to detect multiple values for a given time, which we can't have. If all other settings are equal, we only look at timestamp.- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
This hashCode function is implemented according to the same constraints as equals above- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-