|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.cc.framework.taglib.TagHelp
Helper for the tag library
Constructor Summary | |
private |
TagHelp()
Constructor |
Method Summary | |
static boolean |
checkForBaseClass(java.lang.Class theClass,
java.lang.Class baseClass)
This method checks if a class is derived from the specified base class |
static boolean |
checkRunAtClient(RunAt runat,
javax.servlet.jsp.PageContext pageContext)
This Method checks if a component should run on the client |
static org.apache.ecs.html.IMG |
createImage(javax.servlet.jsp.PageContext pageContext,
ImageModel image)
Creates an IMG Tag for the specified Image. |
static FormElementContainerTag |
getContainer(javax.servlet.jsp.tagext.Tag tag)
Searches the Tag hierarchy for a FormElementContainerTag parent |
static javax.servlet.jsp.tagext.Tag |
getParentTag(javax.servlet.jsp.tagext.Tag tag,
java.lang.Class parrentTagClass)
Searches the Tag hierarchy for a FrameContainerTag parent |
static java.lang.String |
getSource(javax.servlet.jsp.PageContext pageContext,
java.lang.String base,
java.lang.String src,
java.util.Locale locale)
Returns the localized Image resource name |
static void |
hideButtons(ButtonContainer frame,
java.lang.String controlButtonList)
Hides all buttons in the ControlButton List. |
static java.util.Locale |
localeFromName(javax.servlet.jsp.PageContext pageContext,
java.lang.String localeName)
Gets the Locale Object from a Locale Name |
static java.util.Locale |
localeFromSession(javax.servlet.jsp.PageContext pageContext)
Gets the Locale Object for the running session |
static java.lang.String |
localize(javax.servlet.jsp.PageContext pageContext,
java.lang.String keyOrString)
Localizes a string depending on the localization settings of the Painter context. |
static java.lang.String |
localize(javax.servlet.jsp.PageContext pageContext,
java.lang.String keyOrString,
java.lang.Object[] arguments)
Localizes a string depending on the localization settings of the Painter context. |
static java.lang.String |
localize(javax.servlet.jsp.PageContext pageContext,
java.lang.String keyOrString,
java.lang.Object[] arguments,
java.util.Locale locale)
Localizes a string depending on the localization settings of the Painter context. |
static java.lang.String |
localize(javax.servlet.jsp.PageContext pageContext,
java.lang.String keyOrString,
java.lang.Object[] arguments,
java.util.Locale locale,
boolean returnNull)
Localizes a string depending on the localization settings of the Painter context. |
static java.lang.String |
localizeKey(javax.servlet.jsp.PageContext pageContext,
java.lang.String resourceKey,
java.lang.Object[] arguments,
java.util.Locale locale,
boolean returnNull)
Localizes a string depending on the localization settings of the Painter context. |
static java.lang.Object |
lookupBean(javax.servlet.jsp.PageContext pageContext,
javax.servlet.jsp.tagext.TagSupport taghandler,
java.lang.String name,
java.lang.String property,
HttpScope scope)
Lookup a Javabean for use in a JSP tag handler. |
static ImageMap |
lookupImageMap(javax.servlet.jsp.PageContext pageContext,
java.lang.String mapName)
Returns an image map |
static java.lang.String |
resolveRelativePropertyName(javax.servlet.jsp.PageContext pageContext,
java.lang.String relPropertyName)
Resolves the relative property name to a fully qualified property name |
static boolean |
showComments(javax.servlet.jsp.PageContext pageContext)
Checks if painters should write additional comments into the output |
static AlignmentType |
toAlignment(java.lang.String alignment)
Creates a AlignmentType object for the specified argument. |
static boolean |
toBoolean(java.lang.Object obj)
Converts an object to a boolean if possible |
static boolean |
toBoolean(java.lang.Object value,
boolean defValue)
Determines the boolean Value of the specified Object |
static boolean |
toBoolean(java.lang.String str)
Parses a string an returns a boolean value. |
static CheckRange |
toCheckRange(java.lang.String range)
Creates a CheckRange object for the specified argument. |
static Color |
toColor(java.lang.String color)
Creates a color object for the specified argument. |
static int |
toInt(java.lang.String str)
Converts an object to a integer if possible |
static int[] |
toIntArray(java.lang.String str)
Converts an object to a integer array if possible |
static OrientationType |
toOrientation(java.lang.String orientation)
Creates a OrientationType object for the specified argument. |
static Permission |
toPermission(boolean granted)
Creates a permission object for the specified argument. |
static Permission |
toPermission(java.lang.String permission)
Creates a permission object for the specified argument. |
static SortOrder |
toSortOrder(java.lang.String sortOrder)
Creates a sort order object for the specified argument. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
private TagHelp()
Method Detail |
public static java.lang.String resolveRelativePropertyName(javax.servlet.jsp.PageContext pageContext, java.lang.String relPropertyName) throws javax.servlet.jsp.JspException
pageContext
- PageContextrelPropertyName
- the relative property name
javax.servlet.jsp.JspException
public static boolean showComments(javax.servlet.jsp.PageContext pageContext)
pageContext
- JspPage
public static void hideButtons(ButtonContainer frame, java.lang.String controlButtonList) throws javax.servlet.jsp.JspException
frame
- The framed controlcontrolButtonList
- A semicolon delimited list of ControlButton names
javax.servlet.jsp.JspException
- Is thrown when a invalid ControlButton Name is specifiedpublic static boolean checkRunAtClient(RunAt runat, javax.servlet.jsp.PageContext pageContext)
runat
- RunAt setting of the componentpageContext
- JSP Page Context
true
when the component should run on the
clientpublic static java.util.Locale localeFromSession(javax.servlet.jsp.PageContext pageContext)
pageContext
- JSP Page Context
null
public static java.util.Locale localeFromName(javax.servlet.jsp.PageContext pageContext, java.lang.String localeName)
pageContext
- JSP Page ContextlocaleName
- The Name
null
public static java.lang.String getSource(javax.servlet.jsp.PageContext pageContext, java.lang.String base, java.lang.String src, java.util.Locale locale)
pageContext
- JSP Page Contextbase
- Base Directory or resource keysrc
- Resource namelocale
- Locale or null
public static boolean toBoolean(java.lang.Object value, boolean defValue)
value
- ObjectdefValue
- Default Value
public static java.lang.String localize(javax.servlet.jsp.PageContext pageContext, java.lang.String keyOrString)
pageContext
- JSP Page ContextkeyOrString
- String Literal or Resource Key
public static java.lang.String localize(javax.servlet.jsp.PageContext pageContext, java.lang.String keyOrString, java.lang.Object[] arguments)
pageContext
- JSP Page ContextkeyOrString
- String Literal or Resource Keyarguments
- MessageFormat arguments or null
public static java.lang.String localize(javax.servlet.jsp.PageContext pageContext, java.lang.String keyOrString, java.lang.Object[] arguments, java.util.Locale locale)
pageContext
- JSP Page ContextkeyOrString
- String Literal or Resource Keyarguments
- MessageFormat arguments or null
locale
- Locale or null
public static java.lang.String localize(javax.servlet.jsp.PageContext pageContext, java.lang.String keyOrString, java.lang.Object[] arguments, java.util.Locale locale, boolean returnNull)
pageContext
- JSP Page ContextkeyOrString
- The String literal or resource key.arguments
- MessageFormat arguments or null
locale
- Locale or null
returnNull
- controls whether to return null or a not present indicator
public static java.lang.String localizeKey(javax.servlet.jsp.PageContext pageContext, java.lang.String resourceKey, java.lang.Object[] arguments, java.util.Locale locale, boolean returnNull)
pageContext
- JSP Page ContextresourceKey
- The resource key.arguments
- MessageFormat arguments or null
locale
- Locale or null
returnNull
- controls whether to return null or a not present indicator
public static org.apache.ecs.html.IMG createImage(javax.servlet.jsp.PageContext pageContext, ImageModel image)
pageContext
- JSP Page Contextimage
- ImageModel
public static FormElementContainerTag getContainer(javax.servlet.jsp.tagext.Tag tag) throws javax.servlet.jsp.JspException
tag
- the tag to start searching
javax.servlet.jsp.JspException
- is thrown when no parent is presentpublic static javax.servlet.jsp.tagext.Tag getParentTag(javax.servlet.jsp.tagext.Tag tag, java.lang.Class parrentTagClass) throws javax.servlet.jsp.JspException
tag
- the tag to start searchingparrentTagClass
- The Type of the parent tag
javax.servlet.jsp.JspException
- is thrown when no parent is presentpublic static java.lang.Object lookupBean(javax.servlet.jsp.PageContext pageContext, javax.servlet.jsp.tagext.TagSupport taghandler, java.lang.String name, java.lang.String property, HttpScope scope) throws javax.servlet.jsp.JspException
pageContext
- JSP page contexttaghandler
- the current tag handlername
- Name of the beanproperty
- Name of a beans propertyscope
- the scope where the bean should be located
null
javax.servlet.jsp.JspException
- is thrown in case of an errorpublic static ImageMap lookupImageMap(javax.servlet.jsp.PageContext pageContext, java.lang.String mapName) throws javax.servlet.jsp.JspException
pageContext
- The page contextmapName
- The name of the image map
javax.servlet.jsp.JspException
- If the image map can not be foundpublic static boolean checkForBaseClass(java.lang.Class theClass, java.lang.Class baseClass)
theClass
- the class to checkbaseClass
- the base class
true
if the class is derived from the
base classpublic static boolean toBoolean(java.lang.Object obj) throws javax.servlet.jsp.JspException
obj
- The object to convert
javax.servlet.jsp.JspException
- If the object can't be convertedpublic static int toInt(java.lang.String str) throws javax.servlet.jsp.JspException
str
- The string to convert
javax.servlet.jsp.JspException
- If the object can't be convertedpublic static int[] toIntArray(java.lang.String str) throws javax.servlet.jsp.JspException
str
- The string to convert
javax.servlet.jsp.JspException
- If the object can't be convertedpublic static boolean toBoolean(java.lang.String str) throws javax.servlet.jsp.JspException
str
- The string to parse
javax.servlet.jsp.JspException
- If the argument can't be parsedpublic static Permission toPermission(java.lang.String permission) throws javax.servlet.jsp.JspException
permission
- The string to parse
javax.servlet.jsp.JspException
- If the argument can not be parsedpublic static Permission toPermission(boolean granted)
granted
- grant
public static OrientationType toOrientation(java.lang.String orientation) throws javax.servlet.jsp.JspException
orientation
- The string to parse
javax.servlet.jsp.JspException
- If the argument can not be parsedpublic static SortOrder toSortOrder(java.lang.String sortOrder) throws javax.servlet.jsp.JspException
sortOrder
- The string to parse
javax.servlet.jsp.JspException
- If the argument can not be parsedpublic static AlignmentType toAlignment(java.lang.String alignment) throws javax.servlet.jsp.JspException
alignment
- The string to parse
javax.servlet.jsp.JspException
- If the argument can not be parsedpublic static CheckRange toCheckRange(java.lang.String range) throws javax.servlet.jsp.JspException
range
- The string to parse
javax.servlet.jsp.JspException
- If the argument can not be parsedpublic static Color toColor(java.lang.String color)
color
- The string with the color value to parse
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |