Class GroupParentProviderImpl
java.lang.Object
de.murmelmeister.murmelapi.group.parent.GroupParentProviderImpl
- All Implemented Interfaces:
GroupParentProvider
GroupParentProvider is a class that provides methods to manage group parents in the database.
It implements the GroupParent interface and uses the Database class to interact with the database.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final RefreshTypeprivate final GroupParentCacheprivate final de.murmelmeister.library.database.Databaseprivate final RefreshTypeprivate static final String -
Constructor Summary
ConstructorsConstructorDescriptionGroupParentProviderImpl(de.murmelmeister.library.database.Database database, Long fetchLimit, long cacheCapcity, Duration refreshInterval) -
Method Summary
Modifier and TypeMethodDescriptionadd(int groupId, int parentId, long duration, int createdBy) intclear(int groupId) voidgetParent(int groupId, int parentId) getParents(int groupId) intvoidintremove(int groupId, int parentId) static voidsetup(de.murmelmeister.library.database.Database database) update(int groupId, int parentId, long duration, int changedBy)
-
Field Details
-
TABLE_NAME
- See Also:
-
database
private final de.murmelmeister.library.database.Database database -
cache
-
all
-
single
-
-
Constructor Details
-
GroupParentProviderImpl
-
-
Method Details
-
setup
public static void setup(de.murmelmeister.library.database.Database database) -
closeCache
public void closeCache()- Specified by:
closeCachein interfaceGroupParentProvider
-
refreshCache
public void refreshCache()- Specified by:
refreshCachein interfaceGroupParentProvider
-
getParent
- Specified by:
getParentin interfaceGroupParentProvider
-
getParents
- Specified by:
getParentsin interfaceGroupParentProvider
-
add
- Specified by:
addin interfaceGroupParentProvider
-
remove
public int remove(int groupId, int parentId) - Specified by:
removein interfaceGroupParentProvider
-
clear
public int clear(int groupId) - Specified by:
clearin interfaceGroupParentProvider
-
update
- Specified by:
updatein interfaceGroupParentProvider
-
loadExpired
public int loadExpired()- Specified by:
loadExpiredin interfaceGroupParentProvider
-