Class ApplicationSearchDataProvider
- java.lang.Object
-
- com.vaadin.flow.data.provider.AbstractDataProvider<T,com.vaadin.flow.function.SerializablePredicate<T>>
-
- com.vaadin.flow.data.provider.ListDataProvider<Jobs>
-
- com.group21.jobTracker.ui.applicationSearch.ApplicationSearchDataProvider
-
- All Implemented Interfaces:
com.vaadin.flow.data.provider.ConfigurableFilterDataProvider<Jobs,com.vaadin.flow.function.SerializablePredicate<Jobs>,com.vaadin.flow.function.SerializablePredicate<Jobs>>,com.vaadin.flow.data.provider.DataProvider<Jobs,com.vaadin.flow.function.SerializablePredicate<Jobs>>,com.vaadin.flow.data.provider.InMemoryDataProvider<Jobs>,Serializable
public class ApplicationSearchDataProvider extends com.vaadin.flow.data.provider.ListDataProvider<Jobs>
This class is the data provider for the application search page in JobTracker. The data pulled is from API calls to LinkedIn and CareerOneStop.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ApplicationSearchDataProvider(String keywords)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegergetId(Jobs job)voidsave(Jobs job)Store given job to the CSV backend.voidsetFilter(String filterText)Sets the filter to use for this data provider and refreshes data.-
Methods inherited from class com.vaadin.flow.data.provider.ListDataProvider
fetch, getFilter, getItems, getSortComparator, setFilter, setSortComparator, size
-
Methods inherited from class com.vaadin.flow.data.provider.AbstractDataProvider
addDataProviderListener, addListener, fireEvent, refreshAll, refreshItem, refreshItem
-
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.data.provider.DataProvider
addDataProviderListener, refreshAll, refreshItem, refreshItem, withConfigurableFilter, withConfigurableFilter, withConvertedFilter
-
Methods inherited from interface com.vaadin.flow.data.provider.InMemoryDataProvider
addFilter, addFilter, addFilterByValue, addSortComparator, addSortOrder, clearFilters, filteringBy, filteringBy, filteringByEquals, filteringByPrefix, filteringByPrefix, filteringBySubstring, filteringBySubstring, isInMemory, setFilter, setFilterByValue, setSortOrder
-
-
-
-
Constructor Detail
-
ApplicationSearchDataProvider
public ApplicationSearchDataProvider(String keywords)
Constructor- Parameters:
keywords- string that is used to limit the search for API calls (eg "Software Intern")
-
-
Method Detail
-
save
public void save(Jobs job)
Store given job to the CSV backend.- Parameters:
job- to be saved
-
setFilter
public void setFilter(String filterText)
Sets the filter to use for this data provider and refreshes data.Filter is compared for product name, availability and category.
- Parameters:
filterText- the text to filter by, never null
-
-