|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.opencms.workplace.tools.A_CmsToolHandler
Helper class to build easily other admin tool handlers.
| Field Summary | |
static String |
ARG_PARAM_NAME
Property for the params arg. |
static String |
ARG_PATH_NAME
Property for the path arg. |
static String |
ARGS_PROPERTY_DEFINITION
Property for the args. |
static String |
ARGUMENT_SEPARATOR
Argument separator. |
static String |
DEFAULT_DISABLED_HELPTEXT
Default disabled help text constant. |
static String |
VALUE_SEPARATOR
Argument name and value separator. |
| Constructor Summary | |
A_CmsToolHandler()
|
|
| Method Summary | |
String |
getDisabledHelpText()
Returns the help text if disabled. |
String |
getGroup()
Returns the group. |
String |
getHelpText()
Returns the help text. |
String |
getIconPath()
Returns the path to the icon. |
String |
getLink()
Returns the link to the tool. |
String |
getName()
Returns the displayed name. |
String |
getParameters()
Returns the needed parameters. |
String |
getPath()
Returns the tool path to install the tool in. |
float |
getPosition()
Returns the relative position in the group. |
String |
getShortName()
Returns the name for the menu or navbar. |
String |
getSmallIconPath()
Returns the path to an optional small(16x16) icon. |
void |
setDisabledHelpText(String disabledHelpText)
Sets the help text if disabled. |
void |
setGroup(String group)
Sets the group. |
void |
setHelpText(String helpText)
Sets the help text. |
void |
setIconPath(String iconPath)
Sets the icon path. |
void |
setLink(String link)
Sets the link. |
void |
setName(String name)
Sets the name. |
void |
setParameters(String parameters)
Sets the parameters. |
void |
setPath(String path)
Sets the path. |
void |
setPosition(float position)
Sets the position. |
void |
setShortName(String shortName)
Sets the short name. |
void |
setSmallIconPath(String smallIconPath)
Sets the small icon path. |
boolean |
setup(CmsObject cms,
String resourcePath)
Default implementation. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.opencms.workplace.tools.I_CmsToolHandler |
isEnabled, isVisible |
| Field Detail |
public static final String ARG_PARAM_NAME
public static final String ARG_PATH_NAME
public static final String ARGS_PROPERTY_DEFINITION
public static final String ARGUMENT_SEPARATOR
public static final String DEFAULT_DISABLED_HELPTEXT
public static final String VALUE_SEPARATOR
| Constructor Detail |
public A_CmsToolHandler()
| Method Detail |
public String getDisabledHelpText()
I_CmsToolHandler
getDisabledHelpText in interface I_CmsToolHandlerI_CmsToolHandler.getDisabledHelpText()public String getGroup()
I_CmsToolHandler
getGroup in interface I_CmsToolHandlerI_CmsToolHandler.getGroup()public String getHelpText()
I_CmsToolHandler
getHelpText in interface I_CmsToolHandlerI_CmsToolHandler.getHelpText()public String getIconPath()
I_CmsToolHandler
getIconPath in interface I_CmsToolHandlerI_CmsToolHandler.getIconPath()public String getLink()
I_CmsToolHandler
getLink in interface I_CmsToolHandlerI_CmsToolHandler.getLink()public String getName()
I_CmsToolHandler
getName in interface I_CmsToolHandlerI_CmsToolHandler.getName()public String getParameters()
getParameters in interface I_CmsToolHandlerpublic String getPath()
I_CmsToolHandler
getPath in interface I_CmsToolHandlerI_CmsToolHandler.getPath()public float getPosition()
I_CmsToolHandler
getPosition in interface I_CmsToolHandlerI_CmsToolHandler.getPosition()public String getShortName()
I_CmsToolHandler
getShortName in interface I_CmsToolHandlerI_CmsToolHandler.getShortName()public String getSmallIconPath()
I_CmsToolHandler
getSmallIconPath in interface I_CmsToolHandlerI_CmsToolHandler.getSmallIconPath()public void setDisabledHelpText(String disabledHelpText)
disabledHelpText - the help text to setpublic void setGroup(String group)
group - the group to setpublic void setHelpText(String helpText)
helpText - the help text to setpublic void setIconPath(String iconPath)
iconPath - the icon path to setpublic void setLink(String link)
link - the link to setpublic void setName(String name)
name - the name to setpublic void setParameters(String parameters)
parameters - the parameters to setpublic void setPath(String path)
path - the path to setpublic void setPosition(float position)
position - the position to setpublic void setShortName(String shortName)
shortName - the short name to setpublic void setSmallIconPath(String smallIconPath)
smallIconPath - the samll icon path to set
public boolean setup(CmsObject cms,
String resourcePath)
CmsPropertyDefinition.PROPERTY_NAVIMAGE property,
or uses a default icon if undefined, the name is taken from the
CmsPropertyDefinition.PROPERTY_NAVTEXT property,
or uses the CmsPropertyDefinition.PROPERTY_TITLE property if undefined,
or an default text, if still undefined. if you want 2 different names, one for the big icon tools and one for
the menu/navbar entries, use a VALUE_SEPARATOR to separate them in the property.
(if you do so, the first one is for big icons and the second one for menu/navbar entries). the help text is taken from the
CmsPropertyDefinition.PROPERTY_DESCRIPTION property or a
default text if undefined, if you want to custumize a help text while disabled, use a
VALUE_SEPARATOR as a separator in the same property.
The group is taken from the property,
the position from the CmsPropertyDefinition.PROPERTY_NAVINFO
and the install path is given by the folder structure if the CmsPropertyDefinition.PROPERTY_NAVPOS
property does not include path information.ARGS_PROPERTY_DEFINITION
For the icon path you can specify 2 paths separated by a ,
the first one will be used as a group icon (32x32), and the second as an menu icon (16x16). VALUE_SEPARATOR
setup in interface I_CmsToolHandlercms - the admin context (at opencms-workplace (re-)initialization time)resourcePath - the resource path of the file/folder to use as admin tool
false if something goes wrongI_CmsToolHandler.setup(org.opencms.file.CmsObject, java.lang.String)public String toString()
Object.toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||