src/core/net/sf/basedb/util/jobagent/RequestHandler.java

Code
Comments
Other
Rev Date Author Line
2632 08 Sep 06 nicklas 1 /**
2632 08 Sep 06 nicklas 2   $Id$
2632 08 Sep 06 nicklas 3
3675 16 Aug 07 jari 4   Copyright (C) 2006 Nicklas Nordborg
2632 08 Sep 06 nicklas 5
2632 08 Sep 06 nicklas 6   This file is part of BASE - BioArray Software Environment.
2632 08 Sep 06 nicklas 7   Available at http://base.thep.lu.se/
2632 08 Sep 06 nicklas 8
2632 08 Sep 06 nicklas 9   BASE is free software; you can redistribute it and/or
2632 08 Sep 06 nicklas 10   modify it under the terms of the GNU General Public License
4479 05 Sep 08 jari 11   as published by the Free Software Foundation; either version 3
2632 08 Sep 06 nicklas 12   of the License, or (at your option) any later version.
2632 08 Sep 06 nicklas 13
2632 08 Sep 06 nicklas 14   BASE is distributed in the hope that it will be useful,
2632 08 Sep 06 nicklas 15   but WITHOUT ANY WARRANTY; without even the implied warranty of
2632 08 Sep 06 nicklas 16   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
2632 08 Sep 06 nicklas 17   GNU General Public License for more details.
2632 08 Sep 06 nicklas 18
2632 08 Sep 06 nicklas 19   You should have received a copy of the GNU General Public License
4515 11 Sep 08 jari 20   along with BASE. If not, see <http://www.gnu.org/licenses/>.
2632 08 Sep 06 nicklas 21 */
2632 08 Sep 06 nicklas 22 package net.sf.basedb.util.jobagent;
2632 08 Sep 06 nicklas 23
2634 12 Sep 06 nicklas 24 import java.net.Socket;
2634 12 Sep 06 nicklas 25
6444 09 Apr 14 nicklas 26 import org.slf4j.Logger;
2981 30 Nov 06 nicklas 27
2981 30 Nov 06 nicklas 28
2632 08 Sep 06 nicklas 29 /**
2634 12 Sep 06 nicklas 30   A request handler object takes care of an incoming request from a
2634 12 Sep 06 nicklas 31   {@link JobAgentServerConnection}, processes it and returns an answer.
2634 12 Sep 06 nicklas 32   
2632 08 Sep 06 nicklas 33
2634 12 Sep 06 nicklas 34   @author nicklas
2634 12 Sep 06 nicklas 35   @version 2.0
2981 30 Nov 06 nicklas 36   @see JobAgentServerConnection#JobAgentServerConnection(int, RequestHandler, Logger)
2634 12 Sep 06 nicklas 37   @base.modified $Date$
2634 12 Sep 06 nicklas 38 */
2632 08 Sep 06 nicklas 39 public interface RequestHandler
2632 08 Sep 06 nicklas 40 {
2632 08 Sep 06 nicklas 41
2634 12 Sep 06 nicklas 42   /**
2634 12 Sep 06 nicklas 43     Handle a command that was sent by an incoming request.
2634 12 Sep 06 nicklas 44     @param socket The socket that is handling the communication with the 
2634 12 Sep 06 nicklas 45       remote client
2634 12 Sep 06 nicklas 46     @param cmd The command
2634 12 Sep 06 nicklas 47     @return The answer
2634 12 Sep 06 nicklas 48   */
2634 12 Sep 06 nicklas 49   public String handleCmd(Socket socket, String cmd);
2632 08 Sep 06 nicklas 50   
2632 08 Sep 06 nicklas 51 }