func getData(at: Int, length: Int) -> Data?Return length bytes starting at index and return the result as Data. This will not change the reader index. The selected bytes must be readable or else nil will be returned.
func getData(at: Int, length: Int, byteTransferStrategy: ByteBuffer.ByteTransferStrategy) -> Data?Return length bytes starting at index and return the result as Data. This will not change the reader index. The selected bytes must be readable or else nil will be returned.
func getJSONDecodable<T>(T.Type, decoder: JSONDecoder, at: Int, length: Int) throws -> T?Attempts to decode the length bytes from index using the JSONDecoder decoder as T.
func getString(at: Int, length: Int, encoding: String.Encoding) -> String?Get a String decoding length bytes starting at index with encoding. This will not change the reader index. The selected bytes must be readable or else nil will be returned.
func getUUIDBytes(at: Int) -> UUID?Get a UUID from the 16 bytes starting at index. This will not change the reader index. If there are less than 16 bytes starting at index then nil will be returned.
func peekData(length: Int, byteTransferStrategy: ByteBuffer.ByteTransferStrategy) -> Data?Return length bytes starting at the current readerIndex as Data. This will not change the reader index.
func peekUUIDBytes() -> UUID?Get a UUID from the 16 bytes starting at the current readerIndex. Does not move the reader index.
func readData(length: Int) -> Data?Read length bytes off this ByteBuffer, move the reader index forward by length bytes and return the result as Data.
func readData(length: Int, byteTransferStrategy: ByteBuffer.ByteTransferStrategy) -> Data?Read length bytes off this ByteBuffer, move the reader index forward by length bytes and return the result as Data.
func readJSONDecodable<T>(T.Type, decoder: JSONDecoder, length: Int) throws -> T?Reads length bytes from this ByteBuffer and then attempts to decode them using the JSONDecoder decoder.
func readString(length: Int, encoding: String.Encoding) -> String?Read a String decoding length bytes with encoding from the readerIndex, moving the readerIndex appropriately.
func readUUIDBytes() -> UUID?Read a UUID from the first 16 bytes in the buffer. Advances the reader index.
func setContiguousBytes<Bytes>(Bytes, at: Int) -> IntWrite bytes into this ByteBuffer at index. Does not move the writer index.
func setData<D>(D, at: Int) -> IntWrite the bytes of data into this ByteBuffer at index. Does not move the writer index.
func setJSONEncodable<T>(T, encoder: JSONEncoder, at: Int) throws -> IntEncodes value using the JSONEncoder encoder and set the resulting bytes into this ByteBuffer at the given index.
func setString(String, encoding: String.Encoding, at: Int) throws -> IntWrite string into this ByteBuffer at index using the encoding encoding. Does not move the writer index.
func setUUIDBytes(UUID, at: Int) -> IntSet the bytes of the UUID into this ByteBuffer at index, allocating more storage if necessary. Does not move the writer index.
func writeContiguousBytes<Bytes>(Bytes) -> IntWrite bytes into this ByteBuffer at the writer index, moving the writer index forward appropriately.
func writeJSONEncodable<T>(T, encoder: JSONEncoder) throws -> IntEncodes value using the JSONEncoder encoder and writes the resulting bytes into this ByteBuffer.
func writeString(String, encoding: String.Encoding) throws -> IntWrite string into this ByteBuffer using the encoding encoding, moving the writer index forward appropriately.
func writeUUIDBytes(UUID) -> IntWrite a UUID info the buffer and advances the writer index.