#include <resulttospectrum.h>
Public Slots | |
void | removeAllPaths () |
Removes all paths. | |
AbstractSpectrumModel * | spectrum (QString name) |
Access the created SpectrumModels by name. | |
QStringList | spectra () const |
returns a list of the current spectra | |
void | addPath (QString xml) |
Create path and spectrum by XML. | |
QStringList | guiActions () const |
name and actions for the gui | |
void | guiExecAction (QString, NSCore::GuiServer_Interface *) |
name and actions for the gui | |
QVariant | guiIdentifier (int) const |
name and actions for the gui | |
Signals | |
void | newSpectrum (AbstractSpectrumModel *) |
A new spectrum is created. | |
void | data (NSCore::AcqisitionDataSet) |
Send the data to the sub-threads. | |
Public Member Functions | |
ResultsToSpectrum (QObject *=0) | |
constructor | |
~ResultsToSpectrum () | |
destructor | |
Private Member Functions | |
bool | dataArrived (NSCore::AcqisitionDataSet &) |
Data arrived! | |
QString | debug () const |
debug for NSCore::QTreeItem | |
QDomNode | saveToXML (QDomDocument doc) |
Store the information of this element into a new QDomElement. | |
bool | restoreFromXML (QDomNode) |
Restore the state of this element from the given QDomNode. | |
bool | createFromXML (QDomNode) |
Create childs from XML. | |
Private Attributes | |
QList< NSCore::Thread_Template < ResultThread > * > | _threads |
int | _threadcycler |
This class sends results into a SpectrumModel for further analysis and storage.
It will also be expanded to store into other models as well ( network-send, sql-database, etc ).
The results to be written into the storage can be defined by an own language containing result,add,neg,smb,precision. Use and explore it online by accessing this objects via TreeItemModel and QTreeView...
ResultsToSpectrum::ResultsToSpectrum | ( | QObject * | = 0 |
) |
constructor
ResultsToSpectrum::~ResultsToSpectrum | ( | ) |
destructor
void ResultsToSpectrum::removeAllPaths | ( | ) | [slot] |
Removes all paths.
AbstractSpectrumModel* ResultsToSpectrum::spectrum | ( | QString | name | ) | [slot] |
Access the created SpectrumModels by name.
QStringList ResultsToSpectrum::spectra | ( | ) | const [slot] |
returns a list of the current spectra
void ResultsToSpectrum::addPath | ( | QString | xml | ) | [slot] |
Create path and spectrum by XML.
QStringList ResultsToSpectrum::guiActions | ( | ) | const [inline, virtual, slot] |
name and actions for the gui
Reimplemented from NSCore::QTreeItem.
References NSCore::QTreeItem::guiActions().
void ResultsToSpectrum::guiExecAction | ( | QString | , | |
NSCore::GuiServer_Interface * | ||||
) | [virtual, slot] |
QVariant ResultsToSpectrum::guiIdentifier | ( | int | ) | const [virtual, slot] |
void ResultsToSpectrum::newSpectrum | ( | AbstractSpectrumModel * | ) | [signal] |
A new spectrum is created.
void ResultsToSpectrum::data | ( | NSCore::AcqisitionDataSet | ) | [signal] |
Send the data to the sub-threads.
bool ResultsToSpectrum::dataArrived | ( | NSCore::AcqisitionDataSet & | ) | [private, virtual] |
Data arrived!
Subclass this function to handle the data. Return true when the data should be sent to the next in the chain. Otherwise it gets deleted.
Implements NSCore::DataSetChainMember.
QString ResultsToSpectrum::debug | ( | ) | const [inline, private, virtual] |
QDomNode ResultsToSpectrum::saveToXML | ( | QDomDocument | doc | ) | [inline, private, virtual] |
Store the information of this element into a new QDomElement.
This function is only to save the state of this element, all the recursive stuff will be done by toXml().
doc | The QDomDocument to use for creation of the element |
Implements NSCore::QTreeItem.
bool ResultsToSpectrum::restoreFromXML | ( | QDomNode | node | ) | [private, virtual] |
Restore the state of this element from the given QDomNode.
You don't have to do the recursive stuff here, that is handled in fromXml() for you. Only the things done in saveToXML need/can be restored here.
If you succeeded and want the childs to be restored too, return true.
node | The QDomNode to restore from |
Implements NSCore::QTreeItem.
bool ResultsToSpectrum::createFromXML | ( | QDomNode | node | ) | [private, virtual] |
Create childs from XML.
On fromXml() this gets called after successfull return from restoreFromXML(). If you want to create childs of this item from the childs of the QDomNode given, you can do so.
The return value defines whether fromXml will be called on the childs for the child-xml-items.
The default implementation returns true, so the child items get a chance to restore their state too.
node | The QDomNode to restore from |
Reimplemented from NSCore::QTreeItem.
QList< NSCore::Thread_Template<ResultThread>* > ResultsToSpectrum::_threads [private] |
int ResultsToSpectrum::_threadcycler [private] |