public class L1CacheRepositoryDecorator extends AbstractRepositoryDecorator<Entity>
L1Cache when a Repository is RepositoryCapability.CACHEABLE.
Delegates to the underlying repository when an action is not supported by the cache or when the cache doesn't contain
the needed entity.| Constructor and Description |
|---|
L1CacheRepositoryDecorator(Repository<Entity> decoratedRepository,
L1Cache l1Cache) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(Entity entity) |
Integer |
add(java.util.stream.Stream<Entity> entities) |
Repository<Entity> |
delegate() |
void |
delete(Entity entity) |
void |
delete(java.util.stream.Stream<Entity> entities) |
void |
deleteAll() |
void |
deleteAll(java.util.stream.Stream<Object> ids) |
void |
deleteById(Object id) |
java.util.stream.Stream<Entity> |
findAll(java.util.stream.Stream<Object> ids) |
Entity |
findOneById(Object id) |
void |
update(Entity entity) |
void |
update(java.util.stream.Stream<Entity> entities) |
aggregate, close, count, count, findAll, findAll, findOne, findOneById, forEachBatched, getCapabilities, getEntityType, getName, getQueryOperators, iterator, queryclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEachBatchedforEach, spliteratorpublic L1CacheRepositoryDecorator(Repository<Entity> decoratedRepository, L1Cache l1Cache)
public Repository<Entity> delegate()
delegate in class AbstractRepositoryDecorator<Entity>public Integer add(java.util.stream.Stream<Entity> entities)
add in interface Repository<Entity>add in class AbstractRepositoryDecorator<Entity>public void add(Entity entity)
add in interface Repository<Entity>add in class AbstractRepositoryDecorator<Entity>public Entity findOneById(Object id)
findOneById in interface Repository<Entity>findOneById in class AbstractRepositoryDecorator<Entity>public java.util.stream.Stream<Entity> findAll(java.util.stream.Stream<Object> ids)
findAll in interface Repository<Entity>findAll in class AbstractRepositoryDecorator<Entity>public void update(Entity entity)
update in interface Repository<Entity>update in class AbstractRepositoryDecorator<Entity>public void update(java.util.stream.Stream<Entity> entities)
update in interface Repository<Entity>update in class AbstractRepositoryDecorator<Entity>public void delete(Entity entity)
delete in interface Repository<Entity>delete in class AbstractRepositoryDecorator<Entity>public void delete(java.util.stream.Stream<Entity> entities)
delete in interface Repository<Entity>delete in class AbstractRepositoryDecorator<Entity>public void deleteById(Object id)
deleteById in interface Repository<Entity>deleteById in class AbstractRepositoryDecorator<Entity>public void deleteAll(java.util.stream.Stream<Object> ids)
deleteAll in interface Repository<Entity>deleteAll in class AbstractRepositoryDecorator<Entity>public void deleteAll()
deleteAll in interface Repository<Entity>deleteAll in class AbstractRepositoryDecorator<Entity>Copyright © 2017. All Rights Reserved.