NamedPipeClientStream Constructor (PipeDirection, Boolean, Boolean, SafePipeHandle^)

 

Initializes a new instance of the NamedPipeClientStream class for the specified pipe handle with the specified pipe direction.

Namespace:   System.IO.Pipes
Assembly:  System.Core (in System.Core.dll)

public:
NamedPipeClientStream(
	PipeDirection direction,
	bool isAsync,
	bool isConnected,
	SafePipeHandle^ safePipeHandle
)

Parameters

direction
Type: System.IO.Pipes::PipeDirection

One of the enumeration values that determines the direction of the pipe.

isAsync
Type: System::Boolean

true to indicate that the handle was opened asynchronously; otherwise, false.

isConnected
Type: System::Boolean

true to indicate that the pipe is connected; otherwise, false.

safePipeHandle
Type: Microsoft.Win32.SafeHandles::SafePipeHandle^

A safe handle for the pipe that this NamedPipeClientStream object will encapsulate.

Exception Condition
IOException

safePipeHandle is not a valid handle.

ArgumentException

safePipeHandle is not a valid handle.

ArgumentNullException

safePipeHandle is null.

ArgumentOutOfRangeException

direction is not a valid PipeDirection value.

IOException

The stream has been closed.

Demand

for full trust for the immediate caller. This member cannot be used by partially trusted code.

.NET Framework
Available since 3.5
Return to top
Show: