java.lang.Object
is.codion.tools.generator.domain.DomainSource
For instances use the builder provided by
builder().-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionapi()static StringapiSearchString(EntityDefinition definition) builder()combined()i18n()static Stringi18nSearchString(EntityDefinition definition) static StringimplSearchString(EntityDefinition definition) booleanwriteApiImpl(Path apiSourcePath, Path implSourcePath, Path apiResourcePath, Path testPath, BooleanSupplier overwrite) Writes the api and implementation source code to the given path.booleanwriteCombined(Path sourcePath, Path resourcePath, Path testPath, BooleanSupplier overwrite) Writes the combined source code to the given path.
-
Method Details
-
builder
- Returns:
- a new
DomainSource.Builder.DomainStepinstance.
-
api
- Returns:
- the api source code.
-
implementation
- Returns:
- the implementation source code.
-
combined
- Returns:
- the combined source code of the api and implementation.
-
i18n
- Returns:
- the i18n properties for all entities
-
testApiImpl
- Returns:
- the domain model test implementation for api/impl
-
testCombined
- Returns:
- the domain model test implementation for combined
-
writeApiImpl
public boolean writeApiImpl(Path apiSourcePath, Path implSourcePath, Path apiResourcePath, Path testPath, BooleanSupplier overwrite) throws IOException Writes the api and implementation source code to the given path.- Parameters:
apiSourcePath- the path to write the api source files toimplSourcePath- the path to write the implementation source files toapiResourcePath- the path to write the api resources totestPath- the path to write the unit test tooverwrite- used to confirm overwrite if either of the api or impl files exist- Returns:
- true if the files were written, false if overwriting was not confirmed
- Throws:
IOException- in case of an I/O error.
-
writeCombined
public boolean writeCombined(Path sourcePath, Path resourcePath, Path testPath, BooleanSupplier overwrite) throws IOException Writes the combined source code to the given path.- Parameters:
sourcePath- the path to write the source files toresourcePath- the path to write the resources totestPath- the path to write the unit test tooverwrite- used to confirm overwrite if either of the api or impl files exist- Returns:
- true if the files were written, false if overwriting was not confirmed
- Throws:
IOException- in case of an I/O error.
-
apiSearchString
-
implSearchString
-
i18nSearchString
-