Package net.shibboleth.shared.testing
Class ShowAutomaticModuleNames
java.lang.Object
net.shibboleth.shared.testing.ShowAutomaticModuleNames
Command-line utility to show the automatic module names from a
.jar file or a directory of them.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static classThrow one of these to cause the main program to terminate. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate StringgetAutomaticModuleName(JarFile jarFile) Fetch the automatic module name (if any) from a.jarfile.static voidMain program.private voidRunnable main program, wrapped bymainin an exception handler.private voidrunDirectory(File directory) Process all of the.jarfiles in a given directory, and present the results in a readable way.
-
Field Details
-
AUTO_MODULE_NAME
#AUTO_MODULE_NAME.- See Also:
-
-
Constructor Details
-
ShowAutomaticModuleNames
public ShowAutomaticModuleNames()
-
-
Method Details
-
getAutomaticModuleName
@Nullable private String getAutomaticModuleName(@Nonnull JarFile jarFile) throws ShowAutomaticModuleNames.TerminationException Fetch the automatic module name (if any) from a.jarfile.- Parameters:
jarFile-.jarfile to process- Returns:
- the automatic module name, or
null - Throws:
ShowAutomaticModuleNames.TerminationException- if something goes wrong
-
runDirectory
private void runDirectory(@Nonnull File directory) throws ShowAutomaticModuleNames.TerminationException Process all of the.jarfiles in a given directory, and present the results in a readable way.- Parameters:
directory- directory to process- Throws:
ShowAutomaticModuleNames.TerminationException- if something goes wrong
-
run
Runnable main program, wrapped bymainin an exception handler.- Parameters:
args- command-line arguments- Throws:
ShowAutomaticModuleNames.TerminationException- if something bad happens
-
main
Main program.- Parameters:
args- command-line arguments
-