public void Dispose() { try { if (_pipe == null) { return; } _pipe.Dispose(); _pipe = null; } catch (Exception exception) { LastException = exception; } }
protected bool Create(string pipeName) { try { Close(); Log.Information("Attempting to create pipe '" + pipeName + "'"); _pipe = Pipe.Server.Create(pipeName, System.IO.FileAccess.ReadWrite); Log.Information("Successfully created pipe '" + pipeName + "'"); return(true); } catch (Exception exception) { LastException = exception; return(false); } }