MongoUserDefinitionResource Class
- java.
lang. Object - com.
azure. resourcemanager. cosmos. fluent. models. MongoUserDefinitionResource
- com.
Implements
public final class MongoUserDefinitionResource
implements JsonSerializable<MongoUserDefinitionResource>
Azure Cosmos DB Mongo User Definition resource object.
Constructor Summary
| Constructor | Description |
|---|---|
| MongoUserDefinitionResource() |
Creates an instance of Mongo |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
| String |
customData()
Get the custom |
| String |
databaseName()
Get the database |
|
static
Mongo |
fromJson(JsonReader jsonReader)
Reads an instance of Mongo |
| String |
mechanisms()
Get the mechanisms property: The Mongo Auth mechanism. |
| String |
password()
Get the password property: The password for User Definition. |
| List<Role> |
roles()
Get the roles property: The set of roles inherited by the User Definition. |
|
Json |
toJson(JsonWriter jsonWriter) |
| String |
username()
Get the username property: The user name for User Definition. |
| void |
validate()
Validates the instance. |
|
Mongo |
withCustomData(String customData)
Set the custom |
|
Mongo |
withDatabaseName(String databaseName)
Set the database |
|
Mongo |
withMechanisms(String mechanisms)
Set the mechanisms property: The Mongo Auth mechanism. |
|
Mongo |
withPassword(String password)
Set the password property: The password for User Definition. |
|
Mongo |
withRoles(List<Role> roles)
Set the roles property: The set of roles inherited by the User Definition. |
|
Mongo |
withUsername(String username)
Set the username property: The user name for User Definition. |
Methods inherited from java.lang.Object
Constructor Details
MongoUserDefinitionResource
public MongoUserDefinitionResource()
Creates an instance of MongoUserDefinitionResource class.
Method Details
customData
public String customData()
Get the customData property: A custom definition for the USer Definition.
Returns:
databaseName
public String databaseName()
Get the databaseName property: The database name for which access is being granted for this User Definition.
Returns:
fromJson
public static MongoUserDefinitionResource fromJson(JsonReader jsonReader)
Reads an instance of MongoUserDefinitionResource from the JsonReader.
Parameters:
Returns:
Throws:
mechanisms
public String mechanisms()
Get the mechanisms property: The Mongo Auth mechanism. For now, we only support auth mechanism SCRAM-SHA-256.
Returns:
password
public String password()
Get the password property: The password for User Definition. Response does not contain user password.
Returns:
roles
public List<Role> roles()
Get the roles property: The set of roles inherited by the User Definition.
Returns:
toJson
username
public String username()
Get the username property: The user name for User Definition.
Returns:
validate
public void validate()
Validates the instance.
withCustomData
public MongoUserDefinitionResource withCustomData(String customData)
Set the customData property: A custom definition for the USer Definition.
Parameters:
Returns:
withDatabaseName
public MongoUserDefinitionResource withDatabaseName(String databaseName)
Set the databaseName property: The database name for which access is being granted for this User Definition.
Parameters:
Returns:
withMechanisms
public MongoUserDefinitionResource withMechanisms(String mechanisms)
Set the mechanisms property: The Mongo Auth mechanism. For now, we only support auth mechanism SCRAM-SHA-256.
Parameters:
Returns:
withPassword
public MongoUserDefinitionResource withPassword(String password)
Set the password property: The password for User Definition. Response does not contain user password.
Parameters:
Returns:
withRoles
public MongoUserDefinitionResource withRoles(List<Role> roles)
Set the roles property: The set of roles inherited by the User Definition.
Parameters:
Returns:
withUsername
public MongoUserDefinitionResource withUsername(String username)
Set the username property: The user name for User Definition.
Parameters:
Returns: