ROZlib

Overview

This class is a simple Objective C wrapper around ZLib compression library. It allows to compress and decompress the data easily eliminating the need to operate with C language functions and data structures.
The class is used to provide ROBinMessage class with the data compression ability.

Location

Class Methods


zlibDeflateData:fromOffset:toData:

+ (void) zlibDeflateData:(NSData *)sourceData fromOffset:(long)aOffset toData:(NSMutableData *)aData

Parameters:

  • sourceData:
  • aOffset:
  • aData:

zlibDeflateData:toData:

+ (void) zlibDeflateData:(NSData *)sourceData toData:(NSMutableData *)targetData

Parameters:

  • sourceData:
  • targetData:

zlibInflateData:fromOffset:

Decompresses the data passed to the method starting with the specified offset. Returns the data object with the decompressed data.

+ (NSData *) zlibInflateData:(NSData *)data fromOffset:(long)aOffset

Parameters:

  • data: The data to decompress.
  • aOffset: The offset in the input data to start decompression from.

zlibInflateData:fromOffset:toData:

+ (unsigned long) zlibInflateData:(NSData *)data fromOffset:(long)aOffset toData:(NSData * *)aOutData

Parameters:

  • data:
  • aOffset:
  • aOutData: