sends::frame_loc Class Reference
[Sends Data Classes]

Location of a series of frame files. More...

#include <frame_loc.hh>

List of all members.

Public Types

enum  arch_type { kOnline, kCache, kArchive, kOffline }
enum  driver_type {
  kLocal, kSamQfs, kSends, kShared,
  kUnknown
}
typedef unsigned long gps_type

Public Member Functions

 frame_loc (const std::string &location, const std::string &prefix, gps_type start, gps_type stop, gps_type dT, arch_type type, driver_type driv=kUnknown)
 Constructor.
 ~frame_loc (void)
 Frame location destructor.
arch_type archive (void) const
 Get the archive level.
driver_type driver (void) const
 Get the driver type.
std::ostream & dump (std::ostream &out) const
 Dump the locateion.
gps_type frame_end (gps_type t) const
 Get the frame end time.
std::string frame_path (gps_type gps) const
 Get the frame path.
gps_type frame_start (gps_type t) const
 Get the frame start time.
gps_type gps_end (void) const
 Get the location end time.
gps_type gps_start (void) const
 Get the location start time.
bool in_range (gps_type gps) const
 Test if time is in range.
const std::string & prefix (void) const
gps_type start (void) const
gps_type stop (void) const


Detailed Description

Location of a series of frame files.

The frame_loc class contains information about a set of consecutive frames of a given type in a specified area. The frame source type conststs of the first two fields of the frame file name, i.e. the site code and the frame type, e.g. "H-RDS_R_L1". The source path may contain escaped format descriptions that are replaced by the start GPS of a frame when the path is resolved. For example, frame_path() would replace the escaped format sequence in "/archive/frames/S5/L0/LLO/L-R-%3d" with the first 3 digits of the gps time of the frame being resolved.

Author:
John Zweizig
Version:
1.0; Last Modified January 22, 2008

Member Typedef Documentation

typedef unsigned long sends::frame_loc::gps_type

GPS time representation type.


Member Enumeration Documentation

Frame data archive level.

Frame data input driver type.


Constructor & Destructor Documentation

sends::frame_loc::frame_loc ( const std::string &  location,
const std::string &  prefix,
gps_type  start,
gps_type  stop,
gps_type  dT,
arch_type  type,
driver_type  driv = kUnknown 
)

Constructor.

Construct a frame location descriptor.

Parameters:
location Path to frame archive.
prefix Frame type string.
start Start GPS of first frame in series.
stop End GPS of last frame in series.
dT Time duration of all but the last frame.
type Archive level.
driv Driver type.

sends::frame_loc::~frame_loc ( void   ) 

Frame location destructor.

Destroy a frame location descriptor.


Member Function Documentation

frame_loc::arch_type sends::frame_loc::archive ( void   )  const [inline]

Get the archive level.

Get the data archive level for this frame location.

Returns:
Archive level.

frame_loc::driver_type sends::frame_loc::driver ( void   )  const [inline]

Get the driver type.

Get the driver type code for this frame location.

Returns:
Driver type code.

std::ostream& sends::frame_loc::dump ( std::ostream &  out  )  const

Dump the locateion.

Dump the location entry

Parameters:
out Output stream.
Returns:
Output stream reference.

frame_loc::gps_type sends::frame_loc::frame_end ( gps_type  t  )  const [inline]

Get the frame end time.

Get the end time of the frame containing the specified time.

Parameters:
t Time contained in frame.
Returns:
End time of frame.

References frame_start().

std::string sends::frame_loc::frame_path ( gps_type  gps  )  const

Get the frame path.

Get the frame path for frame containing specified GPS. The frame name is assumed to be of the form "<source>/<prefix>-<start>-<dt>.gwf". The generated frame path is tested for read access, and if it is not readable, an empty string is returned.

Parameters:
gps Time contained in frame.
Returns:
Frame path or emty string.

frame_loc::gps_type sends::frame_loc::frame_start ( gps_type  t  )  const [inline]

Get the frame start time.

Get the start time of the frame containing the specified time.

Parameters:
t Time contained in frame.
Returns:
Start time of frame.

Referenced by frame_end().

frame_loc::gps_type sends::frame_loc::gps_end ( void   )  const [inline]

Get the location end time.

Get the end time of data handled by this location.

Returns:
End time of data in location.

frame_loc::gps_type sends::frame_loc::gps_start ( void   )  const [inline]

Get the location start time.

Get the start time of data handled by this location.

Returns:
Start time of data in location.

bool sends::frame_loc::in_range ( gps_type  gps  )  const [inline]

Test if time is in range.

Test whether the specified gps is included in the valid time range for this location.

Parameters:
gps Time to be checked in GPS seconds.
Returns:
True if gps is in range coverd by frame_loc.

const std::string & sends::frame_loc::prefix ( void   )  const [inline]

Return the frame site and type string covered by this frame_loc.

Returns:
Frame prefix string.

frame_loc::gps_type sends::frame_loc::start ( void   )  const [inline]

Return the start time of the first frame in this location.

frame_loc::gps_type sends::frame_loc::stop ( void   )  const [inline]

Return the end time of the last frame in this location.


The documentation for this class was generated from the following file:

Generated on Tue Jun 10 12:18:12 2008 for SENDS by  doxygen 1.5.5