/** * Rx version of {@link #add(String, ChunkMeta, String, IndexMeta, Handler)} * @param chunk the chunk to add * @param chunkMeta the chunk's metadata * @param path the path where the chunk should be stored (may be null) * @param indexMeta metadata affecting the way the chunk will be indexed * @return a Completable that completes when the operation has finished */ public Completable rxAdd(String chunk, ChunkMeta chunkMeta, String path, IndexMeta indexMeta) { return Single.create(new SingleOnSubscribeAdapter<Void>(f -> add(chunk, chunkMeta, path, indexMeta, f))).toCompletable(); }