FMIceLinkDataBufferStream Class Reference

Inherits from NSObject
Declared in FMIceLinkDataBufferStream.h
FMIceLinkDataBufferStream.m

Overview

A data [buffer](#//api/name/buffer) stream.

– available

Gets the available bytes to be read from the DataBuffer.
- (int)available

Discussion

Gets the available bytes to be read from the DataBuffer.

Declared In

FMIceLinkDataBufferStream.h

– bitPosition

Gets the bit [position](#//api/name/position) within a byte.
- (uint8_t)bitPosition

Discussion

Gets the bit [position](#//api/name/position) within a byte.

Declared In

FMIceLinkDataBufferStream.h

– buffer

Gets the buffer.
- (FMIceLinkDataBuffer *)buffer

Discussion

Gets the buffer.

Declared In

FMIceLinkDataBufferStream.h

+ dataBufferStreamWithBuffer:

Initializes a new instance of the FMIceLinkDataBufferStream class.
+ (FMIceLinkDataBufferStream *)dataBufferStreamWithBuffer:(FMIceLinkDataBuffer *)buffer

Parameters

buffer

The buffer.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

+ dataBufferStreamWithDataBufferSize:

Initializes a new instance of the FMIceLinkDataBufferStream class.
+ (FMIceLinkDataBufferStream *)dataBufferStreamWithDataBufferSize:(int)dataBufferSize

Parameters

dataBufferSize

Size of the data buffer.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

+ dataBufferStreamWithDataBufferSize:littleEndian:

Initializes a new instance of the FMIceLinkDataBufferStream class.
+ (FMIceLinkDataBufferStream *)dataBufferStreamWithDataBufferSize:(int)dataBufferSize littleEndian:(bool)littleEndian

Parameters

dataBufferSize

Size of the data buffer.

littleEndian

Whether the data is little-endian.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

– initWithBuffer:

Initializes a new instance of the FMIceLinkDataBufferStream class.
- (instancetype)initWithBuffer:(FMIceLinkDataBuffer *)buffer

Parameters

buffer

The buffer.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

– initWithDataBufferSize:

Initializes a new instance of the FMIceLinkDataBufferStream class.
- (instancetype)initWithDataBufferSize:(int)dataBufferSize

Parameters

dataBufferSize

Size of the data buffer.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

– initWithDataBufferSize:littleEndian:

Initializes a new instance of the FMIceLinkDataBufferStream class.
- (instancetype)initWithDataBufferSize:(int)dataBufferSize littleEndian:(bool)littleEndian

Parameters

dataBufferSize

Size of the data buffer.

littleEndian

Whether the data is little-endian.

Discussion

Initializes a new instance of the FMIceLinkDataBufferStream class.

Declared In

FMIceLinkDataBufferStream.h

– length

Gets the [buffer](#//api/name/buffer) length.
- (int)length

Discussion

Gets the [buffer](#//api/name/buffer) length.

Declared In

FMIceLinkDataBufferStream.h

– nextByte

Resets the bit count to 0 and advances to the next byte.
- (void)nextByte

Discussion

Resets the bit count to 0 and advances to the next byte.

Declared In

FMIceLinkDataBufferStream.h

– peek

Reads an 8-bit value from the DataBuffer without advancing the Position.
- (int)peek

Discussion

Reads an 8-bit value from the DataBuffer without advancing the Position.

Declared In

FMIceLinkDataBufferStream.h

– position

Gets the position within the stream.
- (int)position

Discussion

Gets the position within the stream.

Declared In

FMIceLinkDataBufferStream.h

– read1

Read a single bit and advance the bit [position](#//api/name/position) by 1.
- (bool)read1

Discussion

Read a single bit and advance the bit [position](#//api/name/position) by 1.

Declared In

FMIceLinkDataBufferStream.h

– read15

Reads an 15-bit value from the DataBuffer and advances the Position by 1 and the BitPosition by 7.
- (int)read15

Discussion

Reads an 15-bit value from the DataBuffer and advances the Position by 1 and the BitPosition by 7.

Declared In

FMIceLinkDataBufferStream.h

– read16

Reads an 16-bit value from the DataBuffer and advances the Position by 2.
- (int)read16

Discussion

Reads an 16-bit value from the DataBuffer and advances the Position by 2.

Declared In

FMIceLinkDataBufferStream.h

– read2

Read a 2-bit value and advance the BitPosition by 2.
- (int)read2

Discussion

Read a 2-bit value and advance the BitPosition by 2.

Declared In

FMIceLinkDataBufferStream.h

– read24

Reads an 24-bit value from the DataBuffer and advances the Position by 3.
- (int)read24

Discussion

Reads an 24-bit value from the DataBuffer and advances the Position by 3.

Declared In

FMIceLinkDataBufferStream.h

– read3

Read a 3-bit value and advance the BitPosition by 3.
- (int)read3

Discussion

Read a 3-bit value and advance the BitPosition by 3.

Declared In

FMIceLinkDataBufferStream.h

– read32

Reads an 32-bit value from the DataBuffer and advances the Position by 4.
- (long long)read32

Discussion

Reads an 32-bit value from the DataBuffer and advances the Position by 4.

Declared In

FMIceLinkDataBufferStream.h

– read4

Read a 4-bit value and advance the BitPosition by 4.
- (int)read4

Discussion

Read a 4-bit value and advance the BitPosition by 4.

Declared In

FMIceLinkDataBufferStream.h

– read40

Reads an 40-bit value from the DataBuffer and advances the Position by 5.
- (long long)read40

Discussion

Reads an 40-bit value from the DataBuffer and advances the Position by 5.

Declared In

FMIceLinkDataBufferStream.h

– read48

Reads an 48-bit value from the DataBuffer and advances the Position by 6.
- (long long)read48

Discussion

Reads an 48-bit value from the DataBuffer and advances the Position by 6.

Declared In

FMIceLinkDataBufferStream.h

– read56

Reads an 56-bit value from the DataBuffer and advances the Position by 7.
- (long long)read56

Discussion

Reads an 56-bit value from the DataBuffer and advances the Position by 7.

Declared In

FMIceLinkDataBufferStream.h

– read64

Reads an 64-bit value from the DataBuffer and advances the Position by 8.
- (long long)read64

Discussion

Reads an 64-bit value from the DataBuffer and advances the Position by 8.

Declared In

FMIceLinkDataBufferStream.h

– read7

Reads an 7-bit value from the DataBuffer and advances the BitPosition by 7.
- (int)read7

Discussion

Reads an 7-bit value from the DataBuffer and advances the BitPosition by 7.

Declared In

FMIceLinkDataBufferStream.h

– read8

Reads an 8-bit value from the DataBuffer and advances the Position by 1.
- (int)read8

Discussion

Reads an 8-bit value from the DataBuffer and advances the Position by 1.

Declared In

FMIceLinkDataBufferStream.h

– readByte

Reads a single byte from the stream and advances the Position by 1.
- (int)readByte

Discussion

Reads a single byte from the stream and advances the Position by 1.

Declared In

FMIceLinkDataBufferStream.h

– readBytesWithLength:

Read a specified number of bytes from the DataBuffer and advance the Position by that number.
- (NSMutableData *)readBytesWithLength:(int)length

Parameters

length

The number of bytes to read.

Discussion

Read a specified number of bytes from the DataBuffer and advance the Position by that number.

Declared In

FMIceLinkDataBufferStream.h

– readWithLength:

Reads the specified [length](#//api/name/length) from the DataBuffer and advances the [position](#//api/name/position) by the [length](#//api/name/length).
- (FMIceLinkDataBuffer *)readWithLength:(int)length

Parameters

length

The length.

Discussion

Reads the specified [length](#//api/name/length) from the DataBuffer and advances the [position](#//api/name/position) by the [length](#//api/name/length).

Declared In

FMIceLinkDataBufferStream.h

– setBitPosition:

Sets the bit [position](#//api/name/position) within a byte.
- (void)setBitPosition:(uint8_t)value

Discussion

Sets the bit [position](#//api/name/position) within a byte.

Declared In

FMIceLinkDataBufferStream.h

– setPosition:

Sets the [position](#//api/name/position) within the stream.
- (void)setPosition:(int)value

Discussion

Sets the [position](#//api/name/position) within the stream.

Declared In

FMIceLinkDataBufferStream.h

– write16:

Writes an 16-bit value to the DataBuffer and advances the Position by 2.
- (FMIceLinkDataBufferStream *)write16:(int)value

Parameters

value

The value.

Discussion

Writes an 16-bit value to the DataBuffer and advances the Position by 2.

Declared In

FMIceLinkDataBufferStream.h

– write32:

Writes an 32-bit value to the DataBuffer and advances the Position by 4.
- (FMIceLinkDataBufferStream *)write32:(long long)value

Parameters

value

The value.

Discussion

Writes an 32-bit value to the DataBuffer and advances the Position by 4.

Declared In

FMIceLinkDataBufferStream.h

– write64:

Writes an 64-bit value to the DataBuffer and advances the Position by 8.
- (FMIceLinkDataBufferStream *)write64:(long long)value

Parameters

value

The value.

Discussion

Writes an 64-bit value to the DataBuffer and advances the Position by 8.

Declared In

FMIceLinkDataBufferStream.h

– write8:

Writes an 8-bit value to the DataBuffer and advances the Position by 1.
- (FMIceLinkDataBufferStream *)write8:(int)value

Parameters

value

The value.

Discussion

Writes an 8-bit value to the DataBuffer and advances the Position by 1.

Declared In

FMIceLinkDataBufferStream.h

– writeBytesWithData:

Writes the specified data to the DataBuffer and advances the Position by the [length](#//api/name/length) of the data.
- (FMIceLinkDataBufferStream *)writeBytesWithData:(NSMutableData *)data

Parameters

data

The data.

Discussion

Writes the specified data to the DataBuffer and advances the Position by the [length](#//api/name/length) of the data.

Declared In

FMIceLinkDataBufferStream.h

– writeBytesWithData:index:length:

Writes the specified data to the DataBuffer and advances the Position by the [length](#//api/name/length).
- (FMIceLinkDataBufferStream *)writeBytesWithData:(NSMutableData *)data index:(int)index length:(int)length

Parameters

data

The data.

index

The index.

length

The length.

Discussion

Writes the specified data to the DataBuffer and advances the Position by the [length](#//api/name/length).

Declared In

FMIceLinkDataBufferStream.h

– writeWithBuffer:

Writes the specified [buffer](#//api/name/buffer) to the DataBuffer and advances the Position by the [length](#//api/name/length) of the [buffer](#//api/name/buffer).
- (FMIceLinkDataBufferStream *)writeWithBuffer:(FMIceLinkDataBuffer *)buffer

Parameters

buffer

The buffer.

Discussion

Writes the specified [buffer](#//api/name/buffer) to the DataBuffer and advances the Position by the [length](#//api/name/length) of the [buffer](#//api/name/buffer).

Declared In

FMIceLinkDataBufferStream.h