Interface Resource

  • All Superinterfaces:
    java.lang.AutoCloseable

    @DoNotStore
    public interface Resource
    extends java.lang.AutoCloseable
    A resource can represent any kind of loaded data. It can be a file on the filesystem, a network location, or even generated at runtime. Use inputStream() to retrieve the data.
    • Method Detail

      • inputStream

        java.io.InputStream inputStream()
        Returns the InputStream of this resource. Multiple calls to this method will not return a new object. To get a new object, get a new resource.
        Returns:
        The input stream
      • close

        void close()
            throws java.io.IOException
        Specified by:
        close in interface java.lang.AutoCloseable
        Throws:
        java.io.IOException