@Namespace(ChronoSphereConfiguration.NAMESPACE) public class ChronoSphereConfigurationImpl extends AbstractConfiguration implements ChronoSphereConfiguration { // ===================================================================================================================== // FIELDS // ===================================================================================================================== @Parameter(key = BATCH_INSERT__BATCH_SIZE, optional = true) private int batchInsertBatchSize = 10_000; // ===================================================================================================================== // GETTERS & SETTERS // ===================================================================================================================== @Override public int getBatchInsertBatchSize() { return this.batchInsertBatchSize; } }
@Namespace(ChronosBuildConfiguration.NAMESPACE) public class ChronosBuildConfigurationImpl extends AbstractConfiguration implements ChronosBuildConfiguration { // ===================================================================================================================== // PROPERTIES // ===================================================================================================================== @Parameter(key = ChronosBuildConfiguration.BUILD_VERSION, optional = false) private String chronosVersion; // ===================================================================================================================== // GETTERS // ===================================================================================================================== @Override public String getBuildVersion() { return this.chronosVersion; } }
@Namespace(ChronoGraphConfiguration.NAMESPACE) public class ChronoGraphConfigurationImpl extends AbstractConfiguration implements ChronoGraphConfiguration { // ================================================================================================================= // FIELDS // ================================================================================================================= @Parameter(key = ChronoGraphConfiguration.TRANSACTION_CHECK_ID_EXISTENCE_ON_ADD) private boolean checkIdExistenceOnAdd = true; @Parameter(key = ChronoGraphConfiguration.TRANSACTION_AUTO_OPEN) private boolean txAutoOpenEnabled = true; // ================================================================================================================= // GETTERS // ================================================================================================================= @Override public boolean isCheckIdExistenceOnAddEnabled() { return this.checkIdExistenceOnAdd; } @Override public boolean isTransactionAutoOpenEnabled() { return this.txAutoOpenEnabled; } }
@Namespace("org.chronos.common.test") public class BooleanDependentConfiguration extends AbstractConfiguration { @Parameter private Boolean bool; @Parameter @RequiredIf(field = "bool", comparison = Comparison.IS_SET_TO, compareValue = "true") private String string; public Boolean getBool() { return this.bool; } public String getString() { return this.string; } }
@Namespace(ChronoDBConfiguration.NAMESPACE) public class ChronoDBConfigurationImpl extends AbstractConfiguration implements ChronoDBConfiguration {
@Namespace("org.chronos.common.test") public class MyConfiguration extends AbstractConfiguration {