Subversion Repositories XServices

Rev

Rev 58 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 58 Rev 65
1
package net.brutex.xservices.ws;
1
package net.brutex.xservices.ws;
2
 
2
 
3
import javax.jws.WebMethod;
3
import javax.jws.WebMethod;
4
import javax.jws.WebParam;
4
import javax.jws.WebParam;
5
import javax.jws.WebService;
5
import javax.jws.WebService;
6
 
6
 
7
import net.brutex.xservices.types.HostConnection;
7
import net.brutex.xservices.types.HostConnection;
8
import net.brutex.xservices.types.ReturnCode;
8
import net.brutex.xservices.types.ReturnCode;
9
import net.brutex.xservices.util.BrutexNamespaces;
9
import net.brutex.xservices.util.BrutexNamespaces;
-
 
10
 
-
 
11
/**
-
 
12
 * @author brosenberger
-
 
13
 *
10
 
14
 */
11
@WebService(targetNamespace = BrutexNamespaces.WS_XSERVICES)
15
@WebService(targetNamespace = BrutexNamespaces.WS_XSERVICES)
12
public interface ExecuteService {
16
public interface ExecuteService {
-
 
17
 
-
 
18
	/**
-
 
19
	 * @param cmd
-
 
20
	 * @param args
-
 
21
	 * @param timeout
-
 
22
	 * @return
13
 
23
	 */
14
	@WebMethod(operationName = "runCommand")
24
	@WebMethod(operationName = "runCommand")
15
	public abstract ReturnCode runCommand(
25
	public abstract ReturnCode runCommand(
16
			@WebParam(name = "executable") String cmd,
26
			@WebParam(name = "executable") String cmd,
17
			@WebParam(name = "argline") String args,
27
			@WebParam(name = "argline") String args,
18
			@WebParam(name = "timeout") long timeout);
28
			@WebParam(name = "timeout") long timeout);
-
 
29
 
-
 
30
	/**
-
 
31
	 * @param cmd
-
 
32
	 * @param args
-
 
33
	 * @param timeout
-
 
34
	 * @return
19
 
35
	 */
20
	@WebMethod(operationName = "runCommandWithArgs")
36
	@WebMethod(operationName = "runCommandWithArgs")
21
	public abstract ReturnCode runCommandWithArgs(
37
	public abstract ReturnCode runCommandWithArgs(
22
			@WebParam(name = "executable") String cmd,
38
			@WebParam(name = "executable") String cmd,
23
			@WebParam(name = "arg") String[] args,
39
			@WebParam(name = "arg") String[] args,
24
			@WebParam(name = "timeout") long timeout);
40
			@WebParam(name = "timeout") long timeout);
-
 
41
 
-
 
42
	/**
-
 
43
	 * @param cmd
-
 
44
	 * @param args
-
 
45
	 * @return
25
 
46
	 */
26
	@WebMethod(operationName = "runCommandAsync")
47
	@WebMethod(operationName = "runCommandAsync")
27
	public abstract ReturnCode runCommandAsync(
48
	public abstract ReturnCode runCommandAsync(
28
			@WebParam(name = "executable") String cmd,
49
			@WebParam(name = "executable") String cmd,
29
			@WebParam(name = "argline") String args);
50
			@WebParam(name = "argline") String args);
-
 
51
 
-
 
52
	/**
-
 
53
	 * @param cmd
-
 
54
	 * @param args
-
 
55
	 * @return
30
 
56
	 */
31
	@WebMethod(operationName = "runCommandAsyncWithArgs")
57
	@WebMethod(operationName = "runCommandAsyncWithArgs")
32
	public abstract ReturnCode runCommandAsyncWithArgs(
58
	public abstract ReturnCode runCommandAsyncWithArgs(
33
			@WebParam(name = "executable") String cmd,
59
			@WebParam(name = "executable") String cmd,
34
			@WebParam(name = "arg") String[] args);
60
			@WebParam(name = "arg") String[] args);
-
 
61
 
-
 
62
	/**
-
 
63
	 * @param host
-
 
64
	 * @param cmd
-
 
65
	 * @param timeout
-
 
66
	 * @return
35
 
67
	 */
36
	@WebMethod(operationName = "runCommandWithSSH")
68
	@WebMethod(operationName = "runCommandWithSSH")
37
	public abstract ReturnCode runCommandWithSSH(
69
	public abstract ReturnCode runCommandWithSSH(
38
			@WebParam(name = "host") HostConnection host,
70
			@WebParam(name = "host") HostConnection host,
39
			@WebParam(name = "command") String cmd,
71
			@WebParam(name = "command") String cmd,
40
			@WebParam(name = "timeout") long timeout);
72
			@WebParam(name = "timeout") long timeout);
-
 
73
 
-
 
74
	/**
-
 
75
	 * @param host
-
 
76
	 * @param keyfile
-
 
77
	 * @param cmd
-
 
78
	 * @param timeout
-
 
79
	 * @return
41
 
80
	 */
42
	@WebMethod(operationName = "runCommandWithSSHKeyAuth")
81
	@WebMethod(operationName = "runCommandWithSSHKeyAuth")
43
	public abstract ReturnCode runCommandWithSSHKeyAuth(
82
	public abstract ReturnCode runCommandWithSSHKeyAuth(
44
			@WebParam(name = "host") HostConnection host,
83
			@WebParam(name = "host") HostConnection host,
45
			@WebParam(name = "keyfile") String keyfile,
84
			@WebParam(name = "keyfile") String keyfile,
46
			@WebParam(name = "command") String cmd,
85
			@WebParam(name = "command") String cmd,
47
			@WebParam(name = "timeout") long timeout);
86
			@WebParam(name = "timeout") long timeout);
-
 
87
 
-
 
88
	/**
-
 
89
	 * @param host
-
 
90
	 * @param cmd
-
 
91
	 * @param timeout
-
 
92
	 * @return
48
 
93
	 */
49
	@WebMethod(operationName = "rExec")
94
	@WebMethod(operationName = "rExec")
50
	public abstract ReturnCode rExec(
95
	public abstract ReturnCode rExec(
51
			@WebParam(name = "host") HostConnection host,
96
			@WebParam(name = "host") HostConnection host,
52
			@WebParam(name = "command") String cmd,
97
			@WebParam(name = "command") String cmd,
53
			@WebParam(name = "timeout") long timeout);
98
			@WebParam(name = "timeout") long timeout);
-
 
99
 
-
 
100
	/**
-
 
101
	 * @param host
-
 
102
	 * @param prompt
-
 
103
	 * @param cmd
-
 
104
	 * @param expect
-
 
105
	 * @param timeout
-
 
106
	 * @return
54
 
107
	 */
55
	@WebMethod(operationName = "telnet")
108
	@WebMethod(operationName = "telnet")
56
	public abstract ReturnCode runTelnet(
109
	public abstract ReturnCode runTelnet(
57
			@WebParam(name = "host") HostConnection host,
110
			@WebParam(name = "host") HostConnection host,
58
			@WebParam(name = "prompt") String prompt,
111
			@WebParam(name = "prompt") String prompt,
59
			@WebParam(name = "command") String cmd,
112
			@WebParam(name = "command") String cmd,
60
			@WebParam(name = "expect") String expect,
113
			@WebParam(name = "expect") String expect,
61
			@WebParam(name = "timeout") long timeout);
114
			@WebParam(name = "timeout") long timeout);
62
 
115
 
63
}
116
}
64
 
117
 
65
Generated by GNU Enscript 1.6.5.90.
118
Generated by GNU Enscript 1.6.5.90.
66
 
119
 
67
 
120