#include <Yahoo.h>
Public Slots | |
void | startDownload () |
void | fileDone (bool) |
void | timeoutError () |
void | newStock () |
void | methodChanged (int) |
void | allSymbolsChecked (bool) |
Public Member Functions | |
Yahoo () | |
virtual | ~Yahoo () |
void | update () |
QString | parseDate (QString &) |
void | parseHistory () |
void | parseQuote () |
void | loadSettings () |
void | saveSettings () |
void | printErrorList () |
void | cancelUpdate () |
void | parseFundamental () |
void | loadAllSymbols () |
void | createHistoryUrls (QString &) |
void | createAutoHistoryUrls (QString &, QString &) |
void | createQuoteUrls (QString &) |
void | createFundamentalUrls (QString &) |
void | buildGui () |
void | setMethod (QString) |
void | getExchange (QString &, QString &) |
Private Attributes | |
QStringList | symbolList |
QPtrList< Setting > | url |
Setting * | currentUrl |
QString | dataPath |
QStringList | fileList |
QStringList | errorList |
QStringList | monthList |
DbPlugin | plug |
Config | config |
FileButton * | list |
QCheckBox * | adjustment |
QDateEdit * | sdate |
QDateEdit * | edate |
QComboBox * | method |
QCheckBox * | allSymbols |
int | fileCount |
int | fileCounter |
Definition at line 35 of file Yahoo.h.
Yahoo::Yahoo | ( | ) |
Definition at line 40 of file Yahoo.cpp.
References buildGui(), config, currentUrl, dataPath, Config::DataPath, QuotePlugin::file, fileCount, fileCounter, fileDone(), Config::getData(), QuotePlugin::helpFile, Config::Home, loadSettings(), monthList, QuotePlugin::pluginName, QuotePlugin::signalGetFileDone(), QuotePlugin::signalTimeout(), timeoutError(), and url.
Yahoo::~Yahoo | ( | ) | [virtual] |
void Yahoo::update | ( | ) | [virtual] |
Reimplemented from QuotePlugin.
Definition at line 148 of file Yahoo.cpp.
References allSymbols, allSymbolsChecked(), DBBase::close(), createAutoHistoryUrls(), createFundamentalUrls(), createHistoryUrls(), createQuoteUrls(), currentUrl, dataPath, QuotePlugin::downloadComplete(), errorList, QuotePlugin::errorLoop, fileCount, method, plug, QuotePlugin::printStatusLogMessage(), startDownload(), symbolList, and url.
QString Yahoo::parseDate | ( | QString & | d | ) |
void Yahoo::parseHistory | ( | ) |
Definition at line 285 of file Yahoo.cpp.
References adjustment, QuotePlugin::chartIndex, DBBase::close(), DbPlugin::createNewStock(), currentUrl, QuotePlugin::data, dataPath, QuotePlugin::file, Bar::getClose(), Setting::getData(), Bar::getHigh(), DBIndex::getIndexItem(), Bar::getLow(), Bar::getOpen(), DBIndexItem::getSymbol(), Bar::getVolume(), DbPlugin::open(), parseDate(), plug, QuotePlugin::pluginName, QuotePlugin::printStatusLogMessage(), DbPlugin::setBar(), Bar::setClose(), Bar::setDate(), Bar::setHigh(), DBIndex::setIndexItem(), Bar::setLow(), Bar::setOpen(), DBIndexItem::setQuotePlugin(), DBIndexItem::setSymbol(), QuotePlugin::setTFloat(), DBIndexItem::setTitle(), Bar::setVolume(), QuotePlugin::signalWakeup(), QuotePlugin::stripJunk(), QuotePlugin::tfloat, and Bar::verify().
Referenced by fileDone().
void Yahoo::parseQuote | ( | ) |
Definition at line 452 of file Yahoo.cpp.
References QuotePlugin::chartIndex, DBBase::close(), DbPlugin::createNewStock(), currentUrl, QuotePlugin::data, dataPath, QuotePlugin::file, Setting::getData(), DBIndex::getIndexItem(), DBIndexItem::getSymbol(), DbPlugin::open(), plug, QuotePlugin::pluginName, QuotePlugin::printStatusLogMessage(), DbPlugin::setBar(), Bar::setClose(), Bar::setDate(), Bar::setHigh(), DBIndex::setIndexItem(), Bar::setLow(), Bar::setOpen(), DBIndexItem::setQuotePlugin(), DBIndexItem::setSymbol(), QuotePlugin::setTFloat(), DBIndexItem::setTitle(), Bar::setVolume(), QuotePlugin::signalWakeup(), QuotePlugin::stripJunk(), QuotePlugin::tfloat, and Bar::verify().
Referenced by fileDone().
void Yahoo::loadSettings | ( | ) |
Definition at line 639 of file Yahoo.cpp.
References adjustment, allSymbols, allSymbolsChecked(), QuotePlugin::retrySpin, setMethod(), and QuotePlugin::timeoutSpin.
Referenced by Yahoo().
void Yahoo::saveSettings | ( | ) |
Definition at line 663 of file Yahoo.cpp.
References adjustment, allSymbols, method, QuotePlugin::retrySpin, and QuotePlugin::timeoutSpin.
Referenced by ~Yahoo().
void Yahoo::printErrorList | ( | ) |
Definition at line 677 of file Yahoo.cpp.
References errorList, and QuotePlugin::printStatusLogMessage().
Referenced by fileDone(), and timeoutError().
void Yahoo::cancelUpdate | ( | ) |
Definition at line 687 of file Yahoo.cpp.
References QuotePlugin::downloadComplete(), QuotePlugin::op, QuotePlugin::printStatusLogMessage(), QuotePlugin::progressBar, QuotePlugin::stringCanceled, and QuotePlugin::timer.
void Yahoo::parseFundamental | ( | ) |
Definition at line 700 of file Yahoo.cpp.
References QuotePlugin::chartIndex, DBBase::close(), DbPlugin::createNewStock(), currentUrl, QuotePlugin::data, dataPath, Setting::getData(), DBIndex::getIndexItem(), Setting::getString(), DBIndexItem::getSymbol(), DBIndexItem::getTitle(), DbPlugin::open(), plug, QuotePlugin::pluginName, QuotePlugin::printStatusLogMessage(), Setting::setData(), DBIndex::setFundamentals(), DBIndex::setIndexItem(), DBIndexItem::setQuotePlugin(), DBIndexItem::setSymbol(), DBIndexItem::setTitle(), and QuotePlugin::signalWakeup().
Referenced by fileDone().
void Yahoo::loadAllSymbols | ( | ) |
Definition at line 861 of file Yahoo.cpp.
References dataPath, and symbolList.
Referenced by allSymbolsChecked().
void Yahoo::createHistoryUrls | ( | QString & | d | ) |
void Yahoo::createAutoHistoryUrls | ( | QString & | path, | |
QString & | d | |||
) |
Definition at line 959 of file Yahoo.cpp.
References QuotePlugin::chartIndex, DBBase::close(), Bar::getDate(), Bar::getEmptyFlag(), DBIndex::getIndexItem(), DbPlugin::getLastBar(), DBIndexItem::getQuotePlugin(), DbPlugin::open(), plug, QuotePlugin::pluginName, Bar::setDate(), DBIndex::setIndexItem(), DBIndexItem::setQuotePlugin(), and url.
Referenced by update().
void Yahoo::createQuoteUrls | ( | QString & | d | ) |
void Yahoo::createFundamentalUrls | ( | QString & | d | ) |
void Yahoo::buildGui | ( | ) |
Reimplemented from QuotePlugin.
Definition at line 86 of file Yahoo.cpp.
References Toolbar::addButton(), adjustment, allSymbols, allSymbolsChecked(), QuotePlugin::baseWidget, config, dataPath, Config::DataPath, edate, Toolbar::getButton(), Config::getData(), QuotePlugin::grid, list, method, methodChanged(), newStock(), sdate, and QuotePlugin::toolbar.
Referenced by Yahoo().
void Yahoo::setMethod | ( | QString | d | ) |
Definition at line 1166 of file Yahoo.cpp.
References method, and methodChanged().
Referenced by loadSettings().
void Yahoo::getExchange | ( | QString & | ext, | |
QString & | exchange | |||
) |
Definition at line 1246 of file Yahoo.cpp.
References Exchange::ASSE, Exchange::AXSE, Exchange::BASE, Exchange::BCSE, Exchange::BESE, Exchange::BISE, Exchange::BMSE, Exchange::BOSE, Exchange::COSE, Exchange::DUSE, Exchange::FSE, Exchange::HASE, Exchange::HKSE, Exchange::HMSE, Exchange::JKSE, Exchange::KOSDAQ, Exchange::KSSE, Exchange::LSE, Exchange::MASE, Exchange::MCCATS, Exchange::MFIM, Exchange::MISE, Exchange::MUSE, Exchange::MXSE, Exchange::NSEOI, Exchange::NZSE, Exchange::OLSE, Exchange::PASE, Exchange::SASE, Exchange::SGSE, Exchange::SISE, Exchange::SSSE, Exchange::STSE, Exchange::SWE, Exchange::SZSE, Exchange::TASE, Exchange::TOSE, Exchange::TSXVE, Exchange::TWOOTC, Exchange::TWSE, Exchange::VASE, and Exchange::XETRA.
Referenced by newStock().
void Yahoo::startDownload | ( | ) | [slot] |
Definition at line 205 of file Yahoo.cpp.
References currentUrl, fileCount, fileCounter, Setting::getData(), QuotePlugin::getFile(), and QuotePlugin::progressBar.
Referenced by fileDone(), timeoutError(), and update().
void Yahoo::fileDone | ( | bool | d | ) | [slot] |
Definition at line 215 of file Yahoo.cpp.
References currentUrl, QuotePlugin::downloadComplete(), QuotePlugin::errorLoop, method, parseFundamental(), parseHistory(), parseQuote(), printErrorList(), QuotePlugin::printStatusLogMessage(), QuotePlugin::progressBar, startDownload(), QuotePlugin::stringDone, and url.
Referenced by Yahoo().
void Yahoo::timeoutError | ( | ) | [slot] |
Definition at line 252 of file Yahoo.cpp.
References currentUrl, QuotePlugin::downloadComplete(), errorList, QuotePlugin::errorLoop, Setting::getData(), printErrorList(), QuotePlugin::printStatusLogMessage(), QuotePlugin::retrySpin, startDownload(), QuotePlugin::stringDone, and url.
Referenced by Yahoo().
void Yahoo::newStock | ( | ) | [slot] |
Definition at line 1073 of file Yahoo.cpp.
References QuotePlugin::chartIndex, DBBase::close(), config, DbPlugin::createNewStock(), dataPath, Config::DataPath, Config::getData(), getExchange(), DBIndex::getIndexItem(), DbPlugin::open(), plug, DBIndexItem::setExchange(), and DBIndex::setIndexItem().
Referenced by buildGui().
void Yahoo::methodChanged | ( | int | d | ) | [slot] |
Definition at line 1196 of file Yahoo.cpp.
References adjustment, edate, and sdate.
Referenced by buildGui(), and setMethod().
void Yahoo::allSymbolsChecked | ( | bool | d | ) | [slot] |
Definition at line 1225 of file Yahoo.cpp.
References fileList, FileButton::getFile(), list, loadAllSymbols(), and symbolList.
Referenced by buildGui(), loadSettings(), and update().
QStringList Yahoo::symbolList [private] |
Definition at line 69 of file Yahoo.h.
Referenced by allSymbolsChecked(), loadAllSymbols(), and update().
QPtrList<Setting> Yahoo::url [private] |
Definition at line 70 of file Yahoo.h.
Referenced by createAutoHistoryUrls(), createFundamentalUrls(), createHistoryUrls(), createQuoteUrls(), fileDone(), timeoutError(), update(), and Yahoo().
Setting* Yahoo::currentUrl [private] |
Definition at line 71 of file Yahoo.h.
Referenced by fileDone(), parseFundamental(), parseHistory(), parseQuote(), startDownload(), timeoutError(), update(), and Yahoo().
QString Yahoo::dataPath [private] |
Definition at line 72 of file Yahoo.h.
Referenced by buildGui(), loadAllSymbols(), newStock(), parseFundamental(), parseHistory(), parseQuote(), update(), and Yahoo().
QStringList Yahoo::fileList [private] |
QStringList Yahoo::errorList [private] |
Definition at line 74 of file Yahoo.h.
Referenced by printErrorList(), timeoutError(), and update().
QStringList Yahoo::monthList [private] |
DbPlugin Yahoo::plug [private] |
Definition at line 76 of file Yahoo.h.
Referenced by createAutoHistoryUrls(), newStock(), parseFundamental(), parseHistory(), parseQuote(), update(), and ~Yahoo().
Config Yahoo::config [private] |
FileButton* Yahoo::list [private] |
QCheckBox* Yahoo::adjustment [private] |
Definition at line 79 of file Yahoo.h.
Referenced by buildGui(), loadSettings(), methodChanged(), parseHistory(), and saveSettings().
QDateEdit* Yahoo::sdate [private] |
Definition at line 80 of file Yahoo.h.
Referenced by buildGui(), createHistoryUrls(), and methodChanged().
QDateEdit* Yahoo::edate [private] |
Definition at line 81 of file Yahoo.h.
Referenced by buildGui(), createHistoryUrls(), and methodChanged().
QComboBox* Yahoo::method [private] |
Definition at line 82 of file Yahoo.h.
Referenced by buildGui(), fileDone(), saveSettings(), setMethod(), and update().
QCheckBox* Yahoo::allSymbols [private] |
Definition at line 83 of file Yahoo.h.
Referenced by buildGui(), loadSettings(), saveSettings(), and update().
int Yahoo::fileCount [private] |
int Yahoo::fileCounter [private] |