//  ************************************************************************************************
//
//  BornAgain: simulate and fit reflection and scattering
//
//! @file      Device/Resolution/ResolutionFunction2D.h
//! @brief     Defines class interface ResolutionFunction2D.
//!
//! @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_DEVICE_RESOLUTION_IRESOLUTIONFUNCTION2D_H
#define BORNAGAIN_DEVICE_RESOLUTION_IRESOLUTIONFUNCTION2D_H

#include "Base/Type/Cloneable.h"

//! Interface providing two-dimensional resolution function.

class ResolutionFunction2D : public Cloneable {
public:
    ResolutionFunction2D() = default;

    virtual ~ResolutionFunction2D() = default;

#ifndef SWIG
    ResolutionFunction2D* clone() const override = 0;

    virtual void validate() const {}

    virtual double evaluateCDF(double x, double y) const = 0;

protected:
    mutable bool m_validated{false};
#endif // SWIG
};

#endif // BORNAGAIN_DEVICE_RESOLUTION_IRESOLUTIONFUNCTION2D_H
