| java.lang.Object com.martiansoftware.nailgun.Alias
Alias | public class Alias implements Comparable(Code) | | Provides a means to map memorable, short names to classes in order
to make the issuing of commands more convenient. For example, an
Alias can map the "mycommand " command to the com.yourdomain.yourpackage.YourClass
class. Obviously, it's a lot easier to type "ng mycommand " than the fully
qualified class name.
author: Marty Lamb |
Constructor Summary | |
public | Alias(String name, String description, Class clazz) Creates a new Alias with the specified properties. |
Alias | public Alias(String name, String description, Class clazz)(Code) | | Creates a new Alias with the specified properties.
Parameters: name - the alias name (short command) Parameters: description - a description of the command Parameters: clazz - the class implementing the command |
equals | public boolean equals(Object o)(Code) | | Checks whether two Aliases have the same name. Does not
compare any other fields.
Parameters: o - the other Alias to check true if the specified Alias has the same name as this Alias. |
getAliasedClass | public Class getAliasedClass()(Code) | | Returns the Class object providing a static main() or nailMain() method
for this command.
the Class object providing a static main() or nailMain() methodfor this command. |
getDescription | public String getDescription()(Code) | | Returns a description for the aliased command
a description for the aliased command |
getName | public String getName()(Code) | | Returns the name of the aliased command
the name of the aliased command |
|
|