Class CachingPersistentDecoratorDao
java.lang.Object
com.atlassian.confluence.impl.themes.persistence.CachingPersistentDecoratorDao
- All Implemented Interfaces:
PersistentDecoratorDao
An implementation of
PersistentDecoratorDao
which combines a cache with Hibernate.- Since:
- 5.10
-
Constructor Summary
ConstructorsConstructorDescriptionCachingPersistentDecoratorDao
(org.hibernate.SessionFactory sessionFactory, com.atlassian.cache.CacheFactory cacheFactory) -
Method Summary
Modifier and TypeMethodDescription@Nullable PersistentDecorator
void
remove
(PersistentDecorator decorator) void
saveOrUpdate
(PersistentDecorator decorator) If a decorator already exists with a certain space key and name, we should try to update it (and not try to create a new one just because the body field is different) (a composite key has not been used for space key and name because spacek key can be null)
-
Constructor Details
-
CachingPersistentDecoratorDao
public CachingPersistentDecoratorDao(org.hibernate.SessionFactory sessionFactory, com.atlassian.cache.CacheFactory cacheFactory)
-
-
Method Details
-
saveOrUpdate
If a decorator already exists with a certain space key and name, we should try to update it (and not try to create a new one just because the body field is different) (a composite key has not been used for space key and name because spacek key can be null)- Specified by:
saveOrUpdate
in interfacePersistentDecoratorDao
-
get
- Specified by:
get
in interfacePersistentDecoratorDao
-
remove
- Specified by:
remove
in interfacePersistentDecoratorDao
-