/** @file deletable.h
*	template for adding a DeleteThis() to a base class that doesn't have one
*	@author Chris Burns (cburns@ea.com)
*
*	Core Technology UI
*	(c) 2012 Electronic Arts Inc.
*/

#ifndef EABASETYPESMESSAGE_DELETABLE_H_
#define EABASETYPESMESSAGE_DELETABLE_H_

namespace EA
{
namespace Types
{
	/*! @class	Deletable deletable.h "ux_base/deletable.h"
	*	@brief	Mixin so that you can use a refcounting implementation
	*			with a base class that doesn't have DeleteThis() (like EA::Messaging::IMessageRC)
	*/
	template<typename Base>
	class Deletable : public Base
	{
	protected:

		/*!
		*	Delete this object
		*/
		virtual void DeleteThis() = 0;
	};
}
}

#endif /* EABASETYPESMESSAGE_DELETABLE_H_ */
