Interface PluginArtifact


public interface PluginArtifact
Allows the retrieval of files and/or an input stream of a plugin artifact. Implementations must allow multiple calls to getInputStream().
Since:
2.0.0
See Also:
  • Method Details

    • doesResourceExist

      boolean doesResourceExist(String name)
      Returns:
      true if the resource exists in this artifact, otherwise false
      Since:
      2.2.0
    • getResourceAsStream

      InputStream getResourceAsStream(String name)
      Returns:
      an input stream of the resource specified inside the artifact. Null if the resource cannot be found.
      Throws:
      PluginParseException - if the there was an exception retrieving the resource from the artifact
    • getName

      String getName()
      Returns:
      the original name of the plugin artifact file. Typically used for persisting it to disk with a meaningful name.
    • getInputStream

      InputStream getInputStream()
      Returns:
      an InputStream for the entire plugin artifact. Calling this multiple times will return a fresh input stream each time.
    • toFile

      File toFile()
      Returns:
      the artifact as a file, or its underlying file if it is already one
      Since:
      2.2.0
    • containsJavaExecutableCode

      boolean containsJavaExecutableCode()
      Returns:
      true if the plugin contains or references java executable code.
      Since:
      3.0
    • containsSpringContext

      boolean containsSpringContext()
      Returns:
      true if the plugin contains Spring context files or instructions
      Since:
      4.1
    • getReferenceMode

      ReferenceMode getReferenceMode()
      Returns:
      the ReferenceMode specifying whether or not this PluginArtifact may be reference installed.
      Since:
      4.0.0