WXP C++ Library Version 6.74.9
Loading...
Searching...
No Matches
Public Member Functions | List of all members
WXP::RedbookFile Class Reference

This class reads in Redbook formatted data. More...

#include "../include/RedbookFile.h"

Public Member Functions

 RedbookFile ()
 
 RedbookFile (const char *file)
 
 ~RedbookFile ()
 
int open (const char *file)
 
int close ()
 
bool isOpen ()
 
int readHeader ()
 
int getPi ()
 
int getDate (Date &rdate)
 
int readPacket (RedbookPacket &pack)
 
int procPacket (RedbookPacket &pack)
 
int plotParam (RedbookPacket &pack, RedbookPlotParam &param)
 
int vector (RedbookPacket &pack, RedbookVector &vect)
 
int text (RedbookPacket &pack, RedbookText &text)
 

Detailed Description

This class reads in Redbook formatted data.

Author
Dan Vietor

Constructor & Destructor Documentation

◆ RedbookFile() [1/2]

RedbookFile::RedbookFile ( )

Constructor.

◆ RedbookFile() [2/2]

RedbookFile::RedbookFile ( const char *  filename)

Constructor. Opens file

Parameters
filenameFilename

References open().

◆ ~RedbookFile()

RedbookFile::~RedbookFile ( )

Destructor

References WXP::File::close().

Member Function Documentation

◆ close()

int RedbookFile::close ( )

Closes the flie

References WXP::File::close().

◆ getPi()

int RedbookFile::getPi ( )

Returns the projection indicator (1 or 2)

Referenced by WXP::RedbookPlot::getDomain().

◆ isOpen()

bool RedbookFile::isOpen ( )

Returns whether file is open

Referenced by WXP::RedbookPlot::draw(), and WXP::RedbookPlot::getDomain().

◆ open()

int RedbookFile::open ( const char *  filename)

Opens file

Parameters
filenameFile name

References WXP::FileTool::getModTime(), WXP::File::isOpen(), WXP::File::open(), and WXP::Date::set().

Referenced by RedbookFile().

◆ plotParam()

int RedbookFile::plotParam ( RedbookPacket pack,
RedbookPlotParam param 
)

Parse plot parameter data

Parameters
packInput packet data
Return values
paramOutput plot param data

References WXP::StrLib::copy(), and WXP::Wxp::outDebug().

Referenced by WXP::RedbookPlot::draw().

◆ procPacket()

int RedbookFile::procPacket ( RedbookPacket pack)

Processes packet data

Parameters
packPacket data

Referenced by WXP::RedbookPlot::draw().

◆ readHeader()

int RedbookFile::readHeader ( )

◆ readPacket()

int RedbookFile::readPacket ( RedbookPacket pack)

Reads in redbook packet

Parameters
packPacket data
Returns
1 if valid data, 0 if at end of file

References WXP::File::read().

Referenced by WXP::RedbookPlot::draw(), and readHeader().

◆ text()

int RedbookFile::text ( RedbookPacket pack,
RedbookText text 
)

Parse text data

Parameters
packPacket data
Return values
textOutput text data

References WXP::StrLib::copy(), WXP::Wxp::outDebug(), text(), WXP::Point::x, and WXP::Point::y.

Referenced by WXP::RedbookPlot::draw(), and text().

◆ vector()

int RedbookFile::vector ( RedbookPacket pack,
RedbookVector vect 
)

Parses vector data

Parameters
packPacket data
Return values
vectOutput vector data

References WXP::Points::add(), WXP::Points::clear(), WXP::RedbookVector::flag, WXP::Points::getX(), WXP::Points::getY(), WXP::RedbookVector::num, WXP::Wxp::outDebug(), and WXP::RedbookVector::pts.

Referenced by WXP::RedbookPlot::draw().


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