// XmlProjectSettings_Atl.h
//

#if !defined (_XMLPROJECTSETTINGS_ATL_H_)
#define _XMLPROJECTSETTINGS_ATL_H_

#include <string>
#include "XmlSerializable.h"
#include "XmlProjectPostGen.h"

using namespace std;

class CXmlProjectSettings_Atl: public CXmlSerializable
{
public:
	CXmlProjectSettings_Atl();
	virtual ~CXmlProjectSettings_Atl();

	// implementation of CXmlSerializable
public:
	virtual bool BuildFromXml(IXMLDOMNode* node);
	virtual bool AppendToDOMDocument(IXMLDOMDocument2* xmlDoc, IXMLDOMElement* parentElement);	
	
	// get/set
	//
	cmString GetGenerationPath() const;
	void SetGenerationPath(const cmString& generationPath);

	cmString GetClassPrefix() const;
	void SetClassPrefix(const cmString& classPrefix);

	cmString GetTypeLibraryName() const;
	void SetTypeLibraryName(const cmString& typeLibraryName);

	cmString GetTypeLibraryGuid() const;
	void SetTypeLibraryGuid(const cmString& guid);

	cmString GetMainDialogClassGuid() const;
	void SetMainDialogClassGuid(const cmString& guid);

	cmString GetMainDialogInterfaceGuid() const;
	void SetMainDialogInterfaceGuid(const cmString& guid);

	cmString GetFormPrefix() const;
	void SetFormPrefix(const cmString& formPrefix);

	cmString GetPostBuildPath() const;
	void SetPostBuildPath(const cmString& postBuildPath);

	cmString GetDllFileNamePrefix() const;
	void SetDllFileNamePrefix(const cmString& prefix);

	bool GetTestPrjGenerationEnabled() const;
	void SetTestPrjGenerationEnabled(bool testPrjGenerationEnabled);

	bool GetGUIGenerationEnabled() const;
	void SetGUIGenerationEnabled(bool GUIGenerationEnabled);

	int GetResourcesOffset() const;
	void SetResourcesOffset(int value);

	//defaultTreeIcons As New clsTreeIcons ' contiene i nomi delle icone utilizzate per default
	bool GetDeleteExistingFiles() const;
	void SetDeleteExistingFiles(const bool deleteExistingFiles);

	bool GetEnabled() const;
	void SetEnabled(bool enabled);

	static cmString GetXmlNodeName(){return _T("ProjectSettings_Atl");}

	void SetDefaults();
	void Clear();

	CXmlProjectPostGen* GetPostGenerationStep();

protected:



	bool enabled_;						// C++ Code Generation enable
	cmString generationPath_;				// Path of generated files
	cmString classPrefix_;				// prefix used to name each class (ie. :  className = MyClass , classPrefix = "cfg_" -> generates "cfg_MyClass")
	cmString formPrefix_;					// prefisso utilizzato per nominare i form generati per l'editor della configurazione
	cmString postBuildPath_;				// destinazione dove la dll viene copiata dopo la compilazione
	cmString typeLibraryName_;			// Type library name for idl generated file
	cmString typeLibraryGuid_;			// guid used for typelibrary
	cmString mainDialogClassGuid_;		// 
	cmString mainDialogInterfaceGuid_;
	cmString dllFileNamePrefix_;
	bool testPrjGenerationEnabled_;		// specifica se deve essere generato il progetto di test
	bool guiGenerationEnabled_;			// specifica se devono essere generati i file relativi alla gestione grafica della configurazione
	bool deleteExistingFiles_;			// indica se prima della generazione dei file è necessario cancellare i file preesistenti
	int resourcesOffset_;				// icon resource offset used in resource.h

	CXmlProjectPostGen postGen_;
};
	
#endif //!defined (_XMLPROJECTSETTINGS_ATL_H_)