//# 10 errors, 343 messages
//#
/*
    //#CallbackManager.java:1:1: class: com.dmdirc.parser.irc.callbacks.CallbackManager
 * Copyright (c) 2006-2009 Chris Smith, Shane Mc Cormack, Gregory Holmes
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */

package com.dmdirc.parser.irc.callbacks;

import com.dmdirc.parser.irc.IRCParser;
import com.dmdirc.parser.irc.callbacks.interfaces.*;

import java.util.Hashtable;
import java.util.Map;

/**
 * IRC Parser Callback Manager.
 * Manages adding/removing/calling callbacks.
 *
 * @author            Shane Mc Cormack
 */
public final class CallbackManager {

    private static final Class[] CLASSES = {
    //#CallbackManager.java:39: method: com.dmdirc.parser.irc.callbacks.CallbackManager.com.dmdirc.parser.irc.callbacks.CallbackManager__static_init
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackManager]
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addAllCallback(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)V
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallbackType(Lcom/dmdirc/parser/irc/callbacks/CallbackObject;)Z
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addNonCriticalCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)Z
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addNonCriticalCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)Z
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delAllCallback(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delCallbackType(Lcom/dmdirc/parser/irc/callbacks/CallbackObject;)Z
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.getCallbackType(Ljava/lang/String;)Lcom/dmdirc/parser/irc/callbacks/CallbackObject;
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): new Class[](CallbackManager__static_init#1) num objects
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES.length
    //#output(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES[0..58]
    //#new obj(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): new Class[](CallbackManager__static_init#1)
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES == &new Class[](CallbackManager__static_init#1)
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackManager] == &__Dispatch_Table
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addAllCallback(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V == &addAllCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V == &addCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)V == &addCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addCallbackType(Lcom/dmdirc/parser/irc/callbacks/CallbackObject;)Z == &addCallbackType
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addNonCriticalCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)Z == &addNonCriticalCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.addNonCriticalCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)Z == &addNonCriticalCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delAllCallback(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V == &delAllCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delCallback(Ljava/lang/String;Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V == &delCallback
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.delCallbackType(Lcom/dmdirc/parser/irc/callbacks/CallbackObject;)Z == &delCallbackType
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): __Dispatch_Table.getCallbackType(Ljava/lang/String;)Lcom/dmdirc/parser/irc/callbacks/CallbackObject; == &getCallbackType
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): new Class[](CallbackManager__static_init#1) num objects == 1
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES.length == 59
    //#post(com.dmdirc.parser.irc.callbacks.CallbackManager__static_init): CLASSES[0..58] in Addr_Set{&com/dmdirc/parser/irc/callbacks/interfaces/IAwayState.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IAwayStateOther.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelAwayStateOther.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelAction.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelCTCP.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelCTCPReply.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelGotListModes.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelGotNames.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelJoin.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelKick.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelMessage.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelModeChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelNickChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelNonUserModeChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelNotice.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelPart.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelQuit.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelSelfJoin.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelSingleModeChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelTopic.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IChannelUserModeChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IConnectError.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IDataIn.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IDataOut.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IDebugInfo.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IErrorInfo.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IGotNetwork.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IInvite.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IMOTDEnd.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IMOTDLine.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IMOTDStart.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/INickChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/INickInUse.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/INoticeAuth.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/INumeric.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPasswordRequired.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPingFailed.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPingSuccess.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPingSent.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPrivateAction.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPrivateCTCP.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPrivateCTCPReply.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPrivateMessage.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPrivateNotice.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IPost005.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IQuit.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IServerError.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IServerReady.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/ISocketClosed.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUnknownAction.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUnknownCTCP.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUnknownCTCPReply.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUnknownMessage.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUnknownNotice.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUserModeChanged.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IUserModeDiscovered.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IWallDesync.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IWallop.__Class_Obj,&com/dmdirc/parser/irc/callbacks/interfaces/IWalluser.__Class_Obj}
    //#CallbackManager.java:39: end of method: com.dmdirc.parser.irc.callbacks.CallbackManager.com.dmdirc.parser.irc.callbacks.CallbackManager__static_init
        IAwayState.class, IAwayStateOther.class, IChannelAwayStateOther.class,
        IChannelAction.class, IChannelCTCP.class, IChannelCTCPReply.class,
        IChannelGotListModes.class, IChannelGotNames.class, IChannelJoin.class,
        IChannelKick.class, IChannelMessage.class, IChannelModeChanged.class,
        IChannelNickChanged.class, IChannelNonUserModeChanged.class,
        IChannelNotice.class, IChannelPart.class, IChannelQuit.class,
        IChannelSelfJoin.class, IChannelSingleModeChanged.class,
        IChannelTopic.class, IChannelUserModeChanged.class, IConnectError.class,
        IDataIn.class, IDataOut.class, IDebugInfo.class, IErrorInfo.class,
        IGotNetwork.class, IInvite.class, IMOTDEnd.class, IMOTDLine.class,
        IMOTDStart.class, INickChanged.class, INickInUse.class,
        INoticeAuth.class, INumeric.class, IPasswordRequired.class,
        IPingFailed.class, IPingSuccess.class, IPingSent.class, IPrivateAction.class,
        IPrivateCTCP.class, IPrivateCTCPReply.class, IPrivateMessage.class,
        IPrivateNotice.class, IPost005.class, IQuit.class, IServerError.class,
        IServerReady.class, ISocketClosed.class, IUnknownAction.class,
        IUnknownCTCP.class, IUnknownCTCPReply.class, IUnknownMessage.class,
        IUnknownNotice.class, IUserModeChanged.class, IUserModeDiscovered.class,
        IWallDesync.class, IWallop.class, IWalluser.class,
    };

	/** Reference to the parser object that owns this CallbackManager. */
	IRCParser myParser;
	
	/** Hashtable used to store the different types of callback known. */
	private final Map<String, CallbackObject> callbackHash = new Hashtable<String, CallbackObject>();
	
	/**
	 * Constructor to create a CallbackManager.
	 *
	 * @param parser IRCParser that owns this callback manager.
	 */
	public CallbackManager(final IRCParser parser) {
    //#CallbackManager.java:72: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): "On"._tainted
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): CLASSES
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): CLASSES.length
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): CLASSES[0..4_294_967_295]
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): parser
    //#input(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): this
    //#output(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): new Hashtable(CallbackManager#1) num objects
    //#output(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): this.callbackHash
    //#output(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): this.myParser
    //#new obj(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): new Hashtable(CallbackManager#1)
    //#pre[1] (void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): (soft) CLASSES[0..4_294_967_295] != null
    //#presumption(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): java.lang.Class:asSubclass(...)@77 != null
    //#presumption(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): java.lang.Class:asSubclass(...)@80 != null
    //#post(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): this.callbackHash == &new Hashtable(CallbackManager#1)
    //#post(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): this.myParser == parser
    //#post(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): init'ed(this.myParser)
    //#post(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): new Hashtable(CallbackManager#1) num objects == 1
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.Class:getSimpleName
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.String:substring
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.util.Map:put
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.util.ArrayList
    //#unanalyzed(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): Effects-of-calling:java.util.Hashtable
    //#test_vector(void com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)): java.lang.Class:isAnnotationPresent(...)@76: {0}, {1}
		myParser = parser;
		
        for (Class<?> type : CLASSES) {
            if (type.isAnnotationPresent(SpecificCallback.class)) {
                addCallbackType(new CallbackObjectSpecific(myParser, this,
                        type.asSubclass(ICallbackInterface.class)));
            } else {
                addCallbackType(new CallbackObject(myParser, this,
                        type.asSubclass(ICallbackInterface.class)));
            }
        }
	}
    //#CallbackManager.java:84: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.com.dmdirc.parser.irc.callbacks.CallbackManager(IRCParser)

	/**
	 * Add new callback type.
	 *
	 * @param callback CallbackObject subclass for the callback.
	 * @return if adding succeeded or not.
	 */
	public boolean addCallbackType(final CallbackObject callback) {
		if (!callbackHash.containsKey(callback.getLowerName())) {
    //#CallbackManager.java:93: method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addCallbackType(CallbackObject)
    //#CallbackManager.java:93: Warning: suspicious precondition
    //#    The precondition for callback.__Tag is not a contiguous range of values
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: bool addCallbackType(CallbackObject)
    //#    suspicious precondition index: [2]
    //#input(bool addCallbackType(CallbackObject)): "On"._tainted
    //#input(bool addCallbackType(CallbackObject)): callback
    //#input(bool addCallbackType(CallbackObject)): callback.__Tag
    //#input(bool addCallbackType(CallbackObject)): callback.type
    //#input(bool addCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(bool addCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(bool addCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(bool addCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(bool addCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(bool addCallbackType(CallbackObject)): this
    //#input(bool addCallbackType(CallbackObject)): this.callbackHash
    //#output(bool addCallbackType(CallbackObject)): return_value
    //#pre[1] (bool addCallbackType(CallbackObject)): callback != null
    //#pre[2] (bool addCallbackType(CallbackObject)): callback.__Tag in {com/dmdirc/parser/irc/callbacks/CallbackObject, com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific}
    //#pre[3] (bool addCallbackType(CallbackObject)): callback.type != null
    //#pre[5] (bool addCallbackType(CallbackObject)): this.callbackHash != null
    //#post(bool addCallbackType(CallbackObject)): init'ed(return_value)
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.Class:getSimpleName
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.String:substring
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(bool addCallbackType(CallbackObject)): Effects-of-calling:java.lang.String:toLowerCase
    //#test_vector(bool addCallbackType(CallbackObject)): java.util.Map:containsKey(...)@93: {1}, {0}
			callbackHash.put(callback.getLowerName(), callback);
			return true;
		}
		return false;
    //#CallbackManager.java:97: end of method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addCallbackType(CallbackObject)
	}
	
	/**
	 * Remove a callback type.
	 *
	 * @param callback CallbackObject subclass to remove.
	 * @return if removal succeeded or not.
	 */
	public boolean delCallbackType(final CallbackObject callback) {
		if (callbackHash.containsKey(callback.getLowerName())) {
    //#CallbackManager.java:107: method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.delCallbackType(CallbackObject)
    //#CallbackManager.java:107: Warning: suspicious precondition
    //#    The precondition for callback.__Tag is not a contiguous range of values
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: bool delCallbackType(CallbackObject)
    //#    suspicious precondition index: [2]
    //#input(bool delCallbackType(CallbackObject)): "On"._tainted
    //#input(bool delCallbackType(CallbackObject)): callback
    //#input(bool delCallbackType(CallbackObject)): callback.__Tag
    //#input(bool delCallbackType(CallbackObject)): callback.type
    //#input(bool delCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(bool delCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(bool delCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(bool delCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(bool delCallbackType(CallbackObject)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.getName()Ljava/lang/String;
    //#input(bool delCallbackType(CallbackObject)): this
    //#input(bool delCallbackType(CallbackObject)): this.callbackHash
    //#output(bool delCallbackType(CallbackObject)): return_value
    //#pre[1] (bool delCallbackType(CallbackObject)): callback != null
    //#pre[2] (bool delCallbackType(CallbackObject)): callback.__Tag in {com/dmdirc/parser/irc/callbacks/CallbackObject, com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific}
    //#pre[3] (bool delCallbackType(CallbackObject)): callback.type != null
    //#pre[5] (bool delCallbackType(CallbackObject)): this.callbackHash != null
    //#post(bool delCallbackType(CallbackObject)): init'ed(return_value)
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.Class:getSimpleName
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.String:substring
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(bool delCallbackType(CallbackObject)): Effects-of-calling:java.lang.String:toLowerCase
    //#test_vector(bool delCallbackType(CallbackObject)): java.util.Map:containsKey(...)@107: {0}, {1}
			callbackHash.remove(callback.getLowerName());
			return true;
		}
		return false;
    //#CallbackManager.java:111: end of method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.delCallbackType(CallbackObject)
	}
	
	/**
	 * Get reference to callback object.
	 *
	 * @param callbackName Name of callback object.
	 * @return CallbackObject returns the callback object for this type
	 */
	public CallbackObject getCallbackType(final String callbackName) {
		if (!callbackHash.containsKey(callbackName.toLowerCase())) {
    //#CallbackManager.java:121: method: CallbackObject com.dmdirc.parser.irc.callbacks.CallbackManager.getCallbackType(String)
    //#input(CallbackObject getCallbackType(String)): "Callback not found: "._tainted
    //#input(CallbackObject getCallbackType(String)): callbackName
    //#input(CallbackObject getCallbackType(String)): callbackName._tainted
    //#input(CallbackObject getCallbackType(String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(CallbackObject getCallbackType(String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(CallbackObject getCallbackType(String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(CallbackObject getCallbackType(String)): this
    //#input(CallbackObject getCallbackType(String)): this.callbackHash
    //#output(CallbackObject getCallbackType(String)): return_value
    //#pre[1] (CallbackObject getCallbackType(String)): callbackName != null
    //#pre[4] (CallbackObject getCallbackType(String)): this.callbackHash != null
    //#presumption(CallbackObject getCallbackType(String)): java.util.Map:containsKey(...)@121 == 1
    //#presumption(CallbackObject getCallbackType(String)): java.util.Map:get(...).__Tag@125 in {com/dmdirc/parser/irc/callbacks/CallbackObject, com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific}
    //#post(CallbackObject getCallbackType(String)): init'ed(return_value)
    //#unanalyzed(CallbackObject getCallbackType(String)): Effects-of-calling:java.lang.RuntimeException
			throw new CallbackNotFoundException("Callback not found: " + callbackName);
		}
		
		return callbackHash.get(callbackName.toLowerCase());
    //#CallbackManager.java:125: end of method: CallbackObject com.dmdirc.parser.irc.callbacks.CallbackManager.getCallbackType(String)
	}
	
	/**
	 * Remove all callbacks associated with a specific object.
	 *
	 * @param o instance of ICallbackInterface to remove.
	 */
	public void delAllCallback(final ICallbackInterface o) {
		for (CallbackObject cb : callbackHash.values()) {
    //#CallbackManager.java:134: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.delAllCallback(ICallbackInterface)
    //#input(void delAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void delAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void delAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void delAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.del(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void delAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.del(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void delAllCallback(ICallbackInterface)): o
    //#input(void delAllCallback(ICallbackInterface)): this
    //#input(void delAllCallback(ICallbackInterface)): this.callbackHash
    //#pre[3] (void delAllCallback(ICallbackInterface)): this.callbackHash != null
    //#presumption(void delAllCallback(ICallbackInterface)): cb.callbackInfo@134 != null
    //#presumption(void delAllCallback(ICallbackInterface)): java.util.Iterator:next(...).__Tag@134 in {com/dmdirc/parser/irc/callbacks/CallbackObject, com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific}
    //#presumption(void delAllCallback(ICallbackInterface)): java.util.Map:values(...)@134 != null
    //#unanalyzed(void delAllCallback(ICallbackInterface)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(void delAllCallback(ICallbackInterface)): Effects-of-calling:java.util.Hashtable:remove
    //#unanalyzed(void delAllCallback(ICallbackInterface)): Effects-of-calling:java.util.List:remove
    //#test_vector(void delAllCallback(ICallbackInterface)): java.util.Iterator:hasNext(...)@134: {0}, {1}
    //#test_vector(void delAllCallback(ICallbackInterface)): java.util.Iterator:next(...)@134: Addr_Set{null}, Inverse{null}
			if (cb != null) { cb.del(o); }
		}
	}
    //#CallbackManager.java:137: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.delAllCallback(ICallbackInterface)
	
	/**
	 * Add all callbacks.
	 *
	 * @param o instance of ICallbackInterface to add.
	 */
	public void addAllCallback(final ICallbackInterface o) {
		for (CallbackObject cb : callbackHash.values()) {
    //#CallbackManager.java:145: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addAllCallback(ICallbackInterface)
    //#input(void addAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void addAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void addAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void addAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void addAllCallback(ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void addAllCallback(ICallbackInterface)): o
    //#input(void addAllCallback(ICallbackInterface)): this
    //#input(void addAllCallback(ICallbackInterface)): this.callbackHash
    //#pre[3] (void addAllCallback(ICallbackInterface)): this.callbackHash != null
    //#presumption(void addAllCallback(ICallbackInterface)): cb.callbackInfo@145 != null
    //#presumption(void addAllCallback(ICallbackInterface)): java.util.Iterator:next(...).__Tag@145 in {com/dmdirc/parser/irc/callbacks/CallbackObject, com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific}
    //#presumption(void addAllCallback(ICallbackInterface)): java.util.Map:values(...)@145 != null
    //#unanalyzed(void addAllCallback(ICallbackInterface)): Effects-of-calling:java.util.List:contains
    //#unanalyzed(void addAllCallback(ICallbackInterface)): Effects-of-calling:java.util.List:add
    //#unanalyzed(void addAllCallback(ICallbackInterface)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(void addAllCallback(ICallbackInterface)): Effects-of-calling:java.util.Hashtable:remove
    //#test_vector(void addAllCallback(ICallbackInterface)): java.util.Iterator:hasNext(...)@145: {0}, {1}
    //#test_vector(void addAllCallback(ICallbackInterface)): java.util.Iterator:next(...)@145: Addr_Set{null}, Inverse{null}
			if (cb != null) { cb.add(o); }
		}
	}
    //#CallbackManager.java:148: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addAllCallback(ICallbackInterface)
	
	/**
	 * Add a callback.
 	 * This method will throw a CallbackNotFoundException if the callback does not exist.
	 *
	 * @param callbackName Name of callback object.
	 * @param o instance of ICallbackInterface to add.
	 * @throws CallbackNotFoundException If callback is not found.
	 * @throws NullPointerException If 'o' is null
	 */
	public void addCallback(final String callbackName, final ICallbackInterface o) throws CallbackNotFoundException {
		if (o == null) {
    //#CallbackManager.java:160: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addCallback(String, ICallbackInterface)
    //#input(void addCallback(String, ICallbackInterface)): "Callback not found: "._tainted
    //#input(void addCallback(String, ICallbackInterface)): callbackName
    //#input(void addCallback(String, ICallbackInterface)): callbackName._tainted
    //#input(void addCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void addCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void addCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void addCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void addCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void addCallback(String, ICallbackInterface)): o
    //#input(void addCallback(String, ICallbackInterface)): this
    //#input(void addCallback(String, ICallbackInterface)): this.callbackHash
    //#pre[1] (void addCallback(String, ICallbackInterface)): callbackName != null
    //#pre[3] (void addCallback(String, ICallbackInterface)): o != null
    //#pre[5] (void addCallback(String, ICallbackInterface)): this.callbackHash != null
    //#presumption(void addCallback(String, ICallbackInterface)): cb.callbackInfo != null
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.RuntimeException
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:get
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.List:contains
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.List:add
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(void addCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:remove
			throw new NullPointerException("CallbackInterface is null");
		}
		
		final CallbackObject cb = getCallbackType(callbackName);
		
		if (cb != null) { cb.add(o); }
    //#CallbackManager.java:166: ?use of default init
    //#    init'ed(cb.__Tag)
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface)
    //#    basic block: bb_2
    //#    assertion: init'ed(cb.__Tag)
    //#    VN: cb.__Tag
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#CallbackManager.java:166: ?null dereference
    //#    com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[cb.__Tag] != null
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface)
    //#    basic block: bb_2
    //#    assertion: com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[cb.__Tag] != null
    //#    VN: com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[cb.__Tag]
    //#    Expected: Inverse{null}
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
	}
    //#CallbackManager.java:167: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addCallback(String, ICallbackInterface)
	
	/**
	 * Add a callback with a specific target.
 	 * This method will throw a CallbackNotFoundException if the callback does not exist.
	 *
	 * @param callbackName Name of callback object.
	 * @param o instance of ICallbackInterface to add.
	 * @param target Parameter to specify that a callback should only fire for specific things
	 * @throws CallbackNotFoundException If callback is not found.
	 * @throws NullPointerException If 'o' is null
	 */
	public void addCallback(final String callbackName, final ICallbackInterface o, final String target) throws CallbackNotFoundException {
		if (o == null) { throw new NullPointerException("CallbackInterface is null"); }
    //#CallbackManager.java:180: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addCallback(String, ICallbackInterface, String)
    //#input(void addCallback(String, ICallbackInterface, String)): "Callback not found: "._tainted
    //#input(void addCallback(String, ICallbackInterface, String)): callbackName
    //#input(void addCallback(String, ICallbackInterface, String)): callbackName._tainted
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[others]
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void addCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)V
    //#input(void addCallback(String, ICallbackInterface, String)): o
    //#input(void addCallback(String, ICallbackInterface, String)): target
    //#input(void addCallback(String, ICallbackInterface, String)): this
    //#input(void addCallback(String, ICallbackInterface, String)): this.callbackHash
    //#pre[1] (void addCallback(String, ICallbackInterface, String)): callbackName != null
    //#pre[3] (void addCallback(String, ICallbackInterface, String)): o != null
    //#pre[4] (void addCallback(String, ICallbackInterface, String)): target != null
    //#pre[6] (void addCallback(String, ICallbackInterface, String)): this.callbackHash != null
    //#presumption(void addCallback(String, ICallbackInterface, String)): getCallbackType(...).callbackInfo != null
    //#presumption(void addCallback(String, ICallbackInterface, String)): getCallbackType(...).specificData != null
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.RuntimeException
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Map:get
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.List:contains
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.List:add
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:remove
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.String:isEmpty
    //#unanalyzed(void addCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:put
		((CallbackObjectSpecific) getCallbackType(callbackName)).add(o,target);
    //#CallbackManager.java:181: ?use of default init
    //#    init'ed(getCallbackType(...).__Tag)
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface, String)
    //#    basic block: bb_3
    //#    assertion: init'ed(getCallbackType(...).__Tag)
    //#    VN: getCallbackType(...).__Tag
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#CallbackManager.java:181: ?ClassCastException check
    //#    com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface, String)
    //#    basic block: bb_3
    //#    assertion: com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    VN: getCallbackType(...).__Tag == com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific
    //#    Expected: {-Inf..-1, 1..+Inf}
    //#    Bad: {0}
    //#    Attribs:  Int  Bad singleton  Bad overlaps +/-1000  Bad > Exp
    //#CallbackManager.java:181: ?null dereference
    //#    getCallbackType(...) != null
    //#    severity: MEDIUM
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface, String)
    //#    basic block: bb_2
    //#    assertion: getCallbackType(...) != null
    //#    VN: getCallbackType(...)
    //#    Expected: Inverse{null}
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
    //#CallbackManager.java:181: ?use of default init
    //#    init'ed(getCallbackType(...).__Tag)
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface, String)
    //#    basic block: bb_2
    //#    assertion: init'ed(getCallbackType(...).__Tag)
    //#    VN: getCallbackType(...).__Tag
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#CallbackManager.java:181: ?null dereference
    //#    com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void addCallback(String, ICallbackInterface, String)
    //#    basic block: bb_2
    //#    assertion: com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    VN: com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[getCallbackType(...).__Tag]
    //#    Expected: Inverse{null}
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
	}
    //#CallbackManager.java:182: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.addCallback(String, ICallbackInterface, String)
	
	/**
	 * Add a callback without an exception.
	 * This should be used if a callback is not essential for execution (ie the DebugOut callback)
	 *
	 * @param callbackName Name of callback object.
	 * @param o instance of ICallbackInterface to add.
	 * @return true/false if the callback was added or not.
	 */
	public boolean addNonCriticalCallback(final String callbackName, final ICallbackInterface o)  {
		try {
			addCallback(callbackName, o);
    //#CallbackManager.java:194: method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addNonCriticalCallback(String, ICallbackInterface)
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): "Callback not found: "._tainted
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): callbackName
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): callbackName._tainted
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): o
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): this
    //#input(bool addNonCriticalCallback(String, ICallbackInterface)): this.callbackHash
    //#output(bool addNonCriticalCallback(String, ICallbackInterface)): return_value
    //#pre[1] (bool addNonCriticalCallback(String, ICallbackInterface)): (soft) callbackName != null
    //#pre[3] (bool addNonCriticalCallback(String, ICallbackInterface)): (soft) o != null
    //#pre[5] (bool addNonCriticalCallback(String, ICallbackInterface)): (soft) this.callbackHash != null
    //#post(bool addNonCriticalCallback(String, ICallbackInterface)): init'ed(return_value)
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.RuntimeException
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:get
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.List:contains
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.List:add
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:remove
			return true;
		} catch (CallbackNotFoundException e) { return false; }
    //#CallbackManager.java:196: end of method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addNonCriticalCallback(String, ICallbackInterface)
	}
	
	/**
	 * Add a callback with a specific target.
	 * This should be used if a callback is not essential for execution
	 *
	 * @param callbackName Name of callback object.
	 * @param o instance of ICallbackInterface to add.
	 * @param target Parameter to specify that a callback should only fire for specific things
	 * @return true/false if the callback was added or not.
	 */
	public boolean addNonCriticalCallback(final String callbackName, final ICallbackInterface o, final String target) {
		try {
			addCallback(callbackName, o, target);
    //#CallbackManager.java:210: method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addNonCriticalCallback(String, ICallbackInterface, String)
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): "Callback not found: "._tainted
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): callbackName
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): callbackName._tainted
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Descendant_Table[others]
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.add(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;Ljava/lang/String;)V
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): o
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): target
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): this
    //#input(bool addNonCriticalCallback(String, ICallbackInterface, String)): this.callbackHash
    //#output(bool addNonCriticalCallback(String, ICallbackInterface, String)): return_value
    //#pre[1] (bool addNonCriticalCallback(String, ICallbackInterface, String)): (soft) callbackName != null
    //#pre[3] (bool addNonCriticalCallback(String, ICallbackInterface, String)): (soft) o != null
    //#pre[4] (bool addNonCriticalCallback(String, ICallbackInterface, String)): (soft) target != null
    //#pre[6] (bool addNonCriticalCallback(String, ICallbackInterface, String)): (soft) this.callbackHash != null
    //#post(bool addNonCriticalCallback(String, ICallbackInterface, String)): init'ed(return_value)
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.RuntimeException
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Map:get
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.List:contains
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.List:add
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:remove
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.lang.String:isEmpty
    //#unanalyzed(bool addNonCriticalCallback(String, ICallbackInterface, String)): Effects-of-calling:java.util.Hashtable:put
			return true;
		} catch (CallbackNotFoundException e) { return false;	}
    //#CallbackManager.java:212: end of method: bool com.dmdirc.parser.irc.callbacks.CallbackManager.addNonCriticalCallback(String, ICallbackInterface, String)
	}
	
	
	/**
	 * Remove a callback.
	 *
	 * @param callbackName Name of callback object.
	 * @param o instance of ICallbackInterface to remove.
	 */
	public void delCallback(final String callbackName, final ICallbackInterface o) {
		getCallbackType(callbackName).del(o);
    //#CallbackManager.java:223: method: void com.dmdirc.parser.irc.callbacks.CallbackManager.delCallback(String, ICallbackInterface)
    //#CallbackManager.java:223: ?null dereference
    //#    getCallbackType(...) != null
    //#    severity: MEDIUM
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void delCallback(String, ICallbackInterface)
    //#    basic block: Entry_BB_1
    //#    assertion: getCallbackType(...) != null
    //#    VN: getCallbackType(...)
    //#    Expected: Inverse{null}
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
    //#CallbackManager.java:223: ?use of default init
    //#    init'ed(getCallbackType(...).__Tag)
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void delCallback(String, ICallbackInterface)
    //#    basic block: Entry_BB_1
    //#    assertion: init'ed(getCallbackType(...).__Tag)
    //#    VN: getCallbackType(...).__Tag
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#CallbackManager.java:223: ?null dereference
    //#    com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    severity: SUPPRESSED
    //#    class: com.dmdirc.parser.irc.callbacks.CallbackManager
    //#    method: void delCallback(String, ICallbackInterface)
    //#    basic block: Entry_BB_1
    //#    assertion: com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[getCallbackType(...).__Tag] != null
    //#    VN: com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[getCallbackType(...).__Tag]
    //#    Expected: Inverse{null}
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
    //#input(void delCallback(String, ICallbackInterface)): "Callback not found: "._tainted
    //#input(void delCallback(String, ICallbackInterface)): callbackName
    //#input(void delCallback(String, ICallbackInterface)): callbackName._tainted
    //#input(void delCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific]
    //#input(void delCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[com/dmdirc/parser/irc/callbacks/CallbackObject]
    //#input(void delCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Descendant_Table[others]
    //#input(void delCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObject.__Dispatch_Table.del(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void delCallback(String, ICallbackInterface)): com/dmdirc/parser/irc/callbacks/CallbackObjectSpecific.__Dispatch_Table.del(Lcom/dmdirc/parser/irc/callbacks/interfaces/ICallbackInterface;)V
    //#input(void delCallback(String, ICallbackInterface)): o
    //#input(void delCallback(String, ICallbackInterface)): this
    //#input(void delCallback(String, ICallbackInterface)): this.callbackHash
    //#pre[1] (void delCallback(String, ICallbackInterface)): callbackName != null
    //#pre[5] (void delCallback(String, ICallbackInterface)): this.callbackHash != null
    //#presumption(void delCallback(String, ICallbackInterface)): getCallbackType(...).callbackInfo != null
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:containsKey
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.String:toLowerCase
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.lang.RuntimeException
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Map:get
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:containsKey
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.util.Hashtable:remove
    //#unanalyzed(void delCallback(String, ICallbackInterface)): Effects-of-calling:java.util.List:remove
	}
    //#CallbackManager.java:224: end of method: void com.dmdirc.parser.irc.callbacks.CallbackManager.delCallback(String, ICallbackInterface)

}
    //#CallbackManager.java:: end of class: com.dmdirc.parser.irc.callbacks.CallbackManager
