Package com.sun.enterprise.admin.remote
Class RemoteResponseManager
- java.lang.Object
-
- com.sun.enterprise.admin.remote.RemoteResponseManager
-
- All Implemented Interfaces:
ResponseManager
public class RemoteResponseManager extends Object implements ResponseManager
This class is responsible for handling the Remote Server response. Note that an unusul paradigm is used here. Success is signaled by throwing a "success" exception. This breaks the overarching rule about Exceptions but is very useful in CLI. CLI has the pattern of: Error: Throw an Exception Success: Don't throw an Exception The logic becomes difficult. The command itself has to know how to print a success message properly instead of just putting such a message inside an Exception object and throwing it. In such a system it is cleaner to do this: Error: throw failure exception Success: throw success exception- Author:
- bnevins
-
-
Constructor Summary
Constructors Constructor Description RemoteResponseManager(InputStream in, int code, Logger logger)
-
-
-
Constructor Detail
-
RemoteResponseManager
public RemoteResponseManager(InputStream in, int code, Logger logger) throws RemoteException, IOException
- Throws:
RemoteException
IOException
-
-
Method Detail
-
process
public void process() throws RemoteException
- Specified by:
process
in interfaceResponseManager
- Throws:
RemoteException
-
-