Module is.codion.framework.db.core
Package is.codion.framework.db
Interface EntityConnectionProvider.Builder<T extends EntityConnectionProvider,B extends EntityConnectionProvider.Builder<T,B>>
- Type Parameters:
T- the connection provider typeB- the builder type
- All Known Implementing Classes:
AbstractEntityConnectionProvider.AbstractBuilder
- Enclosing interface:
- EntityConnectionProvider
public static interface EntityConnectionProvider.Builder<T extends EntityConnectionProvider,B extends EntityConnectionProvider.Builder<T,B>>
Builds a
EntityConnectionProvider instances-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aEntityConnectionProviderinstance based on this builderclientTypeId(String clientTypeId) clientVersion(is.codion.common.version.Version clientVersion) Returns a String specifying the type of connection provided by this connection provider builderdomainType(is.codion.framework.domain.DomainType domainType) onClose(Consumer<EntityConnectionProvider> onClose) user(is.codion.common.user.User user)
-
Method Details
-
connectionType
String connectionType()Returns a String specifying the type of connection provided by this connection provider builder- Returns:
- a String specifying the type of connection, e.g. "local" or "remote"
-
user
- Parameters:
user- the user- Returns:
- this builder instance
-
domainType
- Parameters:
domainType- the domain type to base this connection on- Returns:
- this builder instance
-
clientId
- Parameters:
clientId- the UUID identifying this client connection- Returns:
- this builder instance
-
clientTypeId
- Parameters:
clientTypeId- a String identifying the client type for this connection provider- Returns:
- this builder instance
-
clientVersion
- Parameters:
clientVersion- the client version- Returns:
- this builder instance
-
onClose
- Parameters:
onClose- called when this connection provider has been closed- Returns:
- this builder instance
- See Also:
-
build
T build()Builds aEntityConnectionProviderinstance based on this builder- Returns:
- a new
EntityConnectionProviderinstance
-