|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object info.magnolia.cms.gui.dialog.DialogControlImpl
public abstract class DialogControlImpl
Field Summary | |
---|---|
static java.lang.String |
DEFAULT_VALUE_PROPERTY
|
static java.lang.String |
SESSION_ATTRIBUTENAME_DIALOGOBJECT
|
static java.lang.String |
SESSION_ATTRIBUTENAME_DIALOGOBJECT_REMOVE
|
static java.lang.String |
VALIDATION_PATTERN_PROPERTY
|
protected java.lang.String |
value
|
Constructor Summary | |
---|---|
DialogControlImpl()
|
Method Summary | |
---|---|
void |
addOption(java.lang.Object o)
|
void |
addSub(java.lang.Object o)
|
protected void |
clearWebsiteNode()
Deprecated. websitenode should only be set in init(), this is a workaround used in DialogDate |
void |
drawHtml(java.io.Writer out)
Actually draw the dialog content. |
protected void |
drawHtmlPostSubs(java.io.Writer out)
|
protected void |
drawHtmlPreSubs(java.io.Writer out)
|
protected void |
drawSubs(java.io.Writer out)
|
java.lang.String |
getConfigValue(java.lang.String key)
|
java.lang.String |
getConfigValue(java.lang.String key,
java.lang.String nullValue)
|
java.lang.String |
getDescription()
|
java.lang.String |
getId()
|
java.lang.String |
getLabel()
|
java.lang.String |
getMessage(java.lang.String key)
Get the message. |
java.lang.String |
getMessage(java.lang.String key,
java.lang.Object[] args)
Get the message with replacement strings. |
protected Messages |
getMessages()
Get the AbstractMessagesImpl object for this dialog/control. |
java.lang.String |
getName()
Return the configured name of this control (not the id). |
java.util.List |
getOptions()
|
DialogControlImpl |
getParent()
|
javax.servlet.http.HttpServletRequest |
getRequest()
|
protected javax.servlet.http.HttpServletResponse |
getResponse()
|
Content |
getStorageNode()
|
DialogControlImpl |
getSub(java.lang.String name)
Find a control by its name |
java.util.List |
getSubs()
|
DialogControlImpl |
getTopParent()
|
java.lang.String |
getValidationPattern()
|
java.lang.String |
getValue()
|
java.util.List |
getValues()
|
Content |
getWebsiteNode()
Deprecated. use getStorageNode() |
void |
init(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
Content storageNode,
Content configNode)
Initialize a Dialog. |
boolean |
isRequired()
True if a value is required. |
protected java.lang.String |
readValue()
|
protected java.util.List |
readValues()
|
void |
removeSessionAttribute()
|
void |
setConfig(java.lang.String key,
boolean value)
|
void |
setConfig(java.lang.String key,
int value)
|
void |
setConfig(java.lang.String key,
java.lang.String value)
|
void |
setDescription(java.lang.String s)
|
void |
setLabel(java.lang.String s)
|
void |
setName(java.lang.String s)
Set the name of this control. |
void |
setOptions(java.util.List options)
|
void |
setRequired(boolean required)
|
void |
setSaveInfo(boolean b)
|
void |
setSessionAttribute()
This method sets a control into the session |
protected void |
setTopParent(DialogControlImpl top)
|
protected void |
setValidationMessage(java.lang.String msg)
|
void |
setValue(java.lang.String s)
|
boolean |
validate()
If the validation fails the code will set a message in the context using the AlertUtil. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String VALIDATION_PATTERN_PROPERTY
public static final java.lang.String DEFAULT_VALUE_PROPERTY
public static final java.lang.String SESSION_ATTRIBUTENAME_DIALOGOBJECT
public static final java.lang.String SESSION_ATTRIBUTENAME_DIALOGOBJECT_REMOVE
protected java.lang.String value
Constructor Detail |
---|
public DialogControlImpl()
Method Detail |
---|
public void init(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Content storageNode, Content configNode) throws javax.jcr.RepositoryException
DialogControl
init
in interface DialogControl
request
- current HttpServletRequestresponse
- current HttpServletResponsestorageNode
- current website nodeconfigNode
- configuration node for the dialog
javax.jcr.RepositoryException
public void drawHtml(java.io.Writer out) throws java.io.IOException
DialogControl
drawHtml
in interface DialogControl
out
- Writer
java.io.IOException
- exceptions thrown when writing to the Writer can be safely rethrown by the dialogDialogControl.drawHtml(Writer)
public void addSub(java.lang.Object o)
public void setConfig(java.lang.String key, java.lang.String value)
public void setConfig(java.lang.String key, boolean value)
public void setConfig(java.lang.String key, int value)
public java.lang.String getConfigValue(java.lang.String key, java.lang.String nullValue)
public java.lang.String getConfigValue(java.lang.String key)
public void setValue(java.lang.String s)
public java.lang.String getValue()
protected java.lang.String readValue()
public void setSaveInfo(boolean b)
public void setName(java.lang.String s)
public java.lang.String getName()
public void addOption(java.lang.Object o)
public Content getStorageNode()
public void setLabel(java.lang.String s)
public void setDescription(java.lang.String s)
public void removeSessionAttribute()
public javax.servlet.http.HttpServletRequest getRequest()
public void setOptions(java.util.List options)
protected void drawHtmlPreSubs(java.io.Writer out) throws java.io.IOException
java.io.IOException
protected void drawSubs(java.io.Writer out) throws java.io.IOException
java.io.IOException
protected void drawHtmlPostSubs(java.io.Writer out) throws java.io.IOException
java.io.IOException
public DialogControlImpl getParent()
protected void setTopParent(DialogControlImpl top)
public DialogControlImpl getTopParent()
public java.util.List getSubs()
public DialogControlImpl getSub(java.lang.String name)
name
- the name of the control to find
protected javax.servlet.http.HttpServletResponse getResponse()
@Deprecated protected void clearWebsiteNode()
public java.lang.String getId()
public java.lang.String getLabel()
public java.lang.String getDescription()
public java.util.List getOptions()
public java.util.List getValues()
protected java.util.List readValues()
public void setSessionAttribute()
protected Messages getMessages()
i18nBasename
, then it tries to find the parent with the first definition.
public java.lang.String getMessage(java.lang.String key)
key
- key
public java.lang.String getMessage(java.lang.String key, java.lang.Object[] args)
key
- keyargs
- replacement strings
public boolean validate()
protected void setValidationMessage(java.lang.String msg)
public java.lang.String getValidationPattern()
public boolean isRequired()
public void setRequired(boolean required)
@Deprecated public Content getWebsiteNode()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |