Structure
MySQLConfiguration
A set of parameters used to connect to a MySQL database.
struct MySQLConfiguration
Topics
Initializers
init(hostname: String, port: Int, username: String, password: String, database: String?, tlsConfiguration: TLSConfiguration?)Create aMySQLConfigurationfor connecting to a server with a hostname and optional port.init(unixDomainSocketPath: String, username: String, password: String, database: String?)Create aMySQLConfigurationfor connecting to a server through a UNIX domain socket.init(unixDomainSocketPath: String, username: String, password: String, database: String?, tlsConfiguration: TLSConfiguration?)Create aMySQLConfigurationfor connecting to a server through a UNIX domain socket.init(url:)Create aMySQLConfigurationfrom an appropriately-formatted URL string.
Instance Properties
var address: () throws -> SocketAddressA closure which returns the NIOSocketAddressfor a server.var database: String?An optional initial default database for the connection.var password: StringThe password used to authenticate the connection. May be an empty string.var tlsConfiguration: TLSConfiguration?Optional configuration for TLS-based connection encryption.var username: StringThe username used to authenticate the connection.
Type Properties
static var ianaPortNumber: IntThe IANA-assigned port number for MySQL (3306).
Relationships
Conforms To
Swift.SendableSwift.SendableMetatype