shrinkBufferCapacity(to:)

    The ByteBuffer will successfully be shrunk if the requested capacity is less than the current capacity, and the requested capacity is greater than or equal to the number of readable bytes in the buffer. If either condition is not true, the buffer will not be shrunk.

    ByteBuffer-core.swift:898
    @discardableResult mutating func shrinkBufferCapacity(to desiredCapacity: Int) -> Bool

    Parameters

    desiredCapacity

    The desired capacity for the buffers capacity to be shrunken to

    Returns

    Bool indicating whether the buffer capacity has been shrunk to the desiredCapacity.

    Other members in extension

    Types

    Typealiases

    Show implementation details (2)

    Hide implementation details

    Type members

    Instance members

    Show obsolete interfaces (3)

    Hide obsolete interfaces