Copyright© 2008-2022 Sitevision AB, all rights reserved.
@Requireable(value="SiteCookieUtil") public interface SiteCookieUtil
Contains methods for retrieving sv:siteCookie Nodes of current site and current user's consent status of them.
An instance of the Sitevision class implementing this interface can be obtained via
Utils.getSiteCookieUtil()
.
See Utils
for how to obtain an instance of the Utils
interface.
ResourceLocatorUtil.getSiteCookieRepository()
Modifier and Type | Method and Description |
---|---|
boolean |
checkUserConsent(Node aSiteCookie)
Checks whether or not current user explicitly has accepted a specific site cookie.
|
String |
createUserConsentCookieValue(List<Node> aAllowCookieIdList)
Generates a consent string that can be saved as cookie value for the cookie named
getUserConsentCookieName() . |
List<Node> |
getAnalyticsSiteCookies()
Analytics Site cookies (sv:siteCookie) of current site.
|
String |
getAnalyticsSiteCookiesDescription()
Gets the analytics site cookies category description.
|
String |
getAnalyticsSiteCookiesTitle()
Gets the analytics site cookies category title.
|
List<Node> |
getCustomSiteCookies()
Custom Site cookies (sv:siteCookie) of current site.
|
String |
getCustomSiteCookiesDescription()
Gets the custom site cookies category description.
|
String |
getCustomSiteCookiesTitle()
Gets the custom site cookies category title.
|
List<Node> |
getFunctionalSiteCookies()
Functional Site cookies (sv:siteCookie) of current site.
|
String |
getFunctionalSiteCookiesDescription()
Gets the functional site cookies category description.
|
String |
getFunctionalSiteCookiesTitle()
Gets the functional site cookies category title.
|
List<Node> |
getMarketingSiteCookies()
Marketing Site cookies (sv:siteCookie) of current site.
|
String |
getMarketingSiteCookiesDescription()
Gets the marketing site cookies category description.
|
String |
getMarketingSiteCookiesTitle()
Gets the marketing site cookies category title.
|
List<Node> |
getNecessarySiteCookies()
Necessary Site cookies (sv:siteCookie) of current site.
|
String |
getNecessarySiteCookiesDescription()
Gets the necessary site cookies category description.
|
String |
getNecessarySiteCookiesTitle()
Gets the necessary site cookies category title.
|
String |
getUserConsentCookieName()
The name of the cookie that contains data about site cookie consents.
|
List<Node> |
getUserConsents()
Gets all sv:siteCookie nodes that current user has accepted.
|
boolean |
hasPendingUserConsents()
Whether or not current user has explicitly accepted/rejected all "user selectable" site cookies.
|
boolean |
hasUserConsentCookie()
Whether or not current user has a consent cookie.
|
Node |
resolveSiteCookieByIdentifier(String aCookieIdentifier)
Convenience method that resolves a sv:siteCookie Node from a given cookie identifier.
|
List<Node> getNecessarySiteCookies()
String getNecessarySiteCookiesTitle()
String getNecessarySiteCookiesDescription()
List<Node> getAnalyticsSiteCookies()
String getAnalyticsSiteCookiesTitle()
String getAnalyticsSiteCookiesDescription()
List<Node> getMarketingSiteCookies()
String getMarketingSiteCookiesTitle()
String getMarketingSiteCookiesDescription()
List<Node> getFunctionalSiteCookies()
String getFunctionalSiteCookiesTitle()
String getFunctionalSiteCookiesDescription()
List<Node> getCustomSiteCookies()
String getCustomSiteCookiesTitle()
String getCustomSiteCookiesDescription()
Node resolveSiteCookieByIdentifier(String aCookieIdentifier)
aCookieIdentifier
- the site cookie identifierboolean checkUserConsent(Node aSiteCookie)
aSiteCookie
- the sv:siteCookieboolean hasPendingUserConsents()
hasUserConsentCookie()
boolean hasUserConsentCookie()
hasPendingUserConsents()
String getUserConsentCookieName()
String createUserConsentCookieValue(List<Node> aAllowCookieIdList) throws IllegalArgumentException
getUserConsentCookieName()
.
Note! All "user selectable" sv:siteCookie Nodes that are not present in aAllowCookieIdList
will be treated as rejected.
aAllowCookieIdList
- the list of sv:siteCookie accepted by current userIllegalArgumentException
- if aAllowCookieIdList is null or contains other than sv:siteCookie NodesSitevision - Portal and Content Management Made Easy
Sitevision is an advanced Java enterprise portal product and a portlet container (JSR 286) that implements Java Content Repository (JSR 283).
Copyright© 2008-2022 Sitevision AB, all rights reserved.