@Override public Builder<T> aggregateModel(AggregateModel<T> aggregateModel) { super.aggregateModel(aggregateModel); return this; }
@Override public Builder<T> handlerDefinition(HandlerDefinition handlerDefinition) { super.handlerDefinition(handlerDefinition); return this; }
@Override public Builder<T> lockFactory(LockFactory lockFactory) { super.lockFactory(lockFactory); return this; }
@Override protected void validate() { super.validate(); assertNonNull(eventStore, "The EventStore is a hard requirement and should be provided"); if (aggregateFactory == null) { assertNonNull( aggregateType, "No AggregateFactory is set, whilst either it or the aggregateType is a hard requirement" ); return; } assertNonNull( aggregateFactory, "No aggregateType is set, whilst either it or the AggregateFactory is a hard requirement" ); } }
@Override public Builder<T> aggregateModel(AggregateModel<T> aggregateModel) { super.aggregateModel(aggregateModel); return this; }
@Override protected void validate() { super.validate(); assertNonNull(entityManagerProvider, "The EntityManagerProvider is a hard requirement and should be provided"); assertNonNull(eventBus, "The EventBus is a hard requirement and should be provided"); } }
@Override public Builder<T> parameterResolverFactory(ParameterResolverFactory parameterResolverFactory) { super.parameterResolverFactory(parameterResolverFactory); return this; }
/** * Creates a builder for a Repository for given {@code aggregateType}. * * @param aggregateType the {@code aggregateType} specifying the type of aggregate this {@link Repository} will * store */ protected Builder(Class<T> aggregateType) { super(aggregateType); super.lockFactory(NullLockFactory.INSTANCE); }
@Override public Builder<T> handlerDefinition(HandlerDefinition handlerDefinition) { super.handlerDefinition(handlerDefinition); return this; }
@Override public Builder<T> parameterResolverFactory(ParameterResolverFactory parameterResolverFactory) { super.parameterResolverFactory(parameterResolverFactory); return this; }
/** * {@inheritDoc} * If this Builder is used to instantiate a {@link CachingEventSourcingRepository}, do note that an optimistic * locking strategy is not compatible with a caching approach. */ @Override public Builder<T> lockFactory(LockFactory lockFactory) { super.lockFactory(lockFactory); return this; }
@Override protected void validate() { super.validate(); assertNonNull(eventStore, "The EventStore is a hard requirement and should be provided"); if (aggregateFactory == null) { assertNonNull( aggregateType, "No AggregateFactory is set, whilst either it or the aggregateType is a hard requirement" ); return; } assertNonNull( aggregateFactory, "No aggregateType is set, whilst either it or the AggregateFactory is a hard requirement" ); } }
@Override public Builder<T> aggregateModel(AggregateModel<T> aggregateModel) { super.aggregateModel(aggregateModel); return this; }
@Override public Builder<T> handlerDefinition(HandlerDefinition handlerDefinition) { super.handlerDefinition(handlerDefinition); return this; }
@Override protected void validate() { super.validate(); assertNonNull(entityManagerProvider, "The EntityManagerProvider is a hard requirement and should be provided"); assertNonNull(eventBus, "The EventBus is a hard requirement and should be provided"); } }
@Override public Builder<T> parameterResolverFactory(ParameterResolverFactory parameterResolverFactory) { super.parameterResolverFactory(parameterResolverFactory); return this; }
@Override public Builder<T> lockFactory(LockFactory lockFactory) { super.lockFactory(lockFactory); return this; }
/** * Creates a builder for a Repository for given {@code aggregateType}. * * @param aggregateType the {@code aggregateType} specifying the type of aggregate this {@link Repository} will * store */ protected Builder(Class<T> aggregateType) { super(aggregateType); super.lockFactory(NullLockFactory.INSTANCE); }
@Override public Builder<T> handlerDefinition(HandlerDefinition handlerDefinition) { super.handlerDefinition(handlerDefinition); return this; }
@Override public Builder<T> parameterResolverFactory(ParameterResolverFactory parameterResolverFactory) { super.parameterResolverFactory(parameterResolverFactory); return this; }