Struct postgres::ConnectParams [] [src]

pub struct ConnectParams {
    pub target: ConnectTarget,
    pub port: Option<u16>,
    pub user: Option<UserInfo>,
    pub database: Option<String>,
    pub options: Vec<(String, String)>,
}

Information necessary to open a new connection to a Postgres server.

Fields

target

The target server

port

The target port.

Defaults to 5432 if not specified.

user

The user to login as.

Connection::connect requires a user but cancel_query does not.

database

The database to connect to. Defaults the value of user.

options

Runtime parameters to be passed to the Postgres backend.

Trait Implementations

impl IntoConnectParams for ConnectParams

fn into_connect_params(self) -> Result<ConnectParams, Box<StdError + StdSync + Send>>

Derived Implementations

impl Debug for ConnectParams

fn fmt(&self, __arg_0: &mut Formatter) -> Result

impl Clone for ConnectParams

fn clone(&self) -> ConnectParams

fn clone_from(&mut self, source: &Self)