Package org.patternfly.component.alert
Class AlertGroup
- java.lang.Object
-
- org.patternfly.component.BaseComponent<HTMLUListElement,AlertGroup>
-
- org.patternfly.component.alert.AlertGroup
-
- All Implemented Interfaces:
Container<HTMLUListElement,AlertGroup>,Finder<HTMLUListElement>,HasElement<HTMLUListElement,AlertGroup>,HasHTMLElement<HTMLUListElement,AlertGroup>,IsElement<HTMLUListElement>,TypedBuilder<HTMLUListElement,AlertGroup>,Component
public class AlertGroup extends BaseComponent<HTMLUListElement,AlertGroup>
An alert group stacks and positions 2 or more alerts in a live region, either in a layer over the main content of a page or inline with the page content. Alert groups should always rank alerts by age, stacking new alerts on top of old ones as they surface.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description AlertGroupadd(Alert alert)AlertGroupaddAlert(Alert alert)<T> AlertGroupaddAlerts(Iterable<T> items, Function<T,Alert> display)static AlertGroupalertGroup(AlertGroupType type)Creates a new alert group of the given type without timeout.static AlertGroupalertGroup(AlertGroupType type, int timeout)Creates a new alert group of the given type and timeout.AlertGroupthat()-
Methods inherited from class org.patternfly.component.BaseComponent
componentType, element
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jboss.elemento.Container
add, add, add, addAll, addAll, addAll, addAll, addAll, addAll
-
-
-
-
Method Detail
-
alertGroup
public static AlertGroup alertGroup(AlertGroupType type)
Creates a new alert group of the given type without timeout.If the type is
AlertGroupType.toastthe alert group is added to the body or if it already has been added the existing alert group is returned (singleton pattern).
-
alertGroup
public static AlertGroup alertGroup(AlertGroupType type, int timeout)
Creates a new alert group of the given type and timeout.If the type is
AlertGroupType.toastthe alert group is added to the body or if it already has been added the existing alert group is returned (singleton pattern).
-
addAlerts
public <T> AlertGroup addAlerts(Iterable<T> items, Function<T,Alert> display)
-
addAlert
public AlertGroup addAlert(Alert alert)
-
add
public AlertGroup add(Alert alert)
-
that
public AlertGroup that()
-
-