Create a ServerAddress with default host

XMLWordPrintableJSON

    • Type: New Feature
    • Resolution: Won't Fix
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: API
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Hello,

      Add a constructor that creates a ServerAddress with default host (127.0.0.1)

         /**
           * Creates a ServerAddress with default host
           *
           * @param port mongod port
           */
          public ServerAddress(final int port) { this(defaultHost(), port); }
      

      Usage :

      new ServerAddress(27018);
      

      Farès

            Assignee:
            Unassigned
            Reporter:
            Farès Hassak
            None
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: