Interface JarHandler
- All Known Implementing Classes:
AbstractJarHandler, DefaultJarHandler, MavenJarHandler, NetBeansJarHandler, SeleniumJarHandler
public interface JarHandler
Defines the contract for extracting metadata from JAR files during
classpath inspection.
Implementations of this interface are used by the
VeryPrettyClassPathPrinter
to identify library versions and vendors, enabling token-efficient
representation of the environment.
- Author:
- anahata
-
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if this handler is capable of extracting metadata from the given JAR file.extractMetadata(File jarFile) Extracts semantic metadata (ID, version, vendor) from the JAR file.
-
Method Details
-
canHandle
Checks if this handler is capable of extracting metadata from the given JAR file.- Parameters:
jarFile- The file to check.- Returns:
- true if this handler should be used.
-
extractMetadata
Extracts semantic metadata (ID, version, vendor) from the JAR file.- Parameters:
jarFile- The file to inspect.- Returns:
- The extracted metadata, or null if extraction failed.
-

