Package org.daisy.dotify.common.java
Class ManifestRetriever
- java.lang.Object
-
- org.daisy.dotify.common.java.ManifestRetriever
-
public class ManifestRetriever extends Object
Retrieves a jar manifest, if available.
-
-
Constructor Summary
Constructors Constructor Description ManifestRetriever(Class<?> clazz)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanfailed()Returns true ifgetManifesthas been called and the manifest could not be read.ManifestgetManifest()Returns the jar manifest associated with this instance.
-
-
-
Constructor Detail
-
ManifestRetriever
public ManifestRetriever(Class<?> clazz)
- Parameters:
clazz- a class in the jar to get a manifest for
-
-
Method Detail
-
getManifest
public Manifest getManifest()
Returns the jar manifest associated with this instance.- Returns:
- returns a manifest. If the class is not in a jar, the manifest is empty
-
failed
public boolean failed()
Returns true ifgetManifesthas been called and the manifest could not be read.- Returns:
- true if
getManifestpreviously failed, false otherwise
-
-