Class ListDatabasesOperation<T>

    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      BatchCursor<T> execute​(ReadBinding binding)
      Deprecated.
      Executing this will return a list of all the databases names in the MongoDB instance.
      void executeAsync​(AsyncReadBinding binding, SingleResultCallback<AsyncBatchCursor<T>> callback)
      Deprecated.
      General execute which can return anything of type T
      ListDatabasesOperation<T> filter​(BsonDocument filter)
      Deprecated.
      Sets the query filter to apply to the returned database names.
      BsonDocument getFilter()
      Deprecated.
      Gets the query filter to apply to the returned database names.
      long getMaxTime​(java.util.concurrent.TimeUnit timeUnit)
      Deprecated.
      Gets the maximum execution time on the server for this operation.
      java.lang.Boolean getNameOnly()
      Deprecated.
      Gets the nameOnly flag that indicates whether the command should return just the database names or return the database names and size information.
      boolean getRetryReads()
      Deprecated.
      Gets the value for retryable reads.
      ListDatabasesOperation<T> maxTime​(long maxTime, java.util.concurrent.TimeUnit timeUnit)
      Deprecated.
      Sets the maximum execution time on the server for this operation.
      ListDatabasesOperation<T> nameOnly​(java.lang.Boolean nameOnly)
      Deprecated.
      Sets the nameOnly flag that indicates whether the command should return just the database names or return the database names and size information.
      ListDatabasesOperation<T> retryReads​(boolean retryReads)
      Deprecated.
      Enables retryable reads if a read fails due to a network error.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ListDatabasesOperation

        public ListDatabasesOperation​(Decoder<T> decoder)
        Deprecated.
        Construct a new instance.
        Parameters:
        decoder - the decoder to use for the results
    • Method Detail

      • getMaxTime

        public long getMaxTime​(java.util.concurrent.TimeUnit timeUnit)
        Deprecated.
        Gets the maximum execution time on the server for this operation. The default is 0, which places no limit on the execution time.
        Parameters:
        timeUnit - the time unit to return the result in
        Returns:
        the maximum execution time in the given time unit
      • maxTime

        public ListDatabasesOperation<T> maxTime​(long maxTime,
                                                 java.util.concurrent.TimeUnit timeUnit)
        Deprecated.
        Sets the maximum execution time on the server for this operation.
        Parameters:
        maxTime - the max time
        timeUnit - the time unit, which may not be null
        Returns:
        this
      • filter

        public ListDatabasesOperation<T> filter​(BsonDocument filter)
        Deprecated.
        Sets the query filter to apply to the returned database names.
        Parameters:
        filter - the filter, which may be null.
        Returns:
        this
        Since:
        3.6
      • getFilter

        public BsonDocument getFilter()
        Deprecated.
        Gets the query filter to apply to the returned database names.
        Returns:
        this
        Since:
        3.6
      • nameOnly

        public ListDatabasesOperation<T> nameOnly​(java.lang.Boolean nameOnly)
        Deprecated.
        Sets the nameOnly flag that indicates whether the command should return just the database names or return the database names and size information.
        Parameters:
        nameOnly - the nameOnly flag, which may be null
        Returns:
        this
        Since:
        3.6
      • retryReads

        public ListDatabasesOperation<T> retryReads​(boolean retryReads)
        Deprecated.
        Enables retryable reads if a read fails due to a network error.
        Parameters:
        retryReads - true if reads should be retried
        Returns:
        this
        Since:
        3.11
      • getRetryReads

        public boolean getRetryReads()
        Deprecated.
        Gets the value for retryable reads. The default is true.
        Returns:
        the retryable reads value
        Since:
        3.11
      • getNameOnly

        public java.lang.Boolean getNameOnly()
        Deprecated.
        Gets the nameOnly flag that indicates whether the command should return just the database names or return the database names and size information.
        Returns:
        this
        Since:
        3.6
      • execute

        public BatchCursor<T> execute​(ReadBinding binding)
        Deprecated.
        Executing this will return a list of all the databases names in the MongoDB instance.
        Specified by:
        execute in interface ReadOperation<T>
        Parameters:
        binding - the binding.
        Returns:
        a List of Strings of the names of all the databases in the MongoDB instance.