pub trait SqlBrowser {
// Required method
fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
where Self: Sized + Send + Sync + 'async_trait,
'life0: 'async_trait;
}Expand description
An extension trait to a TcpStream to find a port and connecting to a
named database instance.
Only needed on Windows platforms, where the server port is not known and the
address is in the form of hostname\\INSTANCE.
Required Methods§
Sourcefn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
fn connect_named<'life0, 'async_trait>( builder: &'life0 Config, ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
If the given builder defines a named instance, finds the correct port
and returns a TcpStream to be used in the Client. If instance name
is not defined, connects directly to the given host and port.
Implementations on Foreign Types§
Source§impl SqlBrowser for TcpStream
Available on crate feature sql-browser-smol only.
impl SqlBrowser for TcpStream
sql-browser-smol only.Source§fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
This method can be used to connect to SQL Server named instances
when on a Windows paltform with the sql-browser-tokio feature
enabled. Please see the crate examples for more detailed examples.
Source§impl SqlBrowser for TcpStream
Available on crate feature sql-browser-async-std only.
impl SqlBrowser for TcpStream
sql-browser-async-std only.Source§fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
This method can be used to connect to SQL Server named instances
when on a Windows platform with the sql-browser-async-std feature
enabled. Please see the crate examples for more detailed examples.
Source§impl SqlBrowser for TcpStream
Available on crate feature sql-browser-tokio only.
impl SqlBrowser for TcpStream
sql-browser-tokio only.Source§fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn connect_named<'life0, 'async_trait>(
builder: &'life0 Config,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
This method can be used to connect to SQL Server named instances
when on a Windows paltform with the sql-browser-tokio feature
enabled. Please see the crate examples for more detailed examples.