replace method
Creates a new PgEndpoint by replacing the current values with non-null parameters.
Parameters with null
values are ignored (keeping current value).
Implementation
PgEndpoint replace({
String? host,
int? port,
String? database,
String? username,
String? password,
bool? requireSsl,
}) {
return PgEndpoint(
host: host ?? this.host,
port: port ?? this.port,
database: database ?? this.database,
username: username ?? this.username,
password: password ?? this.password,
requireSsl: requireSsl ?? this.requireSsl,
);
}