Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-3778

Add a Filters.empty() method

    XMLWordPrintableJSON

Details

    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.2.0
    • None
    • Builders
    • None
    • Needed
    • Hide

      Documentation changes have been made as part of the commit, but will need to be ported over to the new documentation site.

      Show
      Documentation changes have been made as part of the commit, but will need to be ported over to the new documentation site.

    Description

      At the moment I need to write the following:

       

      exampleCollection.updateMany(new Document(), set("status", status))
      

      It would be a lot more self-descriptive to use a method like Filters.empty() to achieve the same result:

       

       

      exampleCollection.updateMany(empty(), set("status", status))
      

       

       

      Attachments

        Activity

          People

            brian.deleonardis@mongodb.com Brian DeLeonardis (Inactive)
            laxika91@gmail.com Gyula Lakatos
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: