/*****************************************************************//**
 * \file   RestrictedMasterProblemInitializer.h
 * \brief  Interface of chain of responsibility design pattern dealing with the initialization method.
 *
 * \author talmefta
 * \date   May 2022
 *********************************************************************/
#ifndef RESTRICTEDMASTERPROBLEMINITIALIZER_H
#define RESTRICTEDMASTERPROBLEMINITIALIZER_H

#include "Header.h"

 /**
  * \class RestrictedMasterProblemInitializer
 * \brief  Interface of chain of responsibility design pattern dealing with the initialization method.
  */

template<class Instance, class ColumnsType>
class RestrictedMasterProblemInitializer {

public:
    /**
     * Virtual destructor.
     *
     */
    virtual ~RestrictedMasterProblemInitializer() {}

    /**
    * \brief Sets the next algorithm operator in the chain of responsibility in the base handler class (here, the RestrictedMasterProblemInitializerAbstract).
    * \param _next_algorithm : RestrictedMasterProblemInitializer<ColumnsType>*
    * \return _next_algorithm to let us link the algorithms operators in a convenient way (algorithm1->set_next_algorithm(handler2)->set_next_algorithm(handler3)) : RestrictedMasterProblemInitializer<Instance, ColumnsType>*.
    */
    virtual RestrictedMasterProblemInitializer<Instance, ColumnsType>* set_next_algorithm(RestrictedMasterProblemInitializer<Instance, ColumnsType>* _next_algorithm) = 0;
    /**
     * Initilize the restricted master problem.
     * \details This method has to be implemented in the inherent classes.
     * \param request : string
     */
    virtual ColumnsType initialize(const string& request) = 0;

    virtual RestrictedMasterProblemInitializer<Instance, ColumnsType>* get_next_algorithm() = 0;

    /**
     * Get method of member cost that will be in the abstract class of initlizer.
     * 
     * \return cost : const double&
     */
    virtual const double& get_cost() const = 0;
};

#endif //RESTRICTEDMASTERPROBLEMINITIALIZER_H