dsnserver
Class XmlRpcTargetCommand

java.lang.Object
  extended by dsnserver.XmlRpcTargetCommand
All Implemented Interfaces:
org.apache.xmlrpc.AuthenticatedXmlRpcHandler

public class XmlRpcTargetCommand
extends java.lang.Object
implements org.apache.xmlrpc.AuthenticatedXmlRpcHandler

A function which is used as a XmlRpc function. It is used for sending out a target command.

Author:
kaltt

Field Summary
(package private)  Communication myComm
           
(package private)  org.apache.xmlrpc.WebServer server
           
 
Constructor Summary
XmlRpcTargetCommand(Communication comm, org.apache.xmlrpc.WebServer server)
           
 
Method Summary
 boolean checkPassword(java.lang.String user, java.lang.String password)
           
protected  java.lang.Object execute(java.lang.String method, java.util.Vector v)
           
 java.lang.Object execute(java.lang.String method, java.util.Vector v, java.lang.String user, java.lang.String password)
           
 java.lang.String targetCommand(java.lang.String DSNID, java.lang.String command)
          A function which is used as a XmlRpc function.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myComm

Communication myComm

server

org.apache.xmlrpc.WebServer server
Constructor Detail

XmlRpcTargetCommand

public XmlRpcTargetCommand(Communication comm,
                           org.apache.xmlrpc.WebServer server)
Method Detail

targetCommand

public java.lang.String targetCommand(java.lang.String DSNID,
                                      java.lang.String command)
                               throws java.lang.Exception
A function which is used as a XmlRpc function. It is used for sending out a target command. The command string have to be shorter than 90 bytes.

Parameters:
String - DSNID
String command (the command that will be sent to the Target, must be shorter than 110 bytes)
Returns:
return "OK!" or "too long!"
Throws:
java.lang.Exception

execute

public java.lang.Object execute(java.lang.String method,
                                java.util.Vector v,
                                java.lang.String user,
                                java.lang.String password)
Specified by:
execute in interface org.apache.xmlrpc.AuthenticatedXmlRpcHandler

execute

protected java.lang.Object execute(java.lang.String method,
                                   java.util.Vector v)

checkPassword

public boolean checkPassword(java.lang.String user,
                             java.lang.String password)