Class AbstractResourceLocator

  • All Implemented Interfaces:
    ResourceLocator

    public abstract class AbstractResourceLocator
    extends Object
    implements ResourceLocator
    Provides easy access to package resources. Simply extend AbstractResourceLocator in the package where the resources are located. Your implementation can then be used to locate the resources by specifying a location relative to the implementation.
    • Constructor Detail

      • AbstractResourceLocator

        public AbstractResourceLocator()
        Creates a new abstract resource locator. Resources are resolved relative to the location of the concrete implementation.
      • AbstractResourceLocator

        public AbstractResourceLocator​(String basePath)
        Creates a new abstract resource locator with the specified sub-path prefix, in other words a sub-path from where all resources are resolved. Resources are resolved relative to the location of the concrete implementation.
        Parameters:
        basePath - the sub-path prefix