Package com.jalios.jcms.shortcut
Class ShortcutManager
- java.lang.Object
-
- com.jalios.jcms.shortcut.ShortcutManager
-
- All Implemented Interfaces:
JPropertiesListener
public class ShortcutManager extends java.lang.Object implements JPropertiesListener
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
REVISION
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
deleteShortcuts(JProperties props)
Delete all the shortcuts present as virtual ids in the given properties.PortalInterface
findDisplayPortal(java.lang.String url)
Returns the portal to display for the given URL of an application.PortalInterface
findDisplayPortal(javax.servlet.http.HttpServletRequest request)
Returns the portal to display for the given request.AbstractShortcut
generateShortcut(java.lang.String key)
Generate a shortcut for the given prefix key propertyvoid
generateShortcuts()
static ShortcutManager
getInstance()
void
init()
void
propertiesChange(JProperties properties)
Invoked after properties have been modified in JCMS and save on disk.
-
-
-
Field Detail
-
REVISION
public static final java.lang.String REVISION
- See Also:
- Constant Field Values
-
-
Method Detail
-
getInstance
public static ShortcutManager getInstance()
-
init
public void init()
-
generateShortcuts
public void generateShortcuts()
-
generateShortcut
public AbstractShortcut generateShortcut(java.lang.String key)
Generate a shortcut for the given prefix key property- Parameters:
key
- a prefix property (eg. shortcut.jcmsplugin.myplugin)- Returns:
- the Shortcut
- Since:
- jcms-10.0.0
-
deleteShortcuts
public void deleteShortcuts(JProperties props)
Delete all the shortcuts present as virtual ids in the given properties.- Parameters:
props
- a set of properties- Since:
- jcms-10.0.0
-
propertiesChange
public void propertiesChange(JProperties properties)
Description copied from interface:JPropertiesListener
Invoked after properties have been modified in JCMS and save on disk.You cannot alter the value received in parameters.
Note that properties parameter may be null, a limited set of site properties, or all site properties.
To check that a property has been modified, reload the "current" property instead using
channel.getProperties
orchannel.getProperty
.- Specified by:
propertiesChange
in interfaceJPropertiesListener
- Parameters:
properties
- the properties which have been submitted to change
-
findDisplayPortal
public PortalInterface findDisplayPortal(javax.servlet.http.HttpServletRequest request)
Returns the portal to display for the given request. A dedicated portal can be declared for an application with a property shorcut.APPNAME.portal where APPNAME is the same as in the shortcut declaration: shortcut.APPNAME.link: plugins/MyPlugin/jsp/myApp.jsp- Parameters:
request
- the request- Returns:
- the portal to display for the given URL of an application.
- Since:
- jcms-10.0.7
-
findDisplayPortal
public PortalInterface findDisplayPortal(java.lang.String url)
Returns the portal to display for the given URL of an application. A dedicated portal can be declared for an application with a property shorcut.APPNAME.portal where APPNAME is the same as in the shortcut declaration: shortcut.APPNAME.link: plugins/MyPlugin/jsp/myApp.jsp- Parameters:
url
- the relative URL of an application- Returns:
- the portal to display for the given URL of an application.
- Since:
- jcms-10.0.7
-
-