// __author__ = Juan Carlos De Abreu (jcabreur@gmail.com)

#ifndef DATA_IF_H__
#define DATA_IF_H__
 
#include "../DataTypes/Data.h"

BEGIN_TEG_NAMESPACE();

class DataIf : public IData {
public:
	// Attributes
	SmartPointer<IData> cond;
	std::vector<SmartPointer<IData>> inst;	// Instructions
	SmartPointer<IData> elseCond; 

	// Constructors
	DataIf(SmartPointer<IData> cond_, std::vector<SmartPointer<IData>> inst_, SmartPointer<IData> elseCond_)
		: IData(DATA_IF), cond(cond_), inst(inst_), elseCond(elseCond_) { }
	~DataIf() { }

	// Methods
	void print() {}

	AUTO_SIZE();

	SmartPointer<IData> resolve(std::map<std::string, SmartPointer<IData>>& variables);
};

END_TEG_NAMESPACE();

#endif  // DATA_IF_H__
