public interface NavigationItemManagement
| Modifier and Type | Method and Description |
|---|---|
boolean |
createBuiltInNavigationItems(Long userId)
Create the built-in immutable navigation items for the current user if they do not yet exist.
|
boolean |
delete(Long navigationItemId)
Delete a given item.
|
<DATA_TYPE extends NavigationItemDataTO> |
find(Class<DATA_TYPE> type,
Long... navigationItemIds)
Method to find all items for the current user.
|
<T> Collection<T> |
get(CollectionConverter<NavigationItem,T> converter,
Long... ids)
Method to find all navigation items for the current user.
|
<DATA_TYPE extends NavigationItemDataTO> |
get(Long notificationItemId,
Class<DATA_TYPE> type)
Method to get an item for the given user.
|
<T extends NavigationItemDataTO> |
store(NavigationItemTO<T> navigationItem)
Updates the given item or creates a new one.
|
boolean createBuiltInNavigationItems(Long userId) throws AuthorizationException
userId - The ID of the user to updateAuthorizationException - If the current user is not the provided user or the internal system userboolean delete(Long navigationItemId) throws AuthorizationException
navigationItemId - ID of the item to delete.AuthorizationException - in case the current user is not the owner of the item<DATA_TYPE extends NavigationItemDataTO> List<NavigationItemTO<DATA_TYPE>> find(Class<DATA_TYPE> type, Long... navigationItemIds) throws NavigationItemDataSerializationException
DATA_TYPE - the type of the data of the itemtype - the type of the data of the itemnavigationItemIds - Id's of items to load or null, if all.NavigationItemDataSerializationException - Thrown, when the given data can't be converted into the given type.<T> Collection<T> get(CollectionConverter<NavigationItem,T> converter, Long... ids)
T - Type of the result.converter - The converter to use for result converting.ids - Ids of items to get or null to get all items.<DATA_TYPE extends NavigationItemDataTO> NavigationItemTO<DATA_TYPE> get(Long notificationItemId, Class<DATA_TYPE> type) throws NavigationItemDataSerializationException
DATA_TYPE - the type of the data of the itemnotificationItemId - Id of the item to get.type - Type of the data, if null, the data won't be deserialized.NavigationItemDataSerializationException - Thrown, when the given data can't be converted into the given type.<T extends NavigationItemDataTO> Long store(NavigationItemTO<T> navigationItem) throws AuthorizationException, NavigationItemDataSerializationException
T - the type of the data of the itemnavigationItem - Item to update.AuthorizationException - in case the item to update exists but the current user is not the owner of itNavigationItemDataSerializationException - Thrown, when the given data can't be converted into JSONCopyright © 2019 Communote team. All rights reserved.