Package com.storedobject.ui
Class ELabel
java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.Composite<com.vaadin.flow.component.html.Span>
com.storedobject.vaadin.StyledText
com.storedobject.ui.ELabel
- All Implemented Interfaces:
StyledBuilder
,StyledBuilder
,HasSize
,HTMLGenerator
,com.vaadin.flow.component.AttachNotifier
,com.vaadin.flow.component.DetachNotifier
,com.vaadin.flow.component.HasElement
,com.vaadin.flow.component.HasSize
,com.vaadin.flow.component.HasStyle
,com.vaadin.flow.component.HasText
,Serializable
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.vaadin.flow.component.HasText
com.vaadin.flow.component.HasText.WhiteSpace
Nested classes/interfaces inherited from interface com.storedobject.common.StyledBuilder
StyledBuilder.Style
-
Field Summary
FieldsFields inherited from interface com.storedobject.vaadin.HTMLGenerator
CHAR_ENTITIES
Fields inherited from interface com.storedobject.common.StyledBuilder
EMPTY_STRINGS
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAppend an object.Append an object with the given color.Append an object with the given style.appendHTML
(String html) void
clear()
Clear the content.drawLine()
getHTML()
Get the HTML text generated.getValue()
boolean
isEmpty()
Check if the content is empty or not.boolean
Check if the last add was a new line or not.newLine
(boolean force) Adds a new line.void
void
Set a value.void
Set a value with the given styles.space
(int count) toString()
update()
Update internals if required.Methods inherited from class com.storedobject.vaadin.StyledText
getText, initContent, onAttach
Methods inherited from class com.vaadin.flow.component.Composite
getChildren, getContent, getElement
Methods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onDetach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisible
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListener
Methods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListener
Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
Methods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidthFull
Methods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
Methods inherited from interface com.vaadin.flow.component.HasText
getText, getWhiteSpace, setWhiteSpace
Methods inherited from interface com.storedobject.vaadin.HTMLGenerator
getPrintText
Methods inherited from interface com.storedobject.common.StyledBuilder
append, newLine, setValue
Methods inherited from interface com.storedobject.ui.StyledBuilder
appendIcon, appendWithTag, appendWithTag, blackMessage, blueMessage, redMessage
-
Field Details
-
label
-
-
Constructor Details
-
ELabel
public ELabel() -
ELabel
-
ELabel
-
ELabel
-
ELabel
-
-
Method Details
-
newLine
Description copied from interface:StyledBuilder
Adds a new line.- Specified by:
newLine
in interfaceStyledBuilder
- Specified by:
newLine
in interfaceStyledBuilder
- Parameters:
force
- If true, a new line is added anyway. Otherwise, no new line should be added ifStyledBuilder.isNewLine()
returns false.- Returns:
- Self-reference is returned.
-
isNewLine
public boolean isNewLine()Description copied from interface:StyledBuilder
Check if the last add was a new line or not.- Specified by:
isNewLine
in interfaceStyledBuilder
- Returns:
- True/false
-
drawLine
- Specified by:
drawLine
in interfaceStyledBuilder
-
append
Description copied from interface:StyledBuilder
Append an object with the given style.- Specified by:
append
in interfaceStyledBuilder
- Specified by:
append
in interfaceStyledBuilder
- Parameters:
object
- Object to append.style
- Styles to be set. (Default implementation ignores this).- Returns:
- Self-reference is returned.
-
append
Description copied from interface:StyledBuilder
Append an object with the given color.- Specified by:
append
in interfaceStyledBuilder
- Specified by:
append
in interfaceStyledBuilder
- Parameters:
object
- Object to append.color
- Color to be set. (Default implementation ignores this).- Returns:
- Self-reference is returned.
-
append
Description copied from interface:StyledBuilder
Append an object.- Specified by:
append
in interfaceStyledBuilder
- Specified by:
append
in interfaceStyledBuilder
- Parameters:
object
- Object to append.- Returns:
- Self-reference is returned.
-
appendHTML
- Specified by:
appendHTML
in interfaceStyledBuilder
-
space
- Specified by:
space
in interfaceStyledBuilder
-
clearContent
Description copied from interface:StyledBuilder
Clear the content.- Specified by:
clearContent
in interfaceStyledBuilder
- Specified by:
clearContent
in interfaceStyledBuilder
- Returns:
- Self-reference is returned.
-
clear
public void clear()- Specified by:
clear
in interfaceStyledBuilder
-
update
Description copied from interface:StyledBuilder
Update internals if required. (Default implementation does nothing).- Specified by:
update
in interfaceStyledBuilder
- Specified by:
update
in interfaceStyledBuilder
- Returns:
- Self-reference is returned.
-
setText
- Specified by:
setText
in interfacecom.vaadin.flow.component.HasText
- Overrides:
setText
in classStyledText
-
isEmpty
public boolean isEmpty()Description copied from interface:StyledBuilder
Check if the content is empty or not.- Specified by:
isEmpty
in interfaceStyledBuilder
- Specified by:
isEmpty
in interfaceStyledBuilder
- Returns:
- True or false.
-
getInternalStyledBuilder
- Specified by:
getInternalStyledBuilder
in interfaceStyledBuilder
-
setValue
Description copied from interface:StyledBuilder
Set a value with the given styles. (Previous content if any will be cleared).- Specified by:
setValue
in interfaceStyledBuilder
- Specified by:
setValue
in interfaceStyledBuilder
- Parameters:
object
- Object (value) to set.style
- Styles to be set.
-
setValue
Description copied from interface:StyledBuilder
Set a value. (Previous content if any will be cleared).- Specified by:
setValue
in interfaceStyledBuilder
- Specified by:
setValue
in interfaceStyledBuilder
- Parameters:
object
- Object (value) to set.
-
getValue
- Specified by:
getValue
in interfaceStyledBuilder
-
getApplication
- Specified by:
getApplication
in interfaceStyledBuilder
-
toString
-
getHTML
Description copied from interface:HTMLGenerator
Get the HTML text generated. (The generated HTML may not contain outer tags. So, span or div tag may be used to bracket it in order to make it a valid HTML text).- Specified by:
getHTML
in interfaceHTMLGenerator
- Specified by:
getHTML
in interfaceStyledBuilder
- Overrides:
getHTML
in classStyledText
- Returns:
- HTML text generated.
-