MySqlDbaServices
Provides DBA services for MySql.
- Namespace:
- KpokPatagon.Data.MySql.Dba
- Type:
- Class
- Public:
- Yes
- Protected:
- No
- Sealed:
- Yes
- Abstract:
- No
Constructors
Properties
DatabaseApi
Database communication API.
- Signature:
public IDbAccess DatabaseApi { get; }
Methods
ChangeUserPassword
Changes a user password.
- Signature:
public Void ChangeUserPassword(user)
Parameters
Name |
Type |
Summary |
user |
User |
A User to change it's password. |
Exceptions
Type |
Summary |
ArgumentNullException |
Thrown when user is null. |
ValidationException |
Thrown when the provided input is not valid to run this operation. |
SchemaManipulationException |
Thrown when an error occurs while manipulating the schema. |
CreateUser
Creates a user to connect to the database.
- Signature:
public Void CreateUser(user)
Parameters
Name |
Type |
Summary |
user |
User |
A User to be created. |
Exceptions
Type |
Summary |
ArgumentNullException |
Thrown when user is null. |
ValidationException |
Thrown when the provided input is not valid to run this operation. |
SchemaManipulationException |
Thrown when an error occurs while manipulating the schema. |
DropSchema
Creates a schema named name.
- Signature:
public Void DropSchema(name)
Parameters
Name |
Type |
Summary |
name |
String |
Name of the schema to create. |
Exceptions
DropUser
Drops a user.
- Signature:
public Void DropUser(name)
Parameters
Name |
Type |
Summary |
name |
String |
The name of the user to drop. |
Exceptions
ExistsUserc
Checks if a user named name exists.
- Signature:
public Boolean ExistsUserc(name)
Returns
true is the user exists, otherwise false.
Parameters
Name |
Type |
Summary |
name |
String |
Name of the user to check. |
Exceptions
GrantUserAccessToSchema
Grants the user all access to the specified schema.
- Signature:
public Void GrantUserAccessToSchema(user, schema)
Parameters
Name |
Type |
Summary |
user |
String |
User name to grant access to. |
schema |
String |
Schema to grant to the user. |
Exceptions