public class CQPreferences extends Object
Modifier and Type | Field and Description |
---|---|
protected Authorizable |
authorizable
Group / User
|
protected SecurityClient |
client |
static String |
LANGUAGE_DE |
static String |
LANGUAGE_EN |
static String |
LANGUAGE_FR |
static String |
LANGUAGE_PROPERTY |
protected String |
path
path to
Authorizable s' references |
static String |
PREFERENCES_NODE |
static String |
SELECTOR |
Constructor and Description |
---|
CQPreferences(Authorizable authorizable) |
Modifier and Type | Method and Description |
---|---|
Authorizable |
getAuthorizable() |
SecurityClient |
getClient() |
org.codehaus.jackson.JsonNode |
getJson(int... expectedStatus)
Get json representation of the preferences
|
String |
getLanguage()
Get language settings of
Authorizable |
String |
getPath()
Get path to
Authorizable s' references |
org.apache.sling.testing.clients.SlingHttpResponse |
setLanguage(String language)
Set language - if language is not given, default is set to "en"
|
public static final String PREFERENCES_NODE
public static final String SELECTOR
public static final String LANGUAGE_PROPERTY
public static final String LANGUAGE_EN
public static final String LANGUAGE_DE
public static final String LANGUAGE_FR
protected SecurityClient client
protected Authorizable authorizable
protected String path
Authorizable
s' referencespublic CQPreferences(Authorizable authorizable) throws org.apache.sling.testing.clients.ClientException
org.apache.sling.testing.clients.ClientException
public SecurityClient getClient()
public Authorizable getAuthorizable()
public String getPath() throws org.apache.sling.testing.clients.ClientException
Authorizable
s' referencesorg.apache.sling.testing.clients.ClientException
- if the request failspublic org.codehaus.jackson.JsonNode getJson(int... expectedStatus) throws org.apache.sling.testing.clients.ClientException
expectedStatus
- list of expected http status codesJsonNode
org.apache.sling.testing.clients.ClientException
- if the request failspublic String getLanguage() throws org.apache.sling.testing.clients.ClientException
Authorizable
org.apache.sling.testing.clients.ClientException
- if the request failspublic org.apache.sling.testing.clients.SlingHttpResponse setLanguage(String language) throws org.apache.sling.testing.clients.ClientException
language
- language to setorg.apache.sling.testing.clients.ClientException
- if the request failsCopyright © 2018. All rights reserved.