15 #ifndef BORNAGAIN_GUI_MODEL_DATA_REALDATAITEM_H
16 #define BORNAGAIN_GUI_MODEL_DATA_REALDATAITEM_H
36 friend class TestView;
39 static constexpr
auto P_INSTRUMENT_ID{
"Instrument Id"};
40 static constexpr
auto T_INTENSITY_DATA{
"Intensity data"};
41 static constexpr
auto T_NATIVE_DATA{
"Native user data axis"};
42 static constexpr
auto P_NATIVE_DATA_UNITS{
"Native user data units"};
45 static constexpr
auto M_TYPE{
"RealData"};
49 void initAsSpecularItem();
50 void initAsIntensityItem();
53 QString dataName()
const;
54 void setDataName(
const QString&
name);
67 void initNativeData();
68 QString nativeDataUnits()
const;
69 void setNativeDataUnits(
const QString& units);
70 void removeNativeData();
71 bool hasNativeData()
const;
72 const Datafield* nativeDatafield()
const;
73 void setNativeDatafield(Datafield* data);
75 void setDatafield(Datafield* data);
77 bool holdsDimensionalData()
const;
79 QString instrumentId()
const;
81 void unlinkFromInstrument();
84 std::vector<int> shape()
const;
86 bool isIntensityData()
const;
87 bool isSpecularData()
const;
89 bool hasImportErrors()
const;
95 void setNativeFileName(
const QString& filename);
96 QString nativeFileName()
const;
106 bool rotationAffectsSetup()
const;
109 void updateNonXMLDataFileNames();
115 void initDataItem(
size_t data_rank,
const QString& tag);
Defines class AbstractDataLoader.
Defines class SessionItem.
Abstract base class for all data loaders (classes to import real data).
Abstract base class for IntensityDataItem and SpecularDataItem. Owns one simulated data set of type D...
Carries information about loaded data.
Abstract base class for instrument-specific item classes.
Container holding various masks as children.
Provides access to experimental data, for display and fitting. Owns an AbstractDataLoader.
QModelIndex index() const
QByteArray m_importSettings
std::unique_ptr< AbstractDataLoader > m_dataLoader
void importContentsProcessed()
Base class for a GUI data item.
virtual void deserializeBinaryData(const QByteArray &data)
virtual QByteArray serializeBinaryData() const
SpecularDataItem * specularDataItem(SessionItem *parent)
Returns SpecularDataItem contained as a child in givent parent.
IntensityDataItem * intensityDataItem(SessionItem *parent)
Returns IntensityDataItem contained as a child in givent parent.
QString const & name(EShape k)