Skip to content

luckymarmot/ZstdKit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ZstdKit

An Objective-C and Swift library for Zstd (Zstandard) compression and decompression.

Installation

Via Cocoapods:

pod 'ZstdKit'

Usage

NSData category

// compression
[myData compressZstd];

// decompression
[myData decompressZstd];

Compressor class

Simple usage

// compression
[LMZstdCompressor compressedDataWithData:myData];

// decompression
[LMZstdCompressor decompressedDataWithData:myData];

Compression level

// compression
[LMZstdCompressor compressedDataWithData:myData compressionLevel:3];

Core Foundation API

CF_EXPORT CFDataRef LMCreateZstdCompressedData(const void* bytes, CFIndex length, int16_t compressionLevel);
CF_EXPORT CFDataRef LMCreateZstdDecompressedData(const void* bytes, CFIndex length);

License

The original Zstandard code is licensed under the BSD license. This code is licensed under the MIT license.

About

An Objective-C and Swift library for Zstd (Zstandard) compression and decompression.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published