Example usage for Java com.mongodb MongoCredential fields, constructors, methods, implement or subclass
The text is from its open source code.
String | MONGODB_CR_MECHANISM The MongoDB Challenge Response mechanism. |
String | GSSAPI_MECHANISM The GSSAPI mechanism. |
String | PLAIN_MECHANISM The PLAIN mechanism. |
String | MONGODB_X509_MECHANISM The MongoDB X.509 |
String | SCRAM_SHA_1_MECHANISM The SCRAM-SHA-1 Mechanism. |
MongoCredential(@Nullable final AuthenticationMechanism mechanism, @Nullable final String userName, final String source, @Nullable final char[] password) Constructs a new instance using the given mechanism, userName, source, and password |
MongoCredential | createCredential(final String userName, final String database, final char[] password) Creates a MongoCredential instance with an unspecified mechanism. |
MongoCredential | createGSSAPICredential(final String userName) Creates a MongoCredential instance for the GSSAPI SASL mechanism. |
MongoCredential | createMongoCRCredential(final String userName, final String database, final char[] password) Creates a MongoCredential instance for the MongoDB Challenge Response protocol. |
MongoCredential | createMongoX509Credential(final String userName) Creates a MongoCredential instance for the MongoDB X.509 protocol. |
MongoCredential | createPlainCredential(final String userName, final String source, final char[] password) Creates a MongoCredential instance for the PLAIN SASL mechanism. |
MongoCredential | createScramSha1Credential(final String userName, final String source, final char[] password) Creates a MongoCredential instance for the SCRAM-SHA-1 SASL mechanism. |
String | getMechanism() Gets the mechanism |
char[] | getPassword() Gets the password. |
String | getSource() Gets the source of the user name, typically the name of the database where the user is defined. |
String | getUserName() Gets the user name |