org.jomc.cli.commands
Class AbstractModletCommand.CommandLineClassLoader

Package class diagram package AbstractModletCommand.CommandLineClassLoader
java.lang.Object
  extended by java.lang.ClassLoader
      extended by java.security.SecureClassLoader
          extended by java.net.URLClassLoader
              extended by org.jomc.cli.commands.AbstractModletCommand.CommandLineClassLoader
Enclosing class:
AbstractModletCommand

public class AbstractModletCommand.CommandLineClassLoader
extends URLClassLoader

Class loader backed by a command line.

Version:
$JOMC: AbstractModletCommand.java 4463 2012-03-28 00:46:22Z schulte2005 $
Author:
Christian Schulte

Constructor Summary
AbstractModletCommand.CommandLineClassLoader(CommandLine commandLine)
          Creates a new CommandLineClassLoader taking a command line backing the class loader.
 
Method Summary
 void close()
          Closes the class loader.
protected  void finalize()
          Removes temporary resources.
 URL findResource(String name)
          Finds the resource with the specified name on the URL search path.
 Enumeration<URL> findResources(String name)
          Returns an Enumeration of URLs representing all of the resources on the URL search path having the specified name.
 Modlets getExcludedModlets()
          Gets the Modlets excluded by the instance.
 
Methods inherited from class java.net.URLClassLoader
addURL, definePackage, findClass, getPermissions, getURLs, newInstance, newInstance
 
Methods inherited from class java.security.SecureClassLoader
defineClass, defineClass
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractModletCommand.CommandLineClassLoader

public AbstractModletCommand.CommandLineClassLoader(CommandLine commandLine)
                                             throws CommandExecutionException
Creates a new CommandLineClassLoader taking a command line backing the class loader.

Parameters:
commandLine - The command line backing the class loader.
Throws:
NullPointerException - if commandLine is null.
CommandExecutionException - if processing commandLine fails.
Method Detail

getExcludedModlets

public Modlets getExcludedModlets()
Gets the Modlets excluded by the instance.

Returns:
The Modlets excluded by the instance.

findResource

public URL findResource(String name)
Finds the resource with the specified name on the URL search path.

Overrides:
findResource in class URLClassLoader
Parameters:
name - The name of the resource.
Returns:
A URL for the resource or null, if the resource could not be found.

findResources

public Enumeration<URL> findResources(String name)
                               throws IOException
Returns an Enumeration of URLs representing all of the resources on the URL search path having the specified name.

Overrides:
findResources in class URLClassLoader
Parameters:
name - The resource name.
Returns:
An Enumeration of URLs.
Throws:
IOException - if an I/O exception occurs

close

public void close()
           throws IOException
Closes the class loader.

Throws:
IOException - if closing the class loader fails.

finalize

protected void finalize()
                 throws Throwable
Removes temporary resources.

Overrides:
finalize in class Object
Throws:
Throwable - if finalization fails.


Copyright © 2005-2012 The JOMC Project. All Rights Reserved.Get JOMC at SourceForge.net. Fast, secure and Free Open Source software downloads
Please note that this documentation is maintained by non-native english speaking authors. As such, you may encounter phrases or wordings which seem imprecise or may even have a totally different meaning to native english speaking readers than what the individual author was trying to express. If you are a native english speaking reader and find any such phrases or wordings we kindly ask you to send an email to the corresponding author and help us improve this documentation in order to avoid misunderstandings. You will find the authors' email addresses at the top of each class. Please accept our apologies for any inconvenience caused.