public class AuxPoint extends Object implements Comparable<AuxPoint>
Constructor and Description |
---|
AuxPoint(ZonedDateTime timeStamp) |
AuxPoint(ZonedDateTime timeStamp,
Map<String,Serializable> data)
Creates an AuxPoint from a Timestamp and a map containing key,value pairs as found in the slow control data.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(AuxPoint o) |
boolean |
equals(Object o) |
com.google.common.collect.ImmutableMap<String,Serializable> |
getData() |
Double |
getDouble(String key)
Returns the value for the key iff it exists and its a Double.
|
double[] |
getDoubleArray(String key)
Returns the value for the key iff it exists and its an int[].
|
Float |
getFloat(String key)
Returns the value for the key iff it exists and its a Float.
|
Integer |
getInteger(String key)
Returns the value for the key iff it exists and its an Integer.
|
int[] |
getIntegerArray(String key)
Returns the value for the key iff it exists and its an int[].
|
String |
getString(String key)
Returns the value for the key iff it exists and its a String.
|
ZonedDateTime |
getTimeStamp()
The timestamp from when sensor recorded this AuxPoint.
|
<T> Optional<T> |
getValue(String key,
Class<T> cls)
Returns an Optional containing the value with the given class iff it exists.
|
int |
hashCode() |
String |
toString() |
public AuxPoint(ZonedDateTime timeStamp)
public AuxPoint(ZonedDateTime timeStamp, Map<String,Serializable> data)
timeStamp
- the timestamp specifying when the auxiliary data was recorded.data
- a map containing the names and values from the .fits files as key values pairs.public ZonedDateTime getTimeStamp()
public com.google.common.collect.ImmutableMap<String,Serializable> getData()
public Double getDouble(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic Float getFloat(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic Integer getInteger(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic String getString(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic int[] getIntegerArray(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic double[] getDoubleArray(String key)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filepublic <T> Optional<T> getValue(String key, Class<T> cls)
key
- the name of the aux data you want to access. e.g. the name of the column in the aux fits filecls
- the data type you expect the value to be inpublic int compareTo(AuxPoint o)
compareTo
in interface Comparable<AuxPoint>
Copyright © 2019. All rights reserved.