Package pl.edu.icm.unity.engine.api
Interface PreferencesManagement
public interface PreferencesManagement
Preferences management API - allows for storing and retrieving user's preferences,
useful for example for the web endpoints.
- Author:
- K. Benedyczak
-
Method Summary
Modifier and TypeMethodDescriptiongetPreference
(EntityParam entity, String preferenceId) Returns a given preference.void
removePreference
(EntityParam entity, String preferenceId) Removes the given preference.void
setPreference
(EntityParam entity, String preferenceId, String value) Sets or updates a preference for the specified user.
-
Method Details
-
setPreference
Sets or updates a preference for the specified user. The value can be arbitrary, for instance JSON encoded.- Parameters:
entity
-preferenceId
-value
-- Throws:
EngineException
-
getPreference
Returns a given preference. Null is returned if there is no such preference.- Parameters:
entity
-preferenceId
-- Returns:
- Throws:
EngineException
-
removePreference
Removes the given preference.- Parameters:
entity
-preferenceId
-- Throws:
EngineException
-