Package com.composum.sling.nodes.console
Class ConsoleModel
- java.lang.Object
-
- com.composum.sling.core.AbstractSlingBean
-
- com.composum.sling.nodes.console.ConsoleSlingBean
-
- com.composum.sling.nodes.console.ConsolePage
-
- com.composum.sling.nodes.console.ConsoleModel
-
- All Implemented Interfaces:
RestrictedBean,SlingBean
public class ConsoleModel extends ConsolePage
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classConsoleModel.LinkModel-
Nested classes/interfaces inherited from class com.composum.sling.core.AbstractSlingBean
AbstractSlingBean.NodeClosure
-
-
Field Summary
Fields Modifier and Type Field Description protected Consoles.Consoleconsole-
Fields inherited from class com.composum.sling.nodes.console.ConsolePage
SERVICE_KEY
-
Fields inherited from class com.composum.sling.core.AbstractSlingBean
context, queryManager, request, resolver, resource, response, session, sling
-
-
Constructor Summary
Constructors Constructor Description ConsoleModel()ConsoleModel(BeanContext context)ConsoleModel(BeanContext context, Consoles.Console console)ConsoleModel(BeanContext context, org.apache.sling.api.resource.Resource resource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull StringgetContentSrc()@NotNull StringgetDataSet()@NotNull StringgetDescription()@NotNull StringgetId()@NotNull StringgetLabel()@NotNull ConsoleModel.LinkModelgetLink()@NotNull StringgetLinkAttributes()@NotNull Collection<ConsoleModel>getMenuItems()@NotNull StringgetName()returns the name of the resource wrapped by this bean@NotNull StringgetPath()returns the path of the resource wrapped by this bean@NotNull StringgetStaticUrl()@NotNull StringgetUrl()Returns the URL to the resource of this bean (mapped and with the appropriate extension).voidinitialize(BeanContext context, org.apache.sling.api.resource.Resource resource)This basic initialization sets up the context and resource attributes only, all the other attributes are set 'lazy' during their getter calls.booleanisMenu()booleanisSupportsPermissions()booleanisValidMenu()@NotNull StringtoString()Default implementation: usesAbstractSlingBean.toString(StringBuilder).-
Methods inherited from class com.composum.sling.nodes.console.ConsolePage
getCurrentUser, getLogoutUrl, getSystemPermission, getURL, getUserPermission, getWorkspaceName
-
Methods inherited from class com.composum.sling.core.AbstractSlingBean
executeQuery, findBeans, findNodes, findNodes, findPathList, getContentResource, getDomId, getHasTitle, getInherited, getInherited, getNode, getParent, getParent, getPermissible, getProperty, getProperty, getQueryManager, getRequest, getResolver, getResource, getResponse, getServiceKey, getSession, getSling, getStringId, getTitle, getType, getUsername, initialize, isPermissible, isReadAllowed, isWriteAllowed, toString
-
-
-
-
Field Detail
-
console
protected Consoles.Console console
-
-
Constructor Detail
-
ConsoleModel
public ConsoleModel(BeanContext context, Consoles.Console console)
-
ConsoleModel
public ConsoleModel(BeanContext context, org.apache.sling.api.resource.Resource resource)
-
ConsoleModel
public ConsoleModel(BeanContext context)
-
ConsoleModel
public ConsoleModel()
-
-
Method Detail
-
initialize
public void initialize(BeanContext context, org.apache.sling.api.resource.Resource resource)
Description copied from class:AbstractSlingBeanThis basic initialization sets up the context and resource attributes only, all the other attributes are set 'lazy' during their getter calls.- Specified by:
initializein interfaceSlingBean- Overrides:
initializein classConsoleSlingBean- Parameters:
context- the scripting context (e.g. a JSP PageContext or a Groovy scripting context)resource- the resource to use (normally the resource addressed by the request)- See Also:
BeanContext.withResource(Resource)
-
getId
@NotNull public @NotNull String getId()
- Overrides:
getIdin classAbstractSlingBean
-
getName
@NotNull public @NotNull String getName()
Description copied from interface:SlingBeanreturns the name of the resource wrapped by this bean- Specified by:
getNamein interfaceSlingBean- Overrides:
getNamein classAbstractSlingBean
-
getPath
@NotNull public @NotNull String getPath()
Description copied from interface:SlingBeanreturns the path of the resource wrapped by this bean- Specified by:
getPathin interfaceSlingBean- Overrides:
getPathin classAbstractSlingBean
-
getLabel
@NotNull public @NotNull String getLabel()
-
isSupportsPermissions
public boolean isSupportsPermissions()
-
getDescription
@NotNull public @NotNull String getDescription()
-
getContentSrc
@NotNull public @NotNull String getContentSrc()
-
getUrl
@NotNull public @NotNull String getUrl()
Description copied from class:AbstractSlingBeanReturns the URL to the resource of this bean (mapped and with the appropriate extension).- Overrides:
getUrlin classAbstractSlingBean- See Also:
LinkUtil.getUrl(SlingHttpServletRequest, String)
-
getStaticUrl
@NotNull public @NotNull String getStaticUrl()
-
getLink
@NotNull public @NotNull ConsoleModel.LinkModel getLink()
-
getLinkAttributes
@NotNull public @NotNull String getLinkAttributes()
-
isMenu
public boolean isMenu()
-
isValidMenu
public boolean isValidMenu()
-
getMenuItems
@NotNull public @NotNull Collection<ConsoleModel> getMenuItems()
-
toString
@NotNull public @NotNull String toString()
Description copied from class:AbstractSlingBeanDefault implementation: usesAbstractSlingBean.toString(StringBuilder).- Overrides:
toStringin classAbstractSlingBean- Returns:
- a string representation for debugging.
-
getDataSet
@NotNull public @NotNull String getDataSet()
-
-