Interface Resource

All Known Implementing Classes:
AliasedDirectoryResource, AliasedNamedResource, ByteArrayResource, ClassResource, DirectoryResource, JarResource, MultiReleaseResource, PrefixJarResource, ShrinkWrapResource, StringResource

public interface Resource
The Resource API.
Author:
Manfred Riem ([email protected])
  • Method Details

    • getResource

      URL getResource(String location)
      Get the resource.
      Parameters:
      location - the location.
      Returns:
      the URL.
    • getResourceAsStream

      InputStream getResourceAsStream(String location)
      Get the resource as a stream.
      Parameters:
      location - the location.
      Returns:
      the resource as a stream, or null if not found.
    • getAllLocations

      Stream<String> getAllLocations()
      Returns all the locations for this resource.
      Returns:
      all the locations for this resource
    • getName

      default String getName()
      Get the name of this resource
      Returns:
      the name