Class AnnoViewService
java.lang.Object
edu.kit.datamanager.takita.mainpage.dashboard.annoview.AnnoViewService
- All Implemented Interfaces:
IAnnoViewService
Implementation of ContentView Service for type AnnoView.
Has specific methods for AnnoView Content, such as get Thumbnails,
add Attribute, delete Attribute.
Has a name/type of ContentView it is implementing and holds the Attributes
that are currently selected to be displayed.
-
Constructor Summary
ConstructorsConstructorDescriptionAnnoViewService(ISearchService searchService) Constructor for the Anno View Service to autowire required instances. -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.boot.configurationprocessor.json.JSONArraygetData()Gets results and formats them in JSON Array for table to read.Gets search Results from Search Service.getType()Gets Type of content view.search()Trigger search.voidupdateModel(org.springframework.ui.Model model) Update Model with everything from AnnoViewService.
-
Constructor Details
-
AnnoViewService
Constructor for the Anno View Service to autowire required instances.- Parameters:
searchService- instance of the logic for search. Injected with Springs dependency injection system indicated by @autowired annotation.
-
-
Method Details
-
search
Trigger search.- Returns:
- List of Manuscripts
-
getResults
Gets search Results from Search Service.- Returns:
- List of Manuscripts
-
getType
Gets Type of content view.- Specified by:
getTypein interfaceIAnnoViewService- Returns:
- type of content view as String
-
updateModel
public void updateModel(org.springframework.ui.Model model) Update Model with everything from AnnoViewService.- Parameters:
model- the holder for model attributes, used to pass attributes back to the view
-
getData
public org.springframework.boot.configurationprocessor.json.JSONArray getData() throws org.springframework.boot.configurationprocessor.json.JSONExceptionGets results and formats them in JSON Array for table to read.- Returns:
- table data as JSONArray
- Throws:
org.springframework.boot.configurationprocessor.json.JSONException- if the data could not be parsed to a JSONObject
-