Class PBFileInfo
- java.lang.Object
-
- edu.stanford.slac.archiverappliance.PlainPB.PBFileInfo
-
public class PBFileInfo extends Object
Gets some information about PB files. Important information includes the first and last event.- Author:
- mshankar
-
-
Constructor Summary
Constructors Constructor Description PBFileInfo(Path path)
PBFileInfo(Path path, boolean lookupLastEvent)
-
Method Summary
Modifier and Type Method Description static void
checkPayloadInfo(LineByteStream lis, String pvName, ArchDBRTypes type)
Checks the payload info and makes sure we are using appropriate files.short
getDataYear()
DBRTimeEvent
getFirstEvent()
long
getFirstEventEpochSeconds()
EPICSEvent.PayloadInfo
getInfo()
DBRTimeEvent
getLastEvent()
long
getLastEventEpochSeconds()
long
getPositionOfFirstSample()
long
getPositionOfLastSample()
String
getPVName()
ArchDBRTypes
getType()
-
-
-
Constructor Detail
-
PBFileInfo
public PBFileInfo(Path path) throws IOException
- Throws:
IOException
-
PBFileInfo
public PBFileInfo(Path path, boolean lookupLastEvent) throws IOException
- Throws:
IOException
-
-
Method Detail
-
getPVName
public String getPVName()
-
getDataYear
public short getDataYear()
-
getType
public ArchDBRTypes getType()
-
getInfo
public EPICSEvent.PayloadInfo getInfo()
-
getFirstEvent
public DBRTimeEvent getFirstEvent()
-
getLastEvent
public DBRTimeEvent getLastEvent()
-
getFirstEventEpochSeconds
public long getFirstEventEpochSeconds()
-
getLastEventEpochSeconds
public long getLastEventEpochSeconds()
-
getPositionOfFirstSample
public long getPositionOfFirstSample()
-
getPositionOfLastSample
public long getPositionOfLastSample()
-
checkPayloadInfo
public static void checkPayloadInfo(LineByteStream lis, String pvName, ArchDBRTypes type) throws IOException
Checks the payload info and makes sure we are using appropriate files. This assumes that the lis is positioned at the start and subsequently positions the lis just past the first line. So if we need to position the lis elsewhere, the caller needs to do that manually after this call.- Parameters:
lis
- The line bytes streampvName
- The PV nametype
- Enum ArchDBRTypes- Throws:
IOException
-
-
-