public static final boolean addClass(final CMObjectType type, final CMObject O)
	{
		final Object set=getClassSet(type);
		if(set==null)
			return false;
		CMClass.lastUpdateTime=System.currentTimeMillis();
		if(set instanceof List)
		{
			((List)set).add(O);
			if(set instanceof XVector)
				((XVector)set).sort();
		}
		else
		if(set instanceof Hashtable)
			((Hashtable)set).put(O.ID().trim().toUpperCase(), O);
		else
		if(set instanceof HashSet)
			((HashSet)set).add(O);
		else
			return false;
		if(set==c().commands)
			reloadCommandWords();
		if(set==c().libraries)
			CMLib.registerLibraries(c().libraries.elements());
		return true;
	}