Diana Software
pkg
guisession
QGuiScatterPlot.cc
Go to the documentation of this file.
1
#include "
QGuiScatterPlot.hh
"
2
#include <iostream>
3
#include <sstream>
4
5
using
std::endl;
6
using
std::string;
7
using
std::stringstream;
8
using
std::vector;
9
10
QGuiScatterPlot::QGuiScatterPlot
() :
QGuiSessionItem
()
11
{
12
}
13
14
QGuiScatterPlot::~QGuiScatterPlot
()
15
{
16
}
17
18
string
QGuiScatterPlot::Dump
()
const
19
{
20
stringstream scatterPlotDump;
21
scatterPlotDump <<
SCATTER_PLOT_KEY
<< endl;
22
if
(
fName
!=
""
) {
23
scatterPlotDump <<
NAME_KEY
<<
" "
<<
fName
<< endl;
24
}
25
if
(
fXVariable
!=
""
) {
26
scatterPlotDump <<
X_VARIABLE_KEY
<<
" "
<<
fXVariable
<< endl;
27
}
28
if
(
fYVariable
!=
""
) {
29
scatterPlotDump <<
Y_VARIABLE_KEY
<<
" "
<<
fYVariable
<< endl;
30
}
31
for
(vector<string>::const_iterator iter =
fCuts
.begin();
32
iter !=
fCuts
.end();
33
++iter) {
34
scatterPlotDump <<
CUT_KEY
<<
" "
<< *iter << endl;
35
}
36
return
scatterPlotDump.str();
37
}
CUT_KEY
#define CUT_KEY
Definition:
QGTextFileKeys.hh:9
Y_VARIABLE_KEY
#define Y_VARIABLE_KEY
Definition:
QGTextFileKeys.hh:36
SCATTER_PLOT_KEY
#define SCATTER_PLOT_KEY
Definition:
QGTextFileKeys.hh:31
NAME_KEY
#define NAME_KEY
Definition:
QGTextFileKeys.hh:25
X_VARIABLE_KEY
#define X_VARIABLE_KEY
Definition:
QGTextFileKeys.hh:34
QGuiScatterPlot.hh
QGuiScatterPlot::~QGuiScatterPlot
~QGuiScatterPlot()
Default destructor.
Definition:
QGuiScatterPlot.cc:14
QGuiScatterPlot::QGuiScatterPlot
QGuiScatterPlot()
Default constructor.
Definition:
QGuiScatterPlot.cc:10
QGuiScatterPlot::Dump
std::string Dump() const
Dump to string to write to session file.
Definition:
QGuiScatterPlot.cc:18
QGuiScatterPlot::fCuts
std::vector< std::string > fCuts
Cuts.
Definition:
QGuiScatterPlot.hh:34
QGuiScatterPlot::fYVariable
std::string fYVariable
y-variable
Definition:
QGuiScatterPlot.hh:32
QGuiScatterPlot::fXVariable
std::string fXVariable
x-variable
Definition:
QGuiScatterPlot.hh:30
QGuiSessionItem
Base class for GUI session objects like histograms and scatter plots.
Definition:
QGuiSessionItem.hh:14
QGuiSessionItem::fName
std::string fName
Name.
Definition:
QGuiSessionItem.hh:30
Generated by
1.9.1