Bewerken

Share via


AnonymousPipeServerStreamAcl.Create Method

Definition

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

public:
 static System::IO::Pipes::AnonymousPipeServerStream ^ Create(System::IO::Pipes::PipeDirection direction, System::IO::HandleInheritability inheritability, int bufferSize, System::IO::Pipes::PipeSecurity ^ pipeSecurity);
public static System.IO.Pipes.AnonymousPipeServerStream Create (System.IO.Pipes.PipeDirection direction, System.IO.HandleInheritability inheritability, int bufferSize, System.IO.Pipes.PipeSecurity? pipeSecurity);
static member Create : System.IO.Pipes.PipeDirection * System.IO.HandleInheritability * int * System.IO.Pipes.PipeSecurity -> System.IO.Pipes.AnonymousPipeServerStream
Public Shared Function Create (direction As PipeDirection, inheritability As HandleInheritability, bufferSize As Integer, pipeSecurity As PipeSecurity) As AnonymousPipeServerStream

Parameters

direction
PipeDirection

One of the enumeration values that determines the direction of the pipe. Anonymous pipes are unidirectional, so direction cannot be set to InOut.

inheritability
HandleInheritability

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

bufferSize
Int32

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

pipeSecurity
PipeSecurity

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

Returns

A new anonymous pipe server stream instance.

Exceptions

inheritability is not set to a valid HandleInheritability enum value.

-or-

bufferSize is less than 0.

Remarks

Setting pipeSecurity to null is equivalent to calling the AnonymousPipeServerStream(PipeDirection, HandleInheritability, Int32) constructor directly.

Applies to