Package org.zkoss.stateless.sul
Interface IHtml
- All Superinterfaces:
IAnyGroup<IHtml>,IComponent<IHtml>,IHtmlBasedComponent<IHtml>,IXulElement<IHtml>
Immutable
Html component
A component used to embed the browser native content (i.e., HTML tags)
into the output sent to the browser.
The browser native content is specified by withContent(java.lang.String).
Notice that Html generates HTML SPAN to enclose
the embedded HTML tags. Thus, you can specify the style
(IHtmlBasedComponent.getStyle()), tooltip IXulElement.getTooltip() and so on.
- Author:
- katherine
- See Also:
-
Html
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classBuilds instances of typeIHtml.static classBuilds an updater of typeIHtmlforUiAgent.smartUpdate(Locator, SmartUpdater). -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault StringReturns the embedded content (i.e., HTML tags).default StringReturns the client widget class.static IHtmlReturns the instance with the given content.static IHtmlReturns the instance with the given id.withContent(String content) Returns a copy ofthisimmutable component with the specifiedcontent.Methods inherited from interface org.zkoss.stateless.sul.IComponent
getAction, getActions, getClientAttributes, getId, getMold, getWidgetListeners, getWidgetOverrides, isVisible, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withActions, withActions, withClientAttribute, withClientAttributes, withId, withMold, withVisible, withWidgetClass, withWidgetListener, withWidgetListeners, withWidgetOverride, withWidgetOverridesMethods inherited from interface org.zkoss.stateless.sul.IHtmlBasedComponent
getClientAction, getDraggable, getDroppable, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getSkeleton, getStyle, getTabindex, getTooltiptext, getTop, getVflex, getWidth, getZclass, getZIndex, isFocus, withClientAction, withDraggable, withDroppable, withFocus, withHeight, withHflex, withLeft, withRenderdefer, withSclass, withSkeleton, withStyle, withTabindex, withTabindex, withTooltiptext, withTop, withVflex, withWidth, withZclass, withZIndexMethods inherited from interface org.zkoss.stateless.sul.IXulElement
getContext, getCtrlKeys, getPopup, getTooltip, withContext, withCtrlKeys, withPopup, withTooltip
-
Field Details
-
DEFAULT
Constant for default attributes of this immutable component.
-
-
Method Details
-
getWidgetClass
Returns the client widget class.Default:
"zul.wgt.Html"- Specified by:
getWidgetClassin interfaceIComponent<IHtml>
-
getContent
Returns the embedded content (i.e., HTML tags). -
withContent
Returns a copy ofthisimmutable component with the specifiedcontent.Sets the embedded content (i.e., HTML tags).
Security Note
Unlike other methods, the content assigned to this method is generated directly to the browser without escaping. Thus, it is better not to have something input by the user to avoid any XSS attach.
- Parameters:
content- The HTML content.Default:
"".- Returns:
- A modified copy of the
thisobject
-
of
Returns the instance with the given content.- Parameters:
content- The HTML content
-
ofId
Returns the instance with the given id.- Parameters:
id- The id to identify this component
-