Class BaseCardLayout
java.lang.Object
com.vaadin.featurepack.desktop.layouts.BaseCardLayout
- All Implemented Interfaces:
Serializable
Card layout treats each component in the container as a card. Only one card
is visible at a time, and the container acts as a stack of cards.
- Author:
- Vaadin Ltd
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected List<com.vaadin.flow.component.Component> protected int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidfirst()Shows the first card and hides all the others.List<com.vaadin.flow.component.Component> getCards()intvoidlast()Shows the last card and hides all the others.voidnext()Shows the next card and hides all the others.voidprevious()Shows the previous card and hides all the others.voidsetCurrentCard(int currentCard) voidShows the component that was added to this layout with the specified name, using.invalid reference
#setConstraints(Component, Object)
-
Field Details
-
currentCard
protected int currentCard -
cards
-
-
Constructor Details
-
BaseCardLayout
public BaseCardLayout()
-
-
Method Details
-
first
public void first()Shows the first card and hides all the others. -
last
public void last()Shows the last card and hides all the others. -
previous
public void previous()Shows the previous card and hides all the others. If the currently visible card is the first one, the last card is shown. -
next
public void next()Shows the next card and hides all the others. If the currently visible card is the last one, the first card is shown. -
show
Shows the component that was added to this layout with the specified name, using. If no such component exists, then nothing happens.invalid reference
#setConstraints(Component, Object)- Parameters:
name- the component name
-
getCards
-
getCurrentCard
public int getCurrentCard() -
setCurrentCard
public void setCurrentCard(int currentCard)
-