Class ApplicationSearchView
- java.lang.Object
-
- com.vaadin.flow.component.Component
-
- com.vaadin.flow.component.orderedlayout.HorizontalLayout
-
- com.group21.jobTracker.ui.applicationSearch.ApplicationSearchView
-
- All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier,com.vaadin.flow.component.ClickNotifier<com.vaadin.flow.component.orderedlayout.HorizontalLayout>,com.vaadin.flow.component.DetachNotifier,com.vaadin.flow.component.HasComponents,com.vaadin.flow.component.HasElement,com.vaadin.flow.component.HasEnabled,com.vaadin.flow.component.HasOrderedComponents,com.vaadin.flow.component.HasSize,com.vaadin.flow.component.HasStyle,com.vaadin.flow.component.orderedlayout.FlexComponent,com.vaadin.flow.component.orderedlayout.ThemableLayout,com.vaadin.flow.router.BeforeEnterObserver,com.vaadin.flow.router.HasUrlParameter<String>,com.vaadin.flow.router.internal.BeforeEnterHandler,Serializable
@Route(value="ApplicationSearch", layout=MainLayout.class) public class ApplicationSearchView extends com.vaadin.flow.component.orderedlayout.HorizontalLayout implements com.vaadin.flow.router.HasUrlParameter<String>, com.vaadin.flow.router.BeforeEnterObserverRepresents the UI for the "Application Search" page, incorporates functionality for "CRUD" operations as well.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ApplicationSearchView()Constructor for the ApplicationSearchView object
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbeforeEnter(com.vaadin.flow.router.BeforeEnterEvent event)voidclearSelection()Deselects the selected row in the grid.com.vaadin.flow.component.orderedlayout.HorizontalLayoutcreateTopBar()Method to create the top bar on the UI (Search bar and button to search for new apps)voideditJob(Jobs job)Displays user a form to edit a job.voidselectRow(Jobs row)Selects a rowvoidsetParameter(com.vaadin.flow.router.BeforeEvent event, String parameter)voidshowError(String msg)Method to show error messages.voidshowForm(boolean show)Shows and hides the new product formvoidshowNotification(String msg)Shows a temporary popup notification to the user.voidupdateProduct(Jobs job)Updates a job in the list of products.-
Methods inherited from class com.vaadin.flow.component.orderedlayout.HorizontalLayout
addAndExpand, getAlignItems, getAlignSelf, getDefaultVerticalComponentAlignment, getVerticalComponentAlignment, setAlignItems, setAlignSelf, setDefaultVerticalComponentAlignment, setSpacing, setVerticalComponentAlignment
-
Methods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, scrollIntoView, set, setElement, setId, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.flow.component.ClickNotifier
addClickListener, addClickShortcut
-
Methods inherited from interface com.vaadin.flow.component.orderedlayout.FlexComponent
expand, getFlexGrow, getJustifyContentMode, replace, setFlexGrow, setJustifyContentMode
-
Methods inherited from interface com.vaadin.flow.component.HasComponents
add, add, add, addComponentAsFirst, addComponentAtIndex, remove, remove, removeAll
-
Methods inherited from interface com.vaadin.flow.component.HasOrderedComponents
getChildren, getComponentAt, getComponentCount, indexOf
-
Methods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFull
-
-
-
-
Field Detail
-
VIEW_NAME
public static final String VIEW_NAME
Represents the name of the page- See Also:
- Constant Field Values
-
-
Method Detail
-
createTopBar
public com.vaadin.flow.component.orderedlayout.HorizontalLayout createTopBar()
Method to create the top bar on the UI (Search bar and button to search for new apps)- Returns:
- a HorizontalLayout container
-
showError
public void showError(String msg)
Method to show error messages.- Parameters:
msg- error message
-
showNotification
public void showNotification(String msg)
Shows a temporary popup notification to the user.- Parameters:
msg- message to display- See Also:
Notification.show(String)
-
clearSelection
public void clearSelection()
Deselects the selected row in the grid.
-
selectRow
public void selectRow(Jobs row)
Selects a row- Parameters:
row- given row to select in the grid
-
updateProduct
public void updateProduct(Jobs job)
Updates a job in the list of products.- Parameters:
job- to be updated
-
editJob
public void editJob(Jobs job)
Displays user a form to edit a job.- Parameters:
job- to be edited
-
showForm
public void showForm(boolean show)
Shows and hides the new product form- Parameters:
show- whether the form should be shown or not
-
setParameter
public void setParameter(com.vaadin.flow.router.BeforeEvent event, @OptionalParameter String parameter)- Specified by:
setParameterin interfacecom.vaadin.flow.router.HasUrlParameter<String>
-
beforeEnter
public void beforeEnter(com.vaadin.flow.router.BeforeEnterEvent event)
- Specified by:
beforeEnterin interfacecom.vaadin.flow.router.internal.BeforeEnterHandler
-
-