Class SearchServiceInstanceManager
- java.lang.Object
-
- org.ametys.web.frontoffice.search.instance.SearchServiceInstanceManager
-
- All Implemented Interfaces:
Disposable
,Component
,Serviceable
public class SearchServiceInstanceManager extends Object implements Component, Serviceable, Disposable
The component managing allSearchServiceInstance
s.
-
-
Constructor Summary
Constructors Constructor Description SearchServiceInstanceManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dispose()
SearchServiceInstance
get(String zoneItemId)
Gets, or creates if it does not exist yet, theSearchServiceInstance
which is placed at the givenZoneItem
.boolean
isSearchServiceInstance(String zoneItemId)
void
remove(String zoneItemId)
Removes theSearchServiceInstance
which is placed at the givenZoneItem
.void
service(ServiceManager manager)
-
-
-
Constructor Detail
-
SearchServiceInstanceManager
public SearchServiceInstanceManager()
-
-
Method Detail
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
dispose
public void dispose()
- Specified by:
dispose
in interfaceDisposable
-
isSearchServiceInstance
public boolean isSearchServiceInstance(String zoneItemId)
- Parameters:
zoneItemId
- the id of theZoneItem
- Returns:
true
if the given id of aZoneItem
is an instance of aSearchService
-
get
public SearchServiceInstance get(String zoneItemId)
Gets, or creates if it does not exist yet, theSearchServiceInstance
which is placed at the givenZoneItem
.
You must callisSearchServiceInstance
before to ensure that the given id is an instance ofSearchService
(this check is not done in this method)- Parameters:
zoneItemId
- the id of theZoneItem
- Returns:
- the
SearchServiceInstance
which is placed at the givenZoneItem
-
remove
public void remove(String zoneItemId)
Removes theSearchServiceInstance
which is placed at the givenZoneItem
.- Parameters:
zoneItemId
- the id of theZoneItem
-
-