Pipelines.Sockets.Unofficial
Allocates blocks of memory
Allocate a new block
Clear (zero) the supplied region
An allocator that rents memory from the array-pool provided, returning them to the pool when done
An array-pool allocator that uses the shared array-pool
Create a new array-pool allocator that uses the provided array pool (or the shared array-pool otherwise)
Allocate a new block
An array-pool allocator that uses the shared array-pool
An allocator that allocates unmanaged memory, releasing the memory back to the OS when done
The global instance of the unmanaged allocator
Allocate a new block
Options that configure the behaviour of an arena
The default arena configuration
The flags that are enabled for the arena
Tests an individual flag
The block-size to suggest for new allocations in the arena
The policy for retaining allocations when memory requirements decrease
Create a new ArenaOptions instance
Provides facilities to create new type-specific allocators for use in an arena
The default allocator factory
Suggest an allocator for any type
Suggest an allocator for a blittable type
Suggest a per-type block size (in bytes) to use for allocations
Represents a typed subset of data within an arena
Allocate a (possibly non-contiguous) region of memory from the arena
Allocate a single instance as a reference
Allocate a (possibly non-contiguous) region of memory from the arena
An arena allocator that can allocate sequences for multiple data types
Create a new Arena instance
Release all resources associated with this arena
Reset the memory allocated by this arena
Allocate a single instance as a reference
Allocate a (possibly non-contiguous) region of memory from the arena
Allocate a (possibly non-contiguous) region of memory from the arena
Get a per-type arena inside a multi-type arena
Flags that impact behaviour of the arena
None
Allocations are cleared at each reset (and when initially allocated), so that they are always wiped before use
Allocations are cleared when the arena is disposed (or when data is released in line with the retention policy), so that the contents are not released back to the underlying allocator
When possible, and when no allocator is explicitly provided; prefer using unmanaged memory
When possible, use pinned memory
Allow blittable types of the same size to share a pool of data (only applies to multi-type arenas)
Allow blittable types to all share a single pool of byte-data, using padding to align (only applies to multi-type arenas, and for reasonably sized types)
Represents a lifetime-bound allocator of multiple non-contiguous memory regions
The number of elements allocated since the last reset
Create a new Arena
Allocate a (possibly non-contiguous) region of memory from the arena
Allocate a (possibly non-contiguous) region of memory from the arena
Allocate a (possibly non-contiguous) region of memory from the arena
Allocate a reference to a new instance from the arena
Resets the arena; all current allocations should be considered invalid - new allocations may overwrite them
Releases all resources associated with the arena
Acts as a fly-weight reference into existing data
Obtain a text representation of the value
Used to compare two instances for equality
Used to compare two instances for equality
Used to compare two instances for equality
Used to compare two instances for equality
Used to compare two instances for equality
Create a new reference into an array
Create a new reference into a memory
Get a reference to the underlying value
Convert a reference to the underlying type
Provides common retention policies
The default retention policy
Retain the space required by the previous operation (trim to the size of the last usage)
Retain nothing (trim aggressively)
Retain everything (grow only)
When the required usage drops, decay the retained amount exponentially; growth is instant
Represents a Sequence without needing to know the type at compile-time
Returns an empty sequence of the supplied type
Tests two sequences for equality
Tests two sequences for equality
Tests two sequences for equality
Used for equality operations
Summarizes a sequence as a string
Tests two sequences for equality
Tests two sequences for equality
Indicates whether the sequence involves multiple segments, vs whether all the data fits into the first segment
Indicates the number of elements in the sequence
Indicates whether the sequence is empty (zero elements)
Indicates the type of element defined by the sequence
Converts an untyped sequence back to a typed sequence; the type must be correct
Represents a (possibly non-contiguous) region of memory; the read/write cousin or ReadOnlySequence-T
Represents a typed sequence as an untyped sequence
Converts an untyped sequence back to a typed sequence; the type must be correct
Tests two sequences for equality
Tests two sequences for equality
Tests two sequences for equality
Used for equality operations
Summaries a sequence as a string
Tests two sequences for equality
Tests two sequences for equality
Converts a typed sequence to a typed read-only-sequence
Get a reference to an element by index; note that this *can* have
poor performance for multi-segment sequences, but it is usually satisfactory
Get a reference to an element by index; note that this *can* have
poor performance for multi-segment sequences, but it is usually satisfactory
Obtains a reference into the segment
Converts a typed sequence to a typed read-only-sequence
Represents a typed sequence as an untyped sequence
Converts a typed sequence to a typed read-only-sequence
Calculate the start position of the current sequence
Calculate the end position of the current sequence
Calculate a position inside the current sequence
Try to get the contents as an array
Obtains a sub-region of a sequence
Obtains a sub-region of a sequence
Attempts to convert a typed read-only-sequence back to a typed sequence; the sequence must have originated from a valid typed sequence
Indicates the number of elements in the sequence
Indicates whether the sequence involves multiple segments, vs whether all the data fits into the first segment
Indicates whether the sequence is empty (zero elements)
Obtains the first segment, in terms of a memory
Obtains the first segment, in terms of a span
Copy the contents of the sequence into a contiguous region
If possible, copy the contents of the sequence into a contiguous region
Create a new single-segment sequence from a memory
Create a new single-segment sequence from an array
Create a new single-segment sequence from an array
Allows a sequence to be enumerated as spans
Allows a sequence to be enumerated as memory instances
Allows a sequence to be enumerated as spans
Allows a sequence to be enumerated as spans
Allows a sequence to be enumerated as memory instances
Allows a sequence to be enumerated as memory instances
Allows a sequence to be enumerated as values
Allows a sequence to be enumerated as values
Attempt to move the next value
Progresses the iterator, asserting that space is available, returning a reference to the next value
Obtain a reference to the current value
Allows a sequence to be enumerated as spans
Attempt to move the next segment
Asserts that another span is available, and returns then next span
Obtain the current segment
Allows a sequence to be enumerated as memory instances
Attempt to move the next segment
Obtain the current segment
Asserts that another span is available, and returns then next span
Similar to Func, but with "in" parameters
Similar to Func, but with "in" parameters
Provides utility methods for working with sequences
Create an array with the contents of the sequence; if possible, an existing
wrapped array may be reused
Obtain a Sequence from an enumerable; this may reuse existing sequence-compatible data if possible
Create a list-like object that provides access to the sequence
Create an array with the contents of the sequence, applying a projection
Create an array with the contents of the sequence, applying a projection
Copy the data from a sequence to a span, applying a projection
Copy the data from a sequence to a span, applying a projection
Copy the data from a span to a sequence
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a sequence to a span, applying a projection
Copy the data from a sequence to a span, applying a projection
Copy the data from a span to a sequence
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a span to a sequence, applying a projection
Copy the data from a sequence to a newly allocated sequence, applying a projection
Copy the data from a sequence to a newly allocated sequence, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Copy the data from between two sequences, applying a projection
Attempt to calculate the net offset of a position
Attempt to calculate the net offset of a position
A list-like reference type that can be used in most APIs that expect a list object
Returns the size of the list
Allows a sequence to be enumerated as values
Provide a reference to an element by index
Get the sequence represented by this list
Represents an abstract chained segment of mutable memory
The segment index
The type of data represented by this segment
The actual type of memory used for the storage
The offset of this segment in the chain
A memory-owner that provides direct access to the root reference
The root reference of the block, or a null-pointer if the data should not be considered pinned
Gets the size of the data
Represents an abstract chained segment of mutable memory
Creates a new SequenceSegment, optionally attaching the segment to an existing chain
The length of the memory
The logical position of the start of this segment
The next segment in the chain
The memory represented by this segment
Get the logical index of this segment
Get the real type of data being used to hold this data
Remove the Next node in this chain, terminating the chain - returning the detached segment
Represents a with lifetime management over the data
The data represented by this value
Release any resources associated with this value
Create a new instance with a call-defined lifetime management callback
Access the underlying data directly
Represent an existing value with dummy lifetime management
Implements a buffer-writer over arbitrary memory
Create a new buffer-writer instance that uses a memory pool as the backing store; if the provided pool is null, the shared instance is used
Create a new buffer-writer instance that uses an array-pool as the backing store; if the provided pool is null, the shared instance is used
Create a new buffer-writer instance that uses an array-pool as the backing store; if the provided pool is null, the shared instance is used
Get the writer used to append data to this instance
Gets the amount of data buffered by the writer
Release all resources associate with this instance
Gets the currently buffered data as a sequence of read-write buffer-segments
Gets some subset of the currently buffered data as a sequence of read-only buffer-segments (with lifetime management); you
can continue to append data after calling Flush - any additional data will form a new payload
that can be fetched by the next call to Flush
Gets the currently buffered data as a sequence of read-only buffer-segments (with lifetime management); you
can continue to append data after calling Flush - any additional data will form a new payload
that can be fetched by the next call to Flush
Commit a number of bytes to the underyling buffer
Access a contiguous write buffer
Access a contiguous write buffer
Access a non-contiguous write buffer
Implements a over an
Creates a new instance
Indicates that a connection was aborted
Create a new instance of ConnectionAbortedException
Create a new instance of ConnectionAbortedException
Create a new instance of ConnectionAbortedException
Indicates that a connection was reset
Create a new ConnectionResetException instance
Create a new ConnectionResetException instance
Create a new ConnectionResetException instance
An implementation of a pipe-scheduler that uses a dedicated pool of threads, deferring to
the thread-pool if that becomes too backlogged
Reusable shared scheduler instance
Indicates whether the current thread is a worker, optionally for the specific pool
(otherwise for any pool)
The name of the pool
The number of workers associated with this pool
Create a new dedicated thread-pool
The total number of operations serviced by the queue
The total number of operations that could not be serviced by the queue, but which were sent to the thread-pool instead
Requests to be run on scheduler with being passed in
The number of workers currently actively engaged in work
Release the threads associated with this pool; if additional work is requested, it will
be sent to the main thread-pool
Provides utility methods for working with delegates
Iterate over the individual elements of a multicast delegate (without allocation)
Iterate over the individual elements of a multicast delegate (without allocation)
Indicates whether a particular delegate is known to be a single-target delegate
Indicates whether optimized usage is supported on this environment; without this, it may still
work, but with additional overheads at runtime.
Allows allocation-free enumerator over the individual elements of a multicast delegate
Iterate over the individual elements of a multicast delegate (without allocation)
Allows allocation-free enumerator over the individual elements of a multicast delegate
Provides the current value of the sequence
Move to the next item in the sequence
Reset the enumerator, allowing the sequence to be repeated
A duplex pipe that measures the bytes sent/received
The total number of bytes sent to the pipe
The total number of bytes received by the pipe
Represents a pipe that iterates over a memory-mapped file
Get a string representation of the object
Indicates whether this API is likely to work
Create a pipe-reader over the provided file
Mark the reader as complete
Releases all resources associated with the object
Cancels an in-progress read
Indicates how much data was consumed from a read operation
Indicates how much data was consumed, and how much examined, from a read operation
Perform an asynchronous read operation
Attempt to perform a synchronous read operation
Awaitable SocketAsyncEventArgs, where awaiting the args yields either the BytesTransferred or throws the relevant socket exception
Abort the current async operation (and prevent future operations)
Create a new SocketAwaitableEventArgs instance, optionally providing a scheduler for callbacks
Get the awaiter for this instance; used as part of "await"
Indicates whether the current operation is complete; used as part of "await"
Gets the result of the async operation is complete; used as part of "await"
Schedules a continuation for this operation; used as part of "await"
Schedules a continuation for this operation; used as part of "await"
Marks the operation as complete - this should be invoked whenever a SocketAsyncEventArgs operation returns false
Invoked automatically when an operation completes asynchronously
Reperesents a duplex pipe over managed sockets
Open a new or existing socket as a client
Open a new or existing socket as a client
Check that all dependencies are available
When possible, determines how the pipe first reached a close state
When the ShutdownKind relates to a socket error, may contain the socket error code
Try to signal the pipe shutdown reason as being due to an application protocol event
The kind of shutdown; only protocol-related reasons will succeed
True if successful
Set recommended socket options for client sockets
The socket to set options against
Set recommended socket options for server sockets
The socket to set options against
Release any resources held by this instance
Connection for receiving data
Connection for sending data
Gets a string representation of this object
The underlying socket for this connection
Obtain performance monitoring counters about this connection
Exposes performance monitoring counters about a connection
Get the number of bytes currently held in a pipe instance
The number of bytes available on the socket that have not yet been consumed into the pipe
The number of bytes available on the send pipe that have not yet been sent to the socket
The number of bytes available on the receive pipe, i.e. they have been processed from the socket, but not yet read
Create a SocketConnection instance over an existing socket
Create a SocketConnection instance over an existing socket
The total number of bytes read from the socket
The number of bytes received in the last read
The total number of bytes sent to the socket
When possible, determines how the pipe first reached a close state
The pipe is still open
The pipe itself was disposed
The socket-reader reached a natural EOF from the socket
The socket-reader encountered a dispose failure
The socket-reader encountered an IO failure
The socket-reader encountered a general failure
The socket-reader encountered a socket failure - the SocketError may be populated
When attempting to flush incoming data, the pipe indicated that it was complete
When attempting to flush incoming data, the pipe indicated cancelation
The socket-writerreached a natural EOF from the pipe
The socket-writer encountered a dispose failure
The socket-writer encountered an IO failure
The socket-writer encountered a general failure
The socket-writer encountered a socket failure - the SocketError may be populated
The input's reader was completed
The input's writer was completed
The output's reader was completed
The input's writer was completed
An application defined exit was triggered by the client
An application defined exit was triggered by the server
Flags that influence the behavior of SocketConnection
Default
When no data is currently available, perform a zero-length read as a buffer-free wait mechanism
During async reads, the awaiter should continue on the IO thread
During async writes, the awaiter should continue on the IO thread
During async connects, the awaiter should continue on the IO thread
Represents a multi-client socket-server capable of dispatching pipeline clients
Start listening as a server
Start listening as a server
Stop listening as a server
Release any resources associated with this instance
Release any resources associated with this instance
Create a new instance of a socket server
Invoked when the server has faulted
Invoked when a client has faulted
Invoked when the server starts
Invoked when a new client connects
The state of a client connection
The transport to use for this connection
The remote endpoint that the client connected from
Provides serves to shim between streams and pipelines
Exposes a Stream as a duplex pipe
Gets a string representation of this object
Gets whether read operations are available
Gets whether write operations are available
Gets whether the stream can timeout
Gets whether the seek operations are supported on this stream
Change the position of the stream
Query the length of the stream
Get or set the position of the stream
Specify the length of the stream
Read a buffer from the stream
Reads a single byte
Write a buffer to the stream
Perform an asynchronous write operation
Write a single byte
Begin an asynchronous write operation
End an asynchronous write operation
Signal that the written data should be read; this may awaken the reader if inactive,
and suspend the writer if the backlog is too large
Signal that the written data should be read; this may awaken the reader if inactive,
and suspend the writer if the backlog is too large
Close the stream
Signals that writing is complete; no more data will be written
Signals that reading is complete; no more data will be read
Begin an asynchronous read operation
End an asynchronous read operation
Perform an asynchronous read operation
Create a duplex pipe that represents the provided stream
Create a duplex pipe that represents the provided stream
Create a PipeReader that consumes the provided stream
Create a PipeWriter feeds the provided stream
Create a duplex stream that represents the provided reader and writer
Create a duplex stream that represents the provided pipe
Create a write-only stream that feeds the provided PipeReader
The writer to wrap
The logical name of the reader
Create a read-only stream that consumes the provided PipeReader
The reader to wrap
The logical name of the reader
A mutex primitive that can be waited or awaited, with support for schedulers
Time to wait, in milliseconds - or zero for immediate-only
See Object.ToString
Create a new MutexSlim instance
Time to wait, in milliseconds - or zero for immediate-only
The scheduler to use for async continuations, or the thread-pool if omitted
Indicates whether the lock is currently available
Attempt to take the lock (Success should be checked by the caller)
Attempt to take the lock (Success should be checked by the caller)
Additional options that influence how TryWait/TryWaitAsync operate
Default options
If the mutex cannot be acquired immediately, it is failed
Disable full TPL flow; more efficient, but no sync-context or execution-context guarantees
The result of a Wait/WaitAsync operation on MutexSlim; the caller *must* check Success to see whether the mutex was obtained
Compare two LockToken instances for equality
Compare two LockToken instances for equality
Compare two LockToken instances for equality
See Object.GetHashCode
See Object.ToString()
Compare two LockToken instances for equality
Indicates whether the mutex was successfully taken
Indicates whether the mutex was successfully taken
Indicates whether the mutex was successfully taken
Release the mutex, if obtained
A MemoryManager over a raw pointer
The pointer is assumed to be fully unmanaged, or externally pinned - no attempt will be made to pin this data
Create a new UnmanagedMemoryManager instance at the given pointer and size
It is assumed that the span provided is already unmanaged or externally pinned
Create a new UnmanagedMemoryManager instance at the given pointer and size
Create a new UnmanagedMemoryManager instance at the given pointer and size
Obtains a span that represents the region
Provides access to a pointer that represents the data (note: no actual pin occurs)
Has no effect
Releases all resources associated with this object