internal CifsIoException(int errorclass, int errorcode) { fSMBErrorClass = errorclass; fSMBErrorCode = errorcode; string key; if (errorclass == ERROR_CMD) { key = "255:0"; } else { key = (errorclass & 0xff) + ":" + (errorcode & 0xffff); } try { fMessage = CifsRuntimeException.GetMessage(key); } catch (Exception) // The key was not found { fMessage = CifsRuntimeException.GetMessage("U:U"); } fMessage = fMessage + "( SMB=" + key + ")"; }
internal static CifsIoException getNBException(int code) { CifsIoException e = new CifsIoException(); try { e.fMessage = CifsRuntimeException.GetMessage("NB" + code); } catch (Exception) { e.fMessage = CifsRuntimeException.GetMessage("NB999", code); } return(e); }
internal static CifsIoException getLMException(int code) { CifsIoException e = new CifsIoException(); try { e.fMessage = CifsRuntimeException.GetMessage("LM" + code); } catch (Exception) { e.fMessage = CifsRuntimeException.GetMessage("LMERROR", code); if (Debug.DebugOn) { Debug.WriteLine(Debug.Warning, "LM Error: " + code + " not defined."); } } return(e); }
internal CifsIoException(string key, object i1, object i2) { fMessage = CifsRuntimeException.GetMessage(key, i1, i2); }
public CifsIoException(string key) { fMessage = CifsRuntimeException.GetMessage(key); }