Package com.mongodb

Class MongoSocketException

All Implemented Interfaces:
Serializable
Direct Known Subclasses:
MongoSocketClosedException, MongoSocketOpenException, MongoSocketReadException, MongoSocketReadTimeoutException, MongoSocketWriteException

public class MongoSocketException extends MongoException
Subclass of MongoException representing a network-related exception
Since:
2.12
  • Constructor Details

    • MongoSocketException

      public MongoSocketException(String message, ServerAddress serverAddress)
      Construct a new instance.
      Parameters:
      message - the message
      serverAddress - the address
  • Method Details

    • getServerAddress

      public ServerAddress getServerAddress()
      Gets the server address for this exception.
      Returns:
      the address