Package com.storedobject.ui
Class ObjectCard<T extends StoredObject>
java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.Composite<com.vaadin.flow.component.Component>
com.storedobject.ui.Card<T>
com.storedobject.ui.ObjectCard<T>
- Type Parameters:
T- the type of the object stored in the card, which must extend the StoredObject class
- All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier,com.vaadin.flow.component.DetachNotifier,com.vaadin.flow.component.HasComponents,com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasEnabled,com.vaadin.flow.component.HasStyle,Serializable
Represents a generic card that holds a reference to an object of type T, where T is a subclass
of StoredObject. This class extends the functionality of the Card class.
- Author:
- Syam
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.storedobject.ui.Card
Card.Cell, Card.Column, Card.Line, Card.Row -
Constructor Summary
ConstructorsConstructorDescriptionConstructs an instance of ObjectCard with no initial configuration or root component.ObjectCard(com.vaadin.flow.component.Component root) Constructs an ObjectCard with the specified root component. -
Method Summary
Methods inherited from class com.storedobject.ui.Card
alignBottom, alignCenter, alignTop, getObject, getView, ignoreSelection, initContent, isIgnoreSelection, isSelected, justifyCenter, justifyLeft, justifyRight, onDetach, setColumnSpan, setObject, setRowSpan, setSelected, toggleSelectionMethods inherited from class com.vaadin.flow.component.Composite
getChildren, getContent, getElementMethods 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, onAttach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisibleMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListenerMethods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListenerMethods inherited from interface com.vaadin.flow.component.HasComponents
add, add, add, addComponentAsFirst, addComponentAtIndex, getChildren, getComponentAt, getComponentCount, indexOf, remove, remove, removeAll, replaceMethods inherited from interface com.vaadin.flow.component.HasElement
getElementMethods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled, setEnabledMethods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
-
Constructor Details
-
ObjectCard
public ObjectCard()Constructs an instance of ObjectCard with no initial configuration or root component. This constructor initializes the ObjectCard using the default behavior of its parent class. -
ObjectCard
public ObjectCard(com.vaadin.flow.component.Component root) Constructs an ObjectCard with the specified root component. The root component represents the content to be displayed within the card. This constructor initializes the ObjectCard by invoking the parent Card class's constructor, applying default styles and layout settings.- Parameters:
root- the content component to be displayed within the ObjectCard. It is passed to the parent Card class as its content.
-
-
Method Details
-
refresh
public void refresh()Refreshes the content of the card. -
reload
public void reload()Reloads the object and refreshes the card with updated data.
-