Contents | Package | Class | Tree | Deprecated | Index | Help | |||
PREV | NEXT | SHOW LISTS | HIDE LISTS |
java.lang.Object | +----javax.activation.CommandInfo
Constructor Summary | |
CommandInfo(java.lang.String verb,
java.lang.String className)
|
Method Summary | |
java.lang.String | getCommandClass()
|
java.lang.String | getCommandName()
|
java.lang.Object | getCommandObject(DataHandler dh,
java.lang.ClassLoader loader)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CommandInfo(java.lang.String verb, java.lang.String className)
verb
- The command verb this CommandInfo Decribes.
className
- The Bean's fully qualified class name.
Method Detail |
public java.lang.String getCommandName()
public java.lang.String getCommandClass()
public java.lang.Object getCommandObject(DataHandler dh, java.lang.ClassLoader loader) throws java.io.IOException, java.lang.ClassNotFoundException
Begin by instantiating the Bean with Beans.instantiate().
If this bean implements the javax.activation.CommandObject interface, call it's setCommandContext method.
If the DataHandler parameter is null, then the class is instantiated with no data. NOTE: this may be useful if for some reason the DataHandler that is passed in throws IOExceptions when this method attempts to access it's InputStream. It will allow the caller to retrieve a reference to the bean if it can be instantiated.
If the bean does NOT implement the CommandObject interface, this method will check if it implements the java.io.Externalizable interface. If it does, the bean's readExternal method will be called if an InputStream can be acquired from the DataHandler.
dh
- The DataHandler that describes the data to be
passed to the command.
loader
- The ClassLoader to be used to instansiate the
Bean.
Contents | Package | Class | Tree | Deprecated | Index | Help | |||
PREV | NEXT | SHOW LISTS | HIDE LISTS |