Class Repositories
java.lang.Object
wtf.metio.yosql.tooling.gradle.Repositories
The `repositories` configuration can be used to control how `YoSQL` outputs repositories.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionwtf.metio.yosql.models.immutables.RepositoriesConfigurationvoidabstract org.gradle.api.provider.ListProperty<String> abstract org.gradle.api.provider.ListProperty<String> abstract org.gradle.api.provider.ListProperty<String> abstract org.gradle.api.provider.Property<String> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean> abstract org.gradle.api.provider.Property<Boolean>
-
Constructor Details
-
Repositories
public Repositories()
-
-
Method Details
-
getAllowedCallPrefixes
- Returns:
- Configures which name prefixes are allowed for statements that are calling stored procedures.
-
getAllowedReadPrefixes
- Returns:
- Configures which name prefixes are allowed for statements that are reading data from your database.
-
getAllowedWritePrefixes
- Returns:
- Configures which name prefixes are allowed for statements that are writing data to your database.
-
getBasePackageName
- Returns:
- The base package name for all repositories
-
getGenerateInterfaces
- Returns:
- Generate interfaces for all repositories
-
getValidateMethodNamePrefixes
- Returns:
- Validate user given names against list of allowed prefixes per type.
-
getInjectConverters
- Returns:
- Toggles whether converters should be injected as constructor parameters.
-
getExecuteOnce
- Returns:
- Generate methods that are executed once with the given parameters
-
getExecuteBatch
- Returns:
- Generate methods that are executed as batch
-
getUsePreparedStatement
- Returns:
- Should `PreparedStatement`s be used instead of `Statement`s
-
getCatchAndRethrow
- Returns:
- Catch exceptions during SQL execution and re-throw them as RuntimeExceptions
-
getWritesReturnUpdateCount
- Returns:
- Writing method which are using `ReturningMode.NONE` return the number of affected rows instead.
-
getThrowOnMultipleResults
- Returns:
- Throw an exception in case a statement using `ReturningMode.SINGLE` produces more than 1 result.
-
getCreateConnection
- Returns:
- Controls whether the generated code should create/open connection itself or use a given connection.
-
getGenerateConnectionOverloads
- Returns:
- Generate both a DataSource-based method and a Connection-taking overload for every statement.
-
asConfiguration
public wtf.metio.yosql.models.immutables.RepositoriesConfiguration asConfiguration() -
configureConventions
public void configureConventions()
-