io.vertx.reactivex.ext.mongo

## Class MongoGridFsClient

- java.lang.Object
- - io.vertx.reactivex.ext.mongo.MongoGridFsClient

-     public class MongoGridFsClient
      extends Object

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static io.vertx.lang.rx.TypeArg<MongoGridFsClient>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `MongoGridFsClient(MongoGridFsClient delegate)`
    `MongoGridFsClient(Object delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()` Close the client and release its resources
    `MongoGridFsClient` | `delete(String id)` Deletes a file by it's ID
    `MongoGridFsClient` | `delete(String id, Handler<AsyncResult<Void>> resultHandler)` Deletes a file by it's ID
    `MongoGridFsClient` | `downloadByFileName(WriteStream<Buffer> stream, String fileName)`
    `MongoGridFsClient` | `downloadByFileName(WriteStream<Buffer> stream, String fileName, Handler<AsyncResult<Long>> resultHandler)`
    `MongoGridFsClient` | `downloadByFileNameWithOptions(WriteStream<Buffer> stream, String fileName, GridFsDownloadOptions options)`
    `MongoGridFsClient` | `downloadByFileNameWithOptions(WriteStream<Buffer> stream, String fileName, GridFsDownloadOptions options, Handler<AsyncResult<Long>> resultHandler)`
    `MongoGridFsClient` | `downloadById(WriteStream<Buffer> stream, String id)`
    `MongoGridFsClient` | `downloadById(WriteStream<Buffer> stream, String id, Handler<AsyncResult<Long>> resultHandler)`
    `MongoGridFsClient` | `downloadFile(String fileName)` Downloads a file.
    `MongoGridFsClient` | `downloadFile(String fileName, Handler<AsyncResult<Long>> resultHandler)` Downloads a file.
    `MongoGridFsClient` | `downloadFileAs(String fileName, String newFileName)` Downloads a file and gives it a new name.
    `MongoGridFsClient` | `downloadFileAs(String fileName, String newFileName, Handler<AsyncResult<Long>> resultHandler)` Downloads a file and gives it a new name.
    `MongoGridFsClient` | `downloadFileByID(String id, String fileName)` Downloads a file using the ID generated by GridFs.
    `MongoGridFsClient` | `downloadFileByID(String id, String fileName, Handler<AsyncResult<Long>> resultHandler)` Downloads a file using the ID generated by GridFs.
    `MongoGridFsClient` | `drop()` Drops the entire file bucket with all of its contents
    `MongoGridFsClient` | `drop(Handler<AsyncResult<Void>> resultHandler)` Drops the entire file bucket with all of its contents
    `boolean` | `equals(Object o)`
    `MongoGridFsClient` | `findAllIds()` Finds all file ids in the bucket
    `MongoGridFsClient` | `findAllIds(Handler<AsyncResult<List<String>>> resultHandler)` Finds all file ids in the bucket
    `MongoGridFsClient` | `findIds(JsonObject query)` Finds all file ids that match a query.
    `MongoGridFsClient` | `findIds(JsonObject query, Handler<AsyncResult<List<String>>> resultHandler)` Finds all file ids that match a query.
    `MongoGridFsClient` | `getDelegate()`
    `int` | `hashCode()`
    `static MongoGridFsClient` | `newInstance(MongoGridFsClient arg)`
    `Completable` | `rxDelete(String id)` Deletes a file by it's ID
    `Single<Long>` | `rxDownloadByFileName(WriteStream<Buffer> stream, String fileName)`
    `Single<Long>` | `rxDownloadByFileNameWithOptions(WriteStream<Buffer> stream, String fileName, GridFsDownloadOptions options)`
    `Single<Long>` | `rxDownloadById(WriteStream<Buffer> stream, String id)`
    `Single<Long>` | `rxDownloadFile(String fileName)` Downloads a file.
    `Single<Long>` | `rxDownloadFileAs(String fileName, String newFileName)` Downloads a file and gives it a new name.
    `Single<Long>` | `rxDownloadFileByID(String id, String fileName)` Downloads a file using the ID generated by GridFs.
    `Completable` | `rxDrop()` Drops the entire file bucket with all of its contents
    `Single<List<String>>` | `rxFindAllIds()` Finds all file ids in the bucket
    `Single<List<String>>` | `rxFindIds(JsonObject query)` Finds all file ids that match a query.
    `Single<String>` | `rxUploadByFileName(Flowable<Buffer> stream, String fileName)`
    `Single<String>` | `rxUploadByFileName(ReadStream<Buffer> stream, String fileName)`
    `Single<String>` | `rxUploadByFileNameWithOptions(Flowable<Buffer> stream, String fileName, GridFsUploadOptions options)`
    `Single<String>` | `rxUploadByFileNameWithOptions(ReadStream<Buffer> stream, String fileName, GridFsUploadOptions options)`
    `Single<String>` | `rxUploadFile(String fileName)` Upload a file to gridfs
    `Single<String>` | `rxUploadFileWithOptions(String fileName, GridFsUploadOptions options)` Upload a file to gridfs with options
    `String` | `toString()`
    `MongoGridFsClient` | `uploadByFileName(Flowable<Buffer> stream, String fileName)`
    `MongoGridFsClient` | `uploadByFileName(Flowable<Buffer> stream, String fileName, Handler<AsyncResult<String>> resultHandler)`
    `MongoGridFsClient` | `uploadByFileName(ReadStream<Buffer> stream, String fileName)`
    `MongoGridFsClient` | `uploadByFileName(ReadStream<Buffer> stream, String fileName, Handler<AsyncResult<String>> resultHandler)`
    `MongoGridFsClient` | `uploadByFileNameWithOptions(Flowable<Buffer> stream, String fileName, GridFsUploadOptions options)`
    `MongoGridFsClient` | `uploadByFileNameWithOptions(Flowable<Buffer> stream, String fileName, GridFsUploadOptions options, Handler<AsyncResult<String>> resultHandler)`
    `MongoGridFsClient` | `uploadByFileNameWithOptions(ReadStream<Buffer> stream, String fileName, GridFsUploadOptions options)`
    `MongoGridFsClient` | `uploadByFileNameWithOptions(ReadStream<Buffer> stream, String fileName, GridFsUploadOptions options, Handler<AsyncResult<String>> resultHandler)`
    `MongoGridFsClient` | `uploadFile(String fileName)` Upload a file to gridfs
    `MongoGridFsClient` | `uploadFile(String fileName, Handler<AsyncResult<String>> resultHandler)` Upload a file to gridfs
    `MongoGridFsClient` | `uploadFileWithOptions(String fileName, GridFsUploadOptions options)` Upload a file to gridfs with options
    `MongoGridFsClient` | `uploadFileWithOptions(String fileName, GridFsUploadOptions options, Handler<AsyncResult<String>> resultHandler)` Upload a file to gridfs with options

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### __TYPE_ARG

          public static final io.vertx.lang.rx.TypeArg<MongoGridFsClient> __TYPE_ARG

  - ### Constructor Detail

    - #### MongoGridFsClient

          public MongoGridFsClient(MongoGridFsClient delegate)

    - #### MongoGridFsClient

          public MongoGridFsClient(Object delegate)

  - ### Method Detail

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### getDelegate

          public MongoGridFsClient getDelegate()

    - #### delete

          public MongoGridFsClient delete(String id,
                                          Handler<AsyncResult<Void>> resultHandler)

      Deletes a file by it's ID
      Parameters:
        `id` - the identifier of the file
        `resultHandler` - will be called when the file is deleted
      Returns:

    - #### delete

          public MongoGridFsClient delete(String id)

      Deletes a file by it's ID
      Parameters:
        `id` - the identifier of the file
      Returns:

    - #### rxDelete

          public Completable rxDelete(String id)

      Deletes a file by it's ID
      Parameters:
        `id` - the identifier of the file
      Returns:

    - #### downloadByFileName

          public MongoGridFsClient downloadByFileName(WriteStream<Buffer> stream,
                                                      String fileName,
                                                      Handler<AsyncResult<Long>> resultHandler)

    - #### downloadByFileName

          public MongoGridFsClient downloadByFileName(WriteStream<Buffer> stream,
                                                      String fileName)

    - #### rxDownloadByFileName

          public Single<Long> rxDownloadByFileName(WriteStream<Buffer> stream,
                                                   String fileName)

    - #### downloadByFileNameWithOptions

          public MongoGridFsClient downloadByFileNameWithOptions(WriteStream<Buffer> stream,
                                                                 String fileName,
                                                                 GridFsDownloadOptions options,
                                                                 Handler<AsyncResult<Long>> resultHandler)

    - #### downloadByFileNameWithOptions

          public MongoGridFsClient downloadByFileNameWithOptions(WriteStream<Buffer> stream,
                                                                 String fileName,
                                                                 GridFsDownloadOptions options)

    - #### rxDownloadByFileNameWithOptions

          public Single<Long> rxDownloadByFileNameWithOptions(WriteStream<Buffer> stream,
                                                              String fileName,
                                                              GridFsDownloadOptions options)

    - #### downloadById

          public MongoGridFsClient downloadById(WriteStream<Buffer> stream,
                                                String id,
                                                Handler<AsyncResult<Long>> resultHandler)

    - #### downloadById

          public MongoGridFsClient downloadById(WriteStream<Buffer> stream,
                                                String id)

    - #### rxDownloadById

          public Single<Long> rxDownloadById(WriteStream<Buffer> stream,
                                             String id)

    - #### downloadFile

          public MongoGridFsClient downloadFile(String fileName,
                                                Handler<AsyncResult<Long>> resultHandler)

      Downloads a file.
      Parameters:
        `fileName` - the name of the file to download
        `resultHandler` - called when the file is downloaded and returns the length in bytes
      Returns:

    - #### downloadFile

          public MongoGridFsClient downloadFile(String fileName)

      Downloads a file.
      Parameters:
        `fileName` - the name of the file to download
      Returns:

    - #### rxDownloadFile

          public Single<Long> rxDownloadFile(String fileName)

      Downloads a file.
      Parameters:
        `fileName` - the name of the file to download
      Returns:

    - #### downloadFileAs

          public MongoGridFsClient downloadFileAs(String fileName,
                                                  String newFileName,
                                                  Handler<AsyncResult<Long>> resultHandler)

      Downloads a file and gives it a new name.
      Parameters:
        `fileName` - the name of the file to download
        `newFileName` - the name the file should be saved as
        `resultHandler` - called when the file is downloaded and returns the length in bytes
      Returns:

    - #### downloadFileAs

          public MongoGridFsClient downloadFileAs(String fileName,
                                                  String newFileName)

      Downloads a file and gives it a new name.
      Parameters:
        `fileName` - the name of the file to download
        `newFileName` - the name the file should be saved as
      Returns:

    - #### rxDownloadFileAs

          public Single<Long> rxDownloadFileAs(String fileName,
                                               String newFileName)

      Downloads a file and gives it a new name.
      Parameters:
        `fileName` - the name of the file to download
        `newFileName` - the name the file should be saved as
      Returns:

    - #### downloadFileByID

          public MongoGridFsClient downloadFileByID(String id,
                                                    String fileName,
                                                    Handler<AsyncResult<Long>> resultHandler)

      Downloads a file using the ID generated by GridFs.
      Parameters:
        `id` - the GridFs Object ID of the file to download
        `fileName` -
        `resultHandler` - called when the file is downloaded and returns the length in bytes
      Returns:

    - #### downloadFileByID

          public MongoGridFsClient downloadFileByID(String id,
                                                    String fileName)

      Downloads a file using the ID generated by GridFs.
      Parameters:
        `id` - the GridFs Object ID of the file to download
        `fileName` -
      Returns:

    - #### rxDownloadFileByID

          public Single<Long> rxDownloadFileByID(String id,
                                                 String fileName)

      Downloads a file using the ID generated by GridFs.
      Parameters:
        `id` - the GridFs Object ID of the file to download
        `fileName` -
      Returns:

    - #### drop

          public MongoGridFsClient drop(Handler<AsyncResult<Void>> resultHandler)

      Drops the entire file bucket with all of its contents
      Parameters:
        `resultHandler` - called when the bucket is dropped
      Returns:

    - #### drop

          public MongoGridFsClient drop()

      Drops the entire file bucket with all of its contents
      Returns:

    - #### rxDrop

          public Completable rxDrop()

      Drops the entire file bucket with all of its contents
      Returns:

    - #### findAllIds

          public MongoGridFsClient findAllIds(Handler<AsyncResult<List<String>>> resultHandler)

      Finds all file ids in the bucket
      Parameters:
        `resultHandler` - called when the list of file ids is available
      Returns:

    - #### findAllIds

          public MongoGridFsClient findAllIds()

      Finds all file ids in the bucket
      Returns:

    - #### rxFindAllIds

          public Single<List<String>> rxFindAllIds()

      Finds all file ids in the bucket
      Returns:

    - #### findIds

          public MongoGridFsClient findIds(JsonObject query,
                                           Handler<AsyncResult<List<String>>> resultHandler)

      Finds all file ids that match a query.
      Parameters:
        `query` - a bson query expressed as json that will be used to match files
        `resultHandler` - called when the list of file ids is available
      Returns:

    - #### findIds

          public MongoGridFsClient findIds(JsonObject query)

      Finds all file ids that match a query.
      Parameters:
        `query` - a bson query expressed as json that will be used to match files
      Returns:

    - #### rxFindIds

          public Single<List<String>> rxFindIds(JsonObject query)

      Finds all file ids that match a query.
      Parameters:
        `query` - a bson query expressed as json that will be used to match files
      Returns:

    - #### uploadByFileName

          public MongoGridFsClient uploadByFileName(ReadStream<Buffer> stream,
                                                    String fileName,
                                                    Handler<AsyncResult<String>> resultHandler)

    - #### uploadByFileName

          public MongoGridFsClient uploadByFileName(ReadStream<Buffer> stream,
                                                    String fileName)

    - #### rxUploadByFileName

          public Single<String> rxUploadByFileName(ReadStream<Buffer> stream,
                                                   String fileName)

    - #### uploadByFileName

          public MongoGridFsClient uploadByFileName(Flowable<Buffer> stream,
                                                    String fileName,
                                                    Handler<AsyncResult<String>> resultHandler)

    - #### uploadByFileName

          public MongoGridFsClient uploadByFileName(Flowable<Buffer> stream,
                                                    String fileName)

    - #### rxUploadByFileName

          public Single<String> rxUploadByFileName(Flowable<Buffer> stream,
                                                   String fileName)

    - #### uploadByFileNameWithOptions

          public MongoGridFsClient uploadByFileNameWithOptions(ReadStream<Buffer> stream,
                                                               String fileName,
                                                               GridFsUploadOptions options,
                                                               Handler<AsyncResult<String>> resultHandler)

    - #### uploadByFileNameWithOptions

          public MongoGridFsClient uploadByFileNameWithOptions(ReadStream<Buffer> stream,
                                                               String fileName,
                                                               GridFsUploadOptions options)

    - #### rxUploadByFileNameWithOptions

          public Single<String> rxUploadByFileNameWithOptions(ReadStream<Buffer> stream,
                                                              String fileName,
                                                              GridFsUploadOptions options)

    - #### uploadByFileNameWithOptions

          public MongoGridFsClient uploadByFileNameWithOptions(Flowable<Buffer> stream,
                                                               String fileName,
                                                               GridFsUploadOptions options,
                                                               Handler<AsyncResult<String>> resultHandler)

    - #### uploadByFileNameWithOptions

          public MongoGridFsClient uploadByFileNameWithOptions(Flowable<Buffer> stream,
                                                               String fileName,
                                                               GridFsUploadOptions options)

    - #### rxUploadByFileNameWithOptions

          public Single<String> rxUploadByFileNameWithOptions(Flowable<Buffer> stream,
                                                              String fileName,
                                                              GridFsUploadOptions options)

    - #### uploadFile

          public MongoGridFsClient uploadFile(String fileName,
                                              Handler<AsyncResult<String>> resultHandler)

      Upload a file to gridfs
      Parameters:
        `fileName` - the name of the file to store in gridfs
        `resultHandler` - the id of the file that was uploaded
      Returns:

    - #### uploadFile

          public MongoGridFsClient uploadFile(String fileName)

      Upload a file to gridfs
      Parameters:
        `fileName` - the name of the file to store in gridfs
      Returns:

    - #### rxUploadFile

          public Single<String> rxUploadFile(String fileName)

      Upload a file to gridfs
      Parameters:
        `fileName` - the name of the file to store in gridfs
      Returns:

    - #### uploadFileWithOptions

          public MongoGridFsClient uploadFileWithOptions(String fileName,
                                                         GridFsUploadOptions options,
                                                         Handler<AsyncResult<String>> resultHandler)

      Upload a file to gridfs with options
      Parameters:
        `fileName` - the name of the file to store in gridfs
        `options` - `GridFsUploadOptions` for specifying metadata and chunk size
        `resultHandler` - the id of the file that was uploaded
      Returns:

    - #### uploadFileWithOptions

          public MongoGridFsClient uploadFileWithOptions(String fileName,
                                                         GridFsUploadOptions options)

      Upload a file to gridfs with options
      Parameters:
        `fileName` - the name of the file to store in gridfs
        `options` - `GridFsUploadOptions` for specifying metadata and chunk size
      Returns:

    - #### rxUploadFileWithOptions

          public Single<String> rxUploadFileWithOptions(String fileName,
                                                        GridFsUploadOptions options)

      Upload a file to gridfs with options
      Parameters:
        `fileName` - the name of the file to store in gridfs
        `options` - `GridFsUploadOptions` for specifying metadata and chunk size
      Returns:

    - #### close

          public void close()

      Close the client and release its resources

    - #### newInstance

          public static MongoGridFsClient newInstance(MongoGridFsClient arg)

Copyright © 2022 Eclipse. All rights reserved.