|
WXP C++ Library Version 6.74.9
|
This class plots severe weather watch boxes. More...
#include "../include/WatchPlot.h"
Public Member Functions | |
| WatchPlot () | |
| WatchPlot (const char *param) | |
| int | init () |
| int | setParam (const char *str) |
| int | setFile () |
| int | setInput (const char *type) |
| int | setHour (const char *str) |
| int | setNameConv (const char *type) |
| int | setFilename () |
| int | setFilename (const char *str) |
| int | setFilename (Date &date) |
| int | setFilename (Date &date, const char *param) |
| int | setForeTime (const char *fore) |
| int | getDate (Date &date) |
| int | getInitDate (Date &date) |
| int | getDateOffset () |
| int | getLoopType () |
| int | getNumFrames () |
| int | getDomain (Domain &domain) |
| int | setScale (float val) |
| int | setTimezone (const char *str) |
| int | setShadow (int val) |
| int | setValidDate (const char *str) |
| int | setValidDate (Date &date) |
| int | setColorTable (const char *str) |
| int | setColor (const char *str) |
| int | setMap (bool val) |
| int | getSync () |
| int | readFile (Filename &filename) |
| int | readFile (const char *filename, Date &date) |
| int | draw (Plot &plot) |
| void | callback (const char *ev_str, const char *ev_data, const void *data) |
| int | print () |
Additional Inherited Members | |
| Static Public Attributes inherited from WXP::Drawing | |
| static const int | LOOP_NONE = 0 |
| static const int | LOOP_DATE = 1 |
| static const int | LOOP_FORE = 2 |
This class plots severe weather watch boxes.
| WatchPlot::WatchPlot | ( | ) |
Constructor
References init().
| WatchPlot::WatchPlot | ( | const char * | param | ) |
|
virtual |
Sets the callback for processing data from display
| ev_str | The event type |
| ev_data | The event data such as cursor location |
| data | The user defined data attached to event |
Implements WXP::Listener.
|
virtual |
Plots the watch data
| plot | Plot object |
Implements WXP::Drawing.
References WXP::Points::add(), WXP::Plot::addLabel(), WXP::WatchData::CANCELLED, WXP::Wxp::checkMessage(), WXP::Points::clear(), WXP::DateTool::createLabel(), WXP::MapPlot::draw(), WXP::Plot::drawFill(), WXP::Plot::drawLine(), WXP::Plot::drawText(), WXP::WatchData::ENDED, WXP::Points::getCenter(), WXP::Strings::getString(), WXP::Const::MISS, WXP::Point::offset(), WXP::Wxp::outMessage(), WXP::WatchData::PENDING, WXP::ColorFile::read(), readFile(), WXP::WatchData::REPLACED, WXP::Plot::setColorMap(), WXP::Plot::setFill(), WXP::Plot::setFillStyle(), WXP::Plot::setLine(), WXP::Plot::setText(), WXP::Plot::setTextColor(), WXP::WatchData::SEVERE, WXP::WatchData::TEST, and WXP::WatchData::TORNADO.
|
virtual |
Gets the date information from the input file
| date | The file date |
Implements WXP::Drawing.
|
virtual |
Gets the date offset from name convention for loops
Implements WXP::Drawing.
|
virtual |
Gets the default domain
| domain | The domain |
Implements WXP::Drawing.
References WXP::DomainTool::set().
|
virtual |
|
virtual |
Returns the default loop type
Implements WXP::Drawing.
References WXP::Drawing::LOOP_DATE.
|
virtual |
|
inlinevirtual |
Specifies whether object is a time sync
Implements WXP::Drawing.
|
virtual |
Initializes the object
Implements WXP::Drawing.
References setColor(), setFile(), setInput(), setNameConv(), setParam(), setScale(), and setTimezone().
Referenced by WatchPlot(), and WatchPlot().
|
virtual |
Print object parameters
Implements WXP::Drawing.
| int WatchPlot::readFile | ( | Filename & | filename | ) |
Reads the watch file and saves watch data
| filename | Filename to decode |
References WXP::WatchData::CANCELLED, WXP::WatchFile::close(), WXP::WatchData::ENDED, WXP::Date::getSeconds(), WXP::WatchFile::isOpen(), WXP::Const::MISS, WXP::WatchData::num, WXP::Wxp::outMessage(), WXP::WatchData::PENDING, WXP::WatchFile::read(), and WXP::WatchData::REPLACED.
Referenced by draw().
| int WatchPlot::setColor | ( | const char * | str | ) |
| int WatchPlot::setColorTable | ( | const char * | str | ) |
|
virtual |
Sets up the file parameters
Implements WXP::Drawing.
References setHour(), setInput(), and setNameConv().
Referenced by init().
|
virtual |
Sets the input file name
Implements WXP::Drawing.
|
virtual |
|
virtual |
Sets the input file date. The file name is derived using name convention
| date | The file date |
Implements WXP::Drawing.
|
virtual |
Sets the input file date with parameters. This is passed to the name convention to set file name
| date | The file date |
| param | The name convention parameters |
Implements WXP::Drawing.
|
inlinevirtual |
Sets the forecast time (ignored)
Implements WXP::Drawing.
| int WatchPlot::setHour | ( | const char * | str | ) |
|
virtual |
|
inline |
Sets whether object is to draw map or not
|
virtual |
|
virtual |
Sets the class parameters
| str | The parameters ct=file - Color table file co=cs,ct,cl - Colors for severe, tornado and text labeling nolabel - Don't label watch boxes slabel - Simple watch labels sh=## - Drop shadow width vdate=date - Valid date tz=zone - Time zone for labels sc=scale - Scale factor for text fill=pat - Fill pattern |
Implements WXP::Drawing.
References WXP::Strings::equal(), WXP::Strings::getFloat(), WXP::Strings::getInt(), WXP::Strings::getNum(), WXP::Strings::getString(), WXP::Strings::getStringAfter(), setColor(), setColorTable(), setScale(), setShadow(), setTimezone(), and setValidDate().
Referenced by init(), and WatchPlot().
| int WatchPlot::setScale | ( | float | val | ) |
| int WatchPlot::setShadow | ( | int | val | ) |
| int WatchPlot::setTimezone | ( | const char * | str | ) |
| int WatchPlot::setValidDate | ( | const char * | str | ) |
Sets the valid date for which watches will be displayed
| str | Date (yyyymmddhhnn) |
Referenced by setParam().
| int WatchPlot::setValidDate | ( | Date & | rdate | ) |
Sets the valid date for which watches will be displayed
| rdate | Date |