Interface URLHandlerService
- All Known Implementing Classes:
URLHandlerServiceImpl
public interface URLHandlerService
Created by bpolster.
-
Method Summary
Modifier and TypeMethodDescriptionbuildURLHandlerCacheKey
(Site site, String requestUri) This is assumed to be a relatively small list of regex URLHandlers (perhaps in the dozens or hundreds of records at a maximum).Be cautious when calling this.Finds a URLHandler by its ID.Checks the passed in URL to determine if there is a matching URLHandler.removeURLHandlerFromCache
(String mapKey) saveURLHandler
(URLHandler handler) Persists the URLHandler to the DB.
-
Method Details
-
findURLHandlerByURI
Checks the passed in URL to determine if there is a matching URLHandler. Returns null if no handler was found.- Parameters:
uri
-- Returns:
-
findAllURLHandlers
List<URLHandler> findAllURLHandlers()Be cautious when calling this. If there are a large number of records, this can cause performance and memory issues.- Returns:
-
saveURLHandler
Persists the URLHandler to the DB.- Parameters:
handler
-- Returns:
-
findURLHandlerById
Finds a URLHandler by its ID.- Parameters:
id
-- Returns:
-
findAllRegexURLHandlers
List<URLHandler> findAllRegexURLHandlers()This is assumed to be a relatively small list of regex URLHandlers (perhaps in the dozens or hundreds of records at a maximum). Having large number of records here (more 1000, for example) is not likely necessary to accomplish the desired goal, and can cause performance problems.- Returns:
-
buildURLHandlerCacheKey
-
removeURLHandlerFromCache
-