Class MetaInfo
- java.lang.Object
-
- org.epics.archiverappliance.config.MetaInfo
-
public class MetaInfo extends Object
this class is used for getting the meta data- Author:
- luofeng li
-
-
Constructor Summary
Constructors Constructor Description MetaInfo()
-
Method Summary
Modifier and Type Method Description void
addOtherMetaInfo(String name, Double value)
add other meta info such as MDEL,ADELvoid
addOtherMetaInfo(String name, String value)
add other meta info such as MDEL,ADELvoid
addToDict(HashMap<String,String> retVal)
Add the latest metadata values to the dictvoid
applyBasicInfo(String pvName, gov.aps.jca.dbr.DBR dbr, ConfigService configService)
save the basical info from dbrvoid
applyV4BasicInfo(String pvName, org.epics.pvdata.pv.PVStructure pvStructure, ConfigService configService)
void
computeRate(DBRTimeEvent dbrtimeevent)
compute the storage rate and the event rateString
getAliasName()
get aliasNameArchDBRTypes
getArchDBRTypes()
get ArchDBRTypesint
getCount()
get the element count of the pv's value.long
getEventCount()
get total count of event in 1 minute.double
getEventRate()
get the average event rate in 1 minuteString
getHostName()
String[]
getLabel()
double
getLoweCtrlLimit()
get loweCtrlLimitdouble
getLowerAlarmLimit()
get lowerAlarmLimitdouble
getLowerDisplayLimit()
get lowerDisplayLimitdouble
getLowerWarningLimit()
get lowerWarningLimitHashMap<String,String>
getOtherMetaInfo()
int
getPrecision()
get precisiondouble
getSecond()
long
getStartTime()
get the time when archiving this pv.double
getStorageRate()
get the average storage rate in one minutelong
getStorageSize()
get the toal storage size of the event in 1 minuteString
getUnit()
get unitdouble
getUpperAlarmLimit()
get upperAlarmLimitdouble
getUpperCtrlLimit()
get upperCtrlLimitdouble
getUpperDisplayLimit()
get upperDisplayLimitdouble
getUpperWarningLimit()
get upperWarningLimitboolean
isVector()
the pv is vector or notvoid
setAliasName(String aliaseName)
set aliaseNamevoid
setArchDBRTypes(ArchDBRTypes archDBRTypes)
set the archiving DBRType for this pvvoid
setCount(int count)
set the count of pv's value.void
setEventCount(long eventCount)
set the total event countvoid
setEventRate(double eventRate)
set the event ratevoid
setHostName(String hostName)
void
setLabel(String[] label)
void
setLoweCtrlLimit(double loweCtrlLimit)
set the lower ctrl limitvoid
setLowerAlarmLimit(double lowerAlarmLimit)
set the lower Alarm Limitvoid
setLowerDisplayLimit(double lowerDisplayLimit)
set the lower display limitvoid
setLowerWarningLimit(double lowerWarningLimit)
set the lower warning limitvoid
setOtherMetaInfo(HashMap<String,String> otherMetaInfo)
save the other info such as MDEL,ADELvoid
setPrecision(int precision)
set the precisionvoid
setSecond(double second)
void
setStartTime(long startTime)
set the starting time of archiving this pvvoid
setStorageRate(double storageRate)
set the storage ratevoid
setStorageSize(long storageSize)
set total storage size of the event until nowvoid
setUnit(String unit)
set the unitvoid
setUpperAlarmLimit(double upperAlarmLimit)
set the upper alarm limitvoid
setUpperCtrlLimit(double upperCtrlLimit)
set the upper ctrl limitvoid
setUpperDisplayLimit(double upperDisplayLimit)
set the upper display limitvoid
setUpperWarningLimit(double upperWarningLimit)
set the upper warning limitvoid
setVector(boolean isVector)
set this pv to be a vector or notString
toString()
-
-
-
Method Detail
-
addOtherMetaInfo
public void addOtherMetaInfo(String name, Double value)
add other meta info such as MDEL,ADEL- Parameters:
name
- the info namevalue
- the info value
-
getHostName
public String getHostName()
- Returns:
- the host name where this pv is
-
setHostName
public void setHostName(String hostName)
- Parameters:
hostName
- the host name where this pv is
-
addOtherMetaInfo
public void addOtherMetaInfo(String name, String value)
add other meta info such as MDEL,ADEL- Parameters:
name
- the info namevalue
- the info value
-
setStartTime
public void setStartTime(long startTime)
set the starting time of archiving this pv- Parameters:
startTime
- the number of milliseconds since 1970/01/01
-
getOtherMetaInfo
public HashMap<String,String> getOtherMetaInfo()
- Returns:
- the HashMap including all other info for this pv.
-
applyBasicInfo
public void applyBasicInfo(String pvName, gov.aps.jca.dbr.DBR dbr, ConfigService configService)
save the basical info from dbr- Parameters:
pvName
- the name of the PVdbr
- EPICS DB recordconfigService
- ConfigService
-
setAliasName
public void setAliasName(String aliaseName)
set aliaseName- Parameters:
aliaseName
-
-
getLowerAlarmLimit
public double getLowerAlarmLimit()
get lowerAlarmLimit- Returns:
- lowerAlarmLimit <PV Name>.LOLO
-
getLoweCtrlLimit
public double getLoweCtrlLimit()
get loweCtrlLimit- Returns:
- loweCtrlLimit <PV Name>.DRVL
-
getLowerDisplayLimit
public double getLowerDisplayLimit()
get lowerDisplayLimit- Returns:
- lowerDisplayLimit <PV Name>.LOPR
-
getLowerWarningLimit
public double getLowerWarningLimit()
get lowerWarningLimit- Returns:
- lowerWarningLimit <PV Name>.LOW
-
getUpperAlarmLimit
public double getUpperAlarmLimit()
get upperAlarmLimit- Returns:
- upperAlarmLimit <PV Name>.HIHI
-
getUpperCtrlLimit
public double getUpperCtrlLimit()
get upperCtrlLimit- Returns:
- upperCtrlLimit <PV Name>.DRVH
-
getUpperDisplayLimit
public double getUpperDisplayLimit()
get upperDisplayLimit- Returns:
- upperDisplayLimit <PV Name>.HOPR
-
getUpperWarningLimit
public double getUpperWarningLimit()
get upperWarningLimit- Returns:
- upperWarningLimit <PV Name>.HIGH
-
getPrecision
public int getPrecision()
get precision- Returns:
- precision <PV Name>.PREC
-
getUnit
public String getUnit()
get unit- Returns:
- unit <PV Name>.EGU
-
getAliasName
public String getAliasName()
get aliasName- Returns:
- aliasName <PV Name>.NAME
-
getArchDBRTypes
public ArchDBRTypes getArchDBRTypes()
get ArchDBRTypes- Returns:
- ArchDBRTypes
-
getEventRate
public double getEventRate()
get the average event rate in 1 minute- Returns:
- eventRate the average event rate in 1 min
-
getStorageRate
public double getStorageRate()
get the average storage rate in one minute- Returns:
- storageRate average storage rate (bytes per second)
-
getCount
public int getCount()
get the element count of the pv's value.- Returns:
- count
-
isVector
public boolean isVector()
the pv is vector or not- Returns:
- isVector true if vector, else false;
-
getLabel
public String[] getLabel()
-
getEventCount
public long getEventCount()
get total count of event in 1 minute.- Returns:
- eventCount the count of event in one minute
-
getStorageSize
public long getStorageSize()
get the toal storage size of the event in 1 minute- Returns:
- storageSize toal storage size in one minute
-
getSecond
public double getSecond()
-
computeRate
public void computeRate(DBRTimeEvent dbrtimeevent)
compute the storage rate and the event rate- Parameters:
dbrtimeevent
- DBRTimeEvent
-
getStartTime
public long getStartTime()
get the time when archiving this pv.- Returns:
- startTime the starting time and the number of milliseconds since 1970/01/01
-
setArchDBRTypes
public void setArchDBRTypes(ArchDBRTypes archDBRTypes)
set the archiving DBRType for this pv- Parameters:
archDBRTypes
- ArchDBRTypes
-
setOtherMetaInfo
public void setOtherMetaInfo(HashMap<String,String> otherMetaInfo)
save the other info such as MDEL,ADEL- Parameters:
otherMetaInfo
- a hashmap including the other meta info.
-
setLowerAlarmLimit
public void setLowerAlarmLimit(double lowerAlarmLimit)
set the lower Alarm Limit- Parameters:
lowerAlarmLimit
- the lower Alarm Limit
-
setLoweCtrlLimit
public void setLoweCtrlLimit(double loweCtrlLimit)
set the lower ctrl limit- Parameters:
loweCtrlLimit
- the lower ctrl limit
-
setLowerDisplayLimit
public void setLowerDisplayLimit(double lowerDisplayLimit)
set the lower display limit- Parameters:
lowerDisplayLimit
- the lower display limit
-
setLowerWarningLimit
public void setLowerWarningLimit(double lowerWarningLimit)
set the lower warning limit- Parameters:
lowerWarningLimit
- the lower warning limit
-
setUpperAlarmLimit
public void setUpperAlarmLimit(double upperAlarmLimit)
set the upper alarm limit- Parameters:
upperAlarmLimit
- the upper alarm limit
-
setUpperCtrlLimit
public void setUpperCtrlLimit(double upperCtrlLimit)
set the upper ctrl limit- Parameters:
upperCtrlLimit
- the upper ctrl limit
-
setUpperDisplayLimit
public void setUpperDisplayLimit(double upperDisplayLimit)
set the upper display limit- Parameters:
upperDisplayLimit
- the upper display limit
-
setUpperWarningLimit
public void setUpperWarningLimit(double upperWarningLimit)
set the upper warning limit- Parameters:
upperWarningLimit
- the upper warning limit
-
setPrecision
public void setPrecision(int precision)
set the precision- Parameters:
precision
- the precision
-
setUnit
public void setUnit(String unit)
set the unit- Parameters:
unit
- the unit
-
setEventCount
public void setEventCount(long eventCount)
set the total event count- Parameters:
eventCount
-
-
setStorageSize
public void setStorageSize(long storageSize)
set total storage size of the event until now- Parameters:
storageSize
-
-
setEventRate
public void setEventRate(double eventRate)
set the event rate- Parameters:
eventRate
- the event rate
-
setStorageRate
public void setStorageRate(double storageRate)
set the storage rate- Parameters:
storageRate
- storage rate
-
setCount
public void setCount(int count)
set the count of pv's value.- Parameters:
count
-
-
setVector
public void setVector(boolean isVector)
set this pv to be a vector or not- Parameters:
isVector
-
-
setLabel
public void setLabel(String[] label)
-
setSecond
public void setSecond(double second)
-
addToDict
public void addToDict(HashMap<String,String> retVal)
Add the latest metadata values to the dict- Parameters:
retVal
- HashMap
-
applyV4BasicInfo
public void applyV4BasicInfo(String pvName, org.epics.pvdata.pv.PVStructure pvStructure, ConfigService configService)
-
-