Class EntityRedirectsManager


  • public class EntityRedirectsManager
    extends Object
    Handles everything related the URL redirects handling and processing
    Author:
    Aaron Zeckoski (azeckoski @ gmail.com)
    • Constructor Detail

      • EntityRedirectsManager

        protected EntityRedirectsManager()
        Empty constructor
      • EntityRedirectsManager

        public EntityRedirectsManager​(EntityBrokerManager entityBrokerManager,
                                      EntityProviderMethodStore entityProviderMethodStore,
                                      RequestStorageWrite requestStorage)
        Base constructor
        Parameters:
        entityProviderMethodStore - the provider method store service
        requestStorage - the request storage service
    • Method Detail

      • setEntityBrokerManager

        public void setEntityBrokerManager​(EntityBrokerManager entityBrokerManager)
      • setEntityProviderMethodStore

        public void setEntityProviderMethodStore​(EntityProviderMethodStore entityProviderMethodStore)
      • checkForTemplateMatch

        public String checkForTemplateMatch​(EntityProvider entityProvider,
                                            String incomingURL,
                                            String queryString)
        Do a check to see if the current incoming URL is a match to any of the redirect templates for the given entity provider
        Parameters:
        entityProvider - an entity provider
        queryString - the query string (e.g. auto=true) for the incoming URL
        incomingUrl - the incoming URL to try to match
        Returns:
        the URL to redirect to (will start with /direct if it should be forwarded) OR null if no matches were found