C# Класс ALFA.MySQLDatabaseInternal

This wrapper class shields callers of MySQLDatabase from needing to immediately demand that the MySql.Data.dll assembly be loaded.
Наследование: IDisposable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
ACR_SQLEncodeSpecialChars ( string s ) : string

This routine escapes characters for a SQL query.

ACR_SQLExecute ( string SQL ) : void

This routine performs a synchronous SQL query. If there were pending asynchronous queries in the queue, the pending queries are drained first. The query must not return any results.

ACR_SQLFetch ( ) : bool

This routine fetches the next rowset from the database.

ACR_SQLGetAffectedRows ( ) : int

This routine returns the number of rows affected by a query.

ACR_SQLGetData ( ) : string

This routine returns the first column of data from the current SQL rowset.

ACR_SQLGetData ( int ColumnIndex ) : string

This routine returns the specified column of data from the current SQL rowset.

ACR_SQLQuery ( string SQL ) : void

This routine performs a synchronous SQL query. If there were pending asynchronous queries in the queue, the pending queries are drained first.

Dispose ( ) : void

Dispose the object.

Приватные методы

Метод Описание
ACR_SQLNextResult ( ) : bool

This routine advances to the next result set of a multi-result query.

ConnectDatabase ( ) : void

Connect a dedicated connection to the database.

Dispose ( bool Disposing ) : void

Dispose the object.

MySQLDatabaseInternal ( string ConnectionString = null, bool Dedicated = false ) : System

Create a new MySQLDatabaseInternal object.

PrepareSQL ( string SQL ) : string

Prepare a query string for execution. Currently, this prepends a USE DatabaseName; statement to improve latency (see discussion below with DatabaseName).

SetupConnectionString ( ) : void

This method sets up the database connection string based on the default connection information set for the MySQL plugin. The pool size of 3 is based on : - One connection for polling for input by the GameWorldManager synchronization thread. - One connection for background ad-hoc queries kicked off by the server communicator on work items (account record lookup, etc.). - One connection for miscellaneous use.

Описание методов

ACR_SQLEncodeSpecialChars() публичный метод

This routine escapes characters for a SQL query.
public ACR_SQLEncodeSpecialChars ( string s ) : string
s string Supplies the string to escape.
Результат string

ACR_SQLExecute() публичный метод

This routine performs a synchronous SQL query. If there were pending asynchronous queries in the queue, the pending queries are drained first. The query must not return any results.
public ACR_SQLExecute ( string SQL ) : void
SQL string Supplies the SQL query text to execute.
Результат void

ACR_SQLFetch() публичный метод

This routine fetches the next rowset from the database.
public ACR_SQLFetch ( ) : bool
Результат bool

ACR_SQLGetAffectedRows() публичный метод

This routine returns the number of rows affected by a query.
public ACR_SQLGetAffectedRows ( ) : int
Результат int

ACR_SQLGetData() публичный метод

This routine returns the first column of data from the current SQL rowset.
public ACR_SQLGetData ( ) : string
Результат string

ACR_SQLGetData() публичный метод

This routine returns the specified column of data from the current SQL rowset.
public ACR_SQLGetData ( int ColumnIndex ) : string
ColumnIndex int Supplies the zero-based column index to /// retrieve.
Результат string

ACR_SQLQuery() публичный метод

This routine performs a synchronous SQL query. If there were pending asynchronous queries in the queue, the pending queries are drained first.
public ACR_SQLQuery ( string SQL ) : void
SQL string Supplies the SQL query text to execute.
Результат void

Dispose() публичный метод

Dispose the object.
public Dispose ( ) : void
Результат void