Trait sqlx::ConnectOptions [−][src]
Associated Types
type Connection: Connection + ?Sized
[src]
Required methods
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<Self::Connection, Error>> + Send, Global>> where
Self::Connection: Sized,
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<Self::Connection, Error>> + Send, Global>> where
Self::Connection: Sized,
Establish a new database connection with the options specified by self
.
pub fn log_statements(&mut self, level: LevelFilter) -> &mut Self
[src]
Log executed statements with the specified level
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut Self
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut Self
Log executed statements with a duration above the specified duration
at the specified level
.
Provided methods
pub fn disable_statement_logging(&mut self) -> &mut Self
[src]
Entirely disables statement logging (both slow and regular).
Implementors
impl ConnectOptions for AnyConnectOptions
[src]
type Connection = AnyConnection
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<AnyConnection, Error>> + Send, Global>>
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<AnyConnection, Error>> + Send, Global>>
pub fn log_statements(&mut self, level: LevelFilter) -> &mut AnyConnectOptions
[src]
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut AnyConnectOptions
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut AnyConnectOptions
impl ConnectOptions for MssqlConnectOptions
[src]
type Connection = MssqlConnection
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<<MssqlConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<MssqlConnectOptions as ConnectOptions>::Connection: Sized,
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<<MssqlConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<MssqlConnectOptions as ConnectOptions>::Connection: Sized,
pub fn log_statements(&mut self, level: LevelFilter) -> &mut MssqlConnectOptions
[src]
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut MssqlConnectOptions
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut MssqlConnectOptions
impl ConnectOptions for MySqlConnectOptions
[src]
type Connection = MySqlConnection
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<<MySqlConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<MySqlConnectOptions as ConnectOptions>::Connection: Sized,
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<<MySqlConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<MySqlConnectOptions as ConnectOptions>::Connection: Sized,
pub fn log_statements(&mut self, level: LevelFilter) -> &mut MySqlConnectOptions
[src]
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut MySqlConnectOptions
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut MySqlConnectOptions
impl ConnectOptions for PgConnectOptions
[src]
type Connection = PgConnection
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<<PgConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<PgConnectOptions as ConnectOptions>::Connection: Sized,
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<<PgConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<PgConnectOptions as ConnectOptions>::Connection: Sized,
pub fn log_statements(&mut self, level: LevelFilter) -> &mut PgConnectOptions
[src]
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut PgConnectOptions
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut PgConnectOptions
impl ConnectOptions for SqliteConnectOptions
[src]
type Connection = SqliteConnection
pub fn connect(
&self
) -> Pin<Box<dyn Future<Output = Result<<SqliteConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<SqliteConnectOptions as ConnectOptions>::Connection: Sized,
[src]
&self
) -> Pin<Box<dyn Future<Output = Result<<SqliteConnectOptions as ConnectOptions>::Connection, Error>> + Send, Global>> where
<SqliteConnectOptions as ConnectOptions>::Connection: Sized,
pub fn log_statements(
&mut self,
level: LevelFilter
) -> &mut SqliteConnectOptions
[src]
&mut self,
level: LevelFilter
) -> &mut SqliteConnectOptions
pub fn log_slow_statements(
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut SqliteConnectOptions
[src]
&mut self,
level: LevelFilter,
duration: Duration
) -> &mut SqliteConnectOptions