com.puppycrawl.tools.checkstyle

Class PackageObjectFactory

class PackageObjectFactory extends Object implements ModuleFactory

A factory for creating objects from package names and names.

Version: $Revision$

Author: Rick Giles lkuehne

Method Summary
ObjectcreateModule(String aName)
Creates a new instance of a class from a given name, or that name concatenated with "Check".

Method Detail

createModule

public Object createModule(String aName)
Creates a new instance of a class from a given name, or that name concatenated with "Check". If the name is a classname, creates an instance of the named class. Otherwise, creates an instance of a classname obtained by concatenating the given name to a package name from a given list of package names.

Parameters: aName the name of a class.

Returns: the Object created by aLoader.

Throws: CheckstyleException if an error occurs.