Package com.composum.sling.nodes.browser
Class GenericView
- java.lang.Object
-
- com.composum.sling.core.AbstractSlingBean
-
- com.composum.sling.core.AbstractServletBean
-
- com.composum.sling.nodes.console.ConsoleServletBean
-
- com.composum.sling.nodes.browser.GenericView
-
- All Implemented Interfaces:
com.composum.sling.core.bean.RestrictedBean,com.composum.sling.core.SlingBean
public class GenericView extends ConsoleServletBean
-
-
Field Summary
Fields Modifier and Type Field Description protected BrowserViews.ViewbrowserView
-
Constructor Summary
Constructors Constructor Description GenericView()GenericView(com.composum.sling.core.BeanContext context)GenericView(com.composum.sling.core.BeanContext context, org.apache.sling.api.resource.Resource resource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BrowserViews.View.ContentgetContent()@NotNull StringgetFileIcon()@NotNull StringgetFilePath()@NotNull com.composum.sling.core.ResourceHandlegetFileResource()@NotNull StringgetFileType()@NotNull StringgetId()@NotNull StringgetMappedUrl()@NotNull StringgetMimeType()the content mime type declared for the current resource@NotNull StringgetMimeTypeCss()@NotNull StringgetTabResourceType()BrowserViews.View.ToolbargetToolbar()@NotNull StringgetUnmappedUrl()@NotNull StringgetViewResourceType()@NotNull List<BrowserViews.View.Tab>getViewTabs()@NotNull StringgetViewType()voidinitialize(com.composum.sling.core.BeanContext context, org.apache.sling.api.resource.Resource resource)booleanisImage()'true' if the mimetype is of type imagebooleanisRenderable()booleanisVideo()'true' if the mimetype is of type video-
Methods inherited from class com.composum.sling.core.AbstractSlingBean
executeQuery, findBeans, findNodes, findNodes, findPathList, getContentResource, getDomId, getHasTitle, getInherited, getInherited, getName, getNode, getParent, getParent, getPath, getPermissible, getProperty, getProperty, getQueryManager, getRequest, getResolver, getResource, getResponse, getServiceKey, getSession, getSling, getStringId, getTitle, getType, getUrl, getUsername, isPermissible, isReadAllowed, isWriteAllowed, toString, toString
-
-
-
-
Field Detail
-
browserView
protected BrowserViews.View browserView
-
-
Method Detail
-
initialize
public void initialize(com.composum.sling.core.BeanContext context, org.apache.sling.api.resource.Resource resource)- Specified by:
initializein interfacecom.composum.sling.core.SlingBean- Overrides:
initializein classConsoleServletBean
-
getId
@NotNull public @NotNull String getId()
- Overrides:
getIdin classcom.composum.sling.core.AbstractSlingBean
-
getMappedUrl
@NotNull public @NotNull String getMappedUrl()
-
getUnmappedUrl
@NotNull public @NotNull String getUnmappedUrl()
-
getViewResourceType
@NotNull public @NotNull String getViewResourceType()
-
getTabResourceType
@NotNull public @NotNull String getTabResourceType()
-
getViewTabs
@NotNull public @NotNull List<BrowserViews.View.Tab> getViewTabs()
-
getToolbar
@NotNull public BrowserViews.View.Toolbar getToolbar()
-
getContent
@NotNull public BrowserViews.View.Content getContent()
-
getViewType
@NotNull public @NotNull String getViewType()
-
getFileType
@NotNull public @NotNull String getFileType()
-
getFilePath
@NotNull public @NotNull String getFilePath()
-
getFileResource
@NotNull public @NotNull com.composum.sling.core.ResourceHandle getFileResource()
-
isRenderable
public boolean isRenderable()
-
getFileIcon
@NotNull public @NotNull String getFileIcon()
-
getMimeTypeCss
@NotNull public @NotNull String getMimeTypeCss()
-
getMimeType
@NotNull public @NotNull String getMimeType()
the content mime type declared for the current resource
-
isImage
public boolean isImage()
'true' if the mimetype is of type image
-
isVideo
public boolean isVideo()
'true' if the mimetype is of type video
-
-