Skip to content
Snippets Groups Projects
ToDomain.h 1.82 KiB
//  ************************************************************************************************
//
//  BornAgain: simulate and fit reflection and scattering
//
//! @file      GUI/Model/To/ToDomain.h
//! @brief     Defines namespace GUI::Transform::ToDomain
//!
//! @homepage  http://www.bornagainproject.org
//! @license   GNU General Public License v3 or higher (see COPYING)
//! @copyright Forschungszentrum Jülich GmbH 2018
//! @authors   Scientific Computing Group at MLZ (see CITATION, AUTHORS)
//
//  ************************************************************************************************

#ifndef BORNAGAIN_GUI_MODEL_TO_TODOMAIN_H
#define BORNAGAIN_GUI_MODEL_TO_TODOMAIN_H

#include "Device/Instrument/Instrument.h"
#include "Param/Distrib/Distributions.h" // for IDistribution1D
#include "Param/Distrib/ParameterDistribution.h"
#include "Sample/Aggregate/IInterference.h"
#include "Sample/Aggregate/ParticleLayout.h"
#include "Sample/Interface/LayerRoughness.h"
#include "Sample/Multilayer/Layer.h"
#include "Sample/Multilayer/MultiLayer.h"
#include "Sample/Particle/IParticle.h"
#include <memory>
#include <variant>

class LayerItem;
class MultiLayerItem;
class ParticleLayoutItem;
class SessionItem;
class LayerZeroRoughnessItem;
class LayerBasicRoughnessItem;

namespace GUI::Transform::ToDomain {

std::unique_ptr<IParticle> createIParticle(const SessionItem& item);
std::unique_ptr<Layer> createLayer(const LayerItem& item, bool isFirstOrLastLayer);
std::unique_ptr<LayerRoughness> createLayerRoughness(
    const std::variant<LayerZeroRoughnessItem*, LayerBasicRoughnessItem*>& roughness);
std::unique_ptr<MultiLayer> createMultiLayer(const MultiLayerItem& item);
std::unique_ptr<ParticleLayout> createParticleLayout(const ParticleLayoutItem& item);

} // namespace GUI::Transform::ToDomain

#endif // BORNAGAIN_GUI_MODEL_TO_TODOMAIN_H