AnonymousPipeServerStream Constructor (PipeDirection, HandleInheritability, Int32, PipeSecurity^)

 

Initializes a new instance of the AnonymousPipeServerStream class with the specified pipe direction, inheritability mode, buffer size, and pipe security.

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

public:
AnonymousPipeServerStream(
	PipeDirection direction,
	HandleInheritability inheritability,
	int bufferSize,
	PipeSecurity^ pipeSecurity
)

Parameters

direction
Type: System.IO.Pipes::PipeDirection

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

Anonymous pipes can only be in one direction, so direction cannot be set to InOut.

inheritability
Type: System.IO::HandleInheritability

One of the enumeration values that determines whether the underlying handle can be inherited by child processes.

bufferSize
Type: System::Int32

The size of the buffer. This value must be greater than or equal to 0.

pipeSecurity
Type: System.IO.Pipes::PipeSecurity^

An object that determines the access control and audit security for the pipe.

Exception Condition
ArgumentOutOfRangeException

inheritability is not set to either None or Inheritable.

-or-

bufferSize is less than 0.

NotSupportedException

direction is set to InOut.

A PipeDirection value of InOut is not supported because anonymous pipes are defined to be one-way.

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: