SwiftlyS2

IDatabaseService

Interface IDatabaseService

Namespace: SwiftlyS2.Shared.Database

Assembly: SwiftlyS2.CS2.dll

public interface IDatabaseService

Methods

GetConnection(string)

Get a connection to the database.

IDbConnection GetConnection(string connectionName)
Parameters
  • connectionName string — The name of the connection to get the connection for.
Returns
  • IDbConnection — A connection to the database. Return the default connection if the connection name is not found.

GetConnectionString(string)

Get the connection string for a given connection name.

string GetConnectionString(string connectionName)
Parameters
  • connectionName string — The name of the connection to get the connection string for.
Returns
  • string — The connection string for the given connection name. Return the default connection string if the connection name is not found.

On this page