public void AddCommand(string mnemonic, OMuxCommand omuxcmd) { try { oMuxCmdDict.Add(mnemonic, omuxcmd); } catch (System.ArgumentException e) { //TODO: log this, usually duplicate mnemonic throw e; } catch (Exception e) { throw e; } }
public bool RemoveCommand(string mnemonic, OMuxCommand omuxcmd) { bool rtnval = false; try { rtnval = oMuxCmdDict.Remove(mnemonic); } catch (ArgumentNullException e) { // TODO: log this throw e; } catch (Exception e) { throw e; } return(rtnval); }