Class JarClasspathItem

java.lang.Object
de.simonkerstan.ee.core.classpath.JarClasspathItem
All Implemented Interfaces:
ClasspathItem, AutoCloseable

public class JarClasspathItem extends Object implements ClasspathItem
Classpath item for a jar file.

FOR INTERNAL USE ONLY. THE API CAN CHANGE AT ANY TIME.

  • Constructor Details

    • JarClasspathItem

      public JarClasspathItem(String jarFilePath) throws IOException
      Create a new JAR classpath item.
      Parameters:
      jarFilePath - The path to the jar file to be used
      Throws:
      IOException - If the jar file cannot be opened
  • Method Details

    • isResourceExisting

      public boolean isResourceExisting(String path)
      Description copied from interface: ClasspathItem
      Test whether a resource exists.
      Specified by:
      isResourceExisting in interface ClasspathItem
      Parameters:
      path - Path to the resource
      Returns:
      true if the resource exists, false otherwise
    • isDirectory

      public boolean isDirectory(String path)
      Description copied from interface: ClasspathItem
      Test whether a path points to a directory.
      Specified by:
      isDirectory in interface ClasspathItem
      Parameters:
      path - Path to the resource
      Returns:
      true if the path points to a directory, false otherwise
    • getChildren

      public List<String> getChildren(String path)
      Description copied from interface: ClasspathItem
      Get the children of a path.
      Specified by:
      getChildren in interface ClasspathItem
      Parameters:
      path - Path to the resource
      Returns:
      List of children
    • getResourceAsStream

      public InputStream getResourceAsStream(String path)
      Description copied from interface: ClasspathItem
      Get an input stream for a resource.
      Specified by:
      getResourceAsStream in interface ClasspathItem
      Parameters:
      path - Path to the resource
      Returns:
      Input stream for the resource
    • close

      public void close() throws Exception
      Specified by:
      close in interface AutoCloseable
      Throws:
      Exception