Package de.xima.fc.persistence
Class ConnectionProperties
- java.lang.Object
-
- de.xima.fc.persistence.ConnectionProperties
-
- All Implemented Interfaces:
Serializable
public final class ConnectionProperties extends Object implements Serializable
- Since:
- 8.5.0
- Author:
- Norman Lorenz
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classConnectionProperties.Builderstatic classConnectionProperties.TlsScope
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ConnectionProperties.Builderbuilder()booleanequals(Object o)ConnectionIdentifiergetConnectionIdentifier()The connection identifier which uniquely identifies the database connection.DbmsgetDbms()Determines the DBMS type based on the JDBC URL.StringgetJdbcUrl()The JDBC URL for database connection.char[]getPassword()The password for database authentication.ConnectionPoolPropertiesgetPoolProperties()The connection pool properties for this connection.ConnectionProperties.TlsScopegetTlsScope()Optional.StringgetUsername()The username for database authentication.inthashCode()static ConnectionPropertiessystem()Retrieves the connection properties for the system database using CDI.ConnectionProperties.BuildertoBuilder()StringtoString()
-
-
-
Method Detail
-
getDbms
public Dbms getDbms()
Determines the DBMS type based on the JDBC URL.- Returns:
- the DBMS type corresponding to the JDBC URL
-
system
public static ConnectionProperties system()
Retrieves the connection properties for the system database using CDI.- Returns:
- the connection properties for the system database
- Throws:
IllegalStateException- if the CDI container is not available or the bean cannot be found
-
builder
public static ConnectionProperties.Builder builder()
-
toBuilder
public ConnectionProperties.Builder toBuilder()
-
getConnectionIdentifier
public ConnectionIdentifier getConnectionIdentifier()
The connection identifier which uniquely identifies the database connection. Required for managed connections.
-
getJdbcUrl
public String getJdbcUrl()
The JDBC URL for database connection.
-
getUsername
public String getUsername()
The username for database authentication.
-
getPassword
public char[] getPassword()
The password for database authentication.
-
getPoolProperties
public ConnectionPoolProperties getPoolProperties()
The connection pool properties for this connection. If not provided, default properties will be used.
-
getTlsScope
public ConnectionProperties.TlsScope getTlsScope()
Optional. The TLS scope for secure connections. For identified connections, this scope is ignored and the TLS scope is determined by the connection identifier. For unmanaged connections, this scope is used if provided.
-
-