function GHClass(_className,...)
	local obj,className;
	local parent = _parent;
	obj = CreateFrame("Frame"); -- making it a frame might create more memory use?
	
	local interfaces = {...}
	className = _className;
		
	obj.GetType = function(self)
		return className;
	end
	
	obj.IsClass = function(self,str)
		assert(type(str)=="string","Useage: IsClass(str)");
		return self:GetType() == str;
	end;
	
	obj.IsSameClass = function(self,other)
		assert(type(other)=="table","IsSameClass. Other class is not a table");
		if other.GetType then
			return self:GetType() == other:GetType()
		end
	end
	
	obj.InheritsInterface = function(self,_interface)
		for _,int in pairs(interfaces) do
			if (int == _interface) then
				return true;
			end
		end	
		return false;
	end
	
	obj.Dispose = function(self) -- Standard dispose func. This can be overwritten
		wipe(self);
	end
	
	return obj;
end

function GHCheck(name,expected,acual)
	if not(type(expected)=="table" and type(acual)=="table") then
		error("GHCheck used incorrectly in code. Useage: GHCheck(table,table) got "..type(expected).." "..type(acual),2)
	end
	
	local passed = true;
	local acualRes = {};
	for i,expType in pairs(expected) do
		expType = expType:lower();
		local acualType = type(acual[i]):lower();
		if not(expType == "any") and not(string.find(expType,acualType)) then
			passed = false;
		end		
		acualRes[i] = acualType;
	end
	
	if not(passed) then
		error(name.." Usage: "..string.join(",",unpack(expected)) .. " got "..string.join(" ",unpack(acualRes)),2)
	end
end

