Class BaseLocaleUrlDefinitionDAO

    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected org.apache.tiles.request.ApplicationContext applicationContext
      ApplicationContext to locate the source files.
      protected java.util.Map<java.lang.String,​java.lang.Long> lastModifiedDates
      Contains the dates that the URL sources were last modified.
      protected DefinitionsReader reader
      Reader used to get definitions from the sources.
      protected java.util.List<org.apache.tiles.request.ApplicationResource> sources
      Contains the URL objects identifying where configuration data is found.
    • Constructor Summary

      Constructors 
      Constructor Description
      BaseLocaleUrlDefinitionDAO​(org.apache.tiles.request.ApplicationContext applicationContext)
      Constructor.
    • Field Detail

      • sources

        protected java.util.List<org.apache.tiles.request.ApplicationResource> sources
        Contains the URL objects identifying where configuration data is found.
        Since:
        2.1.0
      • lastModifiedDates

        protected java.util.Map<java.lang.String,​java.lang.Long> lastModifiedDates
        Contains the dates that the URL sources were last modified.
        Since:
        2.1.0
      • reader

        protected DefinitionsReader reader
        Reader used to get definitions from the sources.
        Since:
        2.1.0
      • applicationContext

        protected org.apache.tiles.request.ApplicationContext applicationContext
        ApplicationContext to locate the source files.
        Since:
        3.0.0
    • Constructor Detail

      • BaseLocaleUrlDefinitionDAO

        public BaseLocaleUrlDefinitionDAO​(org.apache.tiles.request.ApplicationContext applicationContext)
        Constructor.
    • Method Detail

      • setSources

        public void setSources​(java.util.List<org.apache.tiles.request.ApplicationResource> sources)
      • refreshRequired

        public boolean refreshRequired()
        Indicates whether the sources are out of date and need to be reloaded.
        Specified by:
        refreshRequired in interface RefreshMonitor
        Returns:
        true if the sources need to be refreshed.
      • loadDefinitionsFromResource

        protected java.util.Map<java.lang.String,​Definition> loadDefinitionsFromResource​(org.apache.tiles.request.ApplicationResource resource)
        Loads definitions from an URL without loading from "parent" URLs.
        Parameters:
        resource - The URL to read.
        Returns:
        The definition map that has been read.