PipeInterfaces.cs 597 B

123456789101112131415161718192021222324252627282930313233343536
  1. using Microsoft.Win32.SafeHandles;
  2. namespace System.IO.Pipes
  3. {
  4. // Common interfaces
  5. interface IPipe
  6. {
  7. SafePipeHandle Handle { get; }
  8. void WaitForPipeDrain ();
  9. }
  10. interface IAnonymousPipeClient : IPipe
  11. {
  12. }
  13. interface IAnonymousPipeServer : IPipe
  14. {
  15. SafePipeHandle ClientHandle { get; }
  16. void DisposeLocalCopyOfClientHandle ();
  17. }
  18. interface INamedPipeClient : IPipe
  19. {
  20. void Connect ();
  21. void Connect (int timeout);
  22. int NumberOfServerInstances { get; }
  23. bool IsAsync { get; }
  24. }
  25. interface INamedPipeServer : IPipe
  26. {
  27. void Disconnect ();
  28. void WaitForConnection ();
  29. }
  30. }