/*
 * SPDX-FileCopyrightText: 2025 Copyright contributors to the cppTango project
 *
 * SPDX-License-Identifier: LGPL-3.0-or-later
 */
/*----- PROTECTED REGION ID(DummyClassClass.h) ENABLED START -----*/
/* clang-format on */

#ifndef TANGO_TEST_DUMMYCLASS_DUMMYCLASSCLASS_H
#define TANGO_TEST_DUMMYCLASS_DUMMYCLASSCLASS_H

#include "DummyClass.h"

#include <tango/tango.h>

/* clang-format off */
/*----- PROTECTED REGION END -----*/	//	DummyClassClass.h


namespace DummyClass_ns
{
/*----- PROTECTED REGION ID(DummyClassClass::classes for dynamic creation) ENABLED START -----*/
/* clang-format on */

/* clang-format off */
/*----- PROTECTED REGION END -----*/	//	DummyClassClass::classes for dynamic creation

/**
 *	The DummyClassClass singleton definition
 */

#ifdef _TG_WINDOWS_
class __declspec(dllexport)  DummyClassClass : public Tango::DeviceClass
#else
class DummyClassClass : public Tango::DeviceClass
#endif
{
	/*----- PROTECTED REGION ID(DummyClassClass::Additional DServer data members) ENABLED START -----*/
    /* clang-format on */
    //	Add your own code
    /* clang-format off */
	/*----- PROTECTED REGION END -----*/	//	DummyClassClass::Additional DServer data members

	public:
		//	write class properties data members
		Tango::DbData	cl_prop;
		Tango::DbData	cl_def_prop;
		Tango::DbData	dev_def_prop;
		//	Method prototypes
		static DummyClassClass *init(const char *);
		static DummyClassClass *instance();
		~DummyClassClass();
		Tango::DbDatum	get_class_property(std::string &);
		Tango::DbDatum	get_default_device_property(std::string &);
		Tango::DbDatum	get_default_class_property(std::string &);

	protected:
		DummyClassClass(std::string &);
		static DummyClassClass *_instance;
		void command_factory();
		void attribute_factory(std::vector<Tango::Attr *> &);
		void pipe_factory();
		void write_class_property();
		void set_default_property();
		void get_class_property();
		std::string get_cvstag();
		std::string get_cvsroot();

	private:
		void device_factory(TANGO_UNUSED(const Tango::DevVarStringArray *));
		void create_static_attribute_list(std::vector<Tango::Attr *> &);
		void erase_dynamic_attributes(const Tango::DevVarStringArray *,std::vector<Tango::Attr *> &);
		std::vector<std::string>	defaultAttList;
		Tango::Attr *get_attr_object_by_name(std::vector<Tango::Attr *> &att_list, std::string attname);
};

}	//	End of namespace

#endif   //	DummyClass_H
