Welcome

Initializing Livebox

Using Livebox is a fairly straight forward process, in you Application class call:

// Pass context and wanted serializer. 
// This creates a Livebox instance with default values. 
Livebox.init(this, LiveboxGsonSerializer.create());

Built-in support for Gson and Jackson.

You can pass a Config instance to fully customize Livebox behaviour.

Livebox.init(new Config()
                .lruCacheConfig(new DiskLruDataSource.Config(
                        new File("somePath") // Cache file path
                         10 * 1024 * 1024// Cache size in bytes
                ))
                .addSerializer(LiveboxGsonSerializer.create())
                ...
        );

Please check Configuration page for more details.

Configuration

Last updated