Subversion Repositories XServices

Compare Revisions

Ignore whitespace Rev 20 → Rev 21

/xservices/trunk/src/java/net/brutex/xservices/ws/MiscService.java
13,12 → 13,12
* See the License for the specific language governing permissions and
* limitations under the License.
*/
 
package net.brutex.xservices.ws;
 
import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebService;
import net.brutex.xservices.types.FileSetResource;
import net.brutex.xservices.types.HostConnection;
import net.brutex.xservices.types.ReturnCode;
import net.brutex.xservices.util.BrutexNamespaces;
27,20 → 27,28
*
* @author Brian Rosenberger, bru@brutex.de
*/
@WebService(targetNamespace=BrutexNamespaces.WS_XSERVICES)
@WebService(targetNamespace = BrutexNamespaces.WS_XSERVICES)
public interface MiscService {
 
@WebMethod(operationName="getHostinfo")
public ReturnCode getHostinfo(@WebParam(name="hostname") String hostname);
@WebMethod(operationName = "getHostinfo")
public ReturnCode getHostinfo(@WebParam(name = "hostname") String hostname);
 
@WebMethod(operationName="sendMailSimple")
public ReturnCode sendMailSimple(@WebParam(name="mailhost") HostConnection mailhost,
@WebParam(name="from") String from,
@WebParam(name="to") String tolist,
@WebParam(name="subject") String subject,
@WebParam(name="message") String message);
@WebMethod(operationName = "sendMailSimple")
public ReturnCode sendMailSimple(@WebParam(name = "mailhost") HostConnection mailhost,
@WebParam(name = "from") String from,
@WebParam(name = "to") String tolist,
@WebParam(name = "subject") String subject,
@WebParam(name = "message") String message);
 
@WebMethod(operationName="sleep")
public ReturnCode sleep(@WebParam(name="minutes") int minutes,
@WebParam(name="seconds") int seconds);
@WebMethod(operationName = "sendMailSimpleWithAttachment")
public ReturnCode sendMailSimpleWithAttachment(@WebParam(name = "mailhost") HostConnection mailhost,
@WebParam(name = "from") String from,
@WebParam(name = "to") String tolist,
@WebParam(name = "subject") String subject,
@WebParam(name = "message") String message,
@WebParam(name = "attachments") FileSetResource res);
 
@WebMethod(operationName = "sleep")
public ReturnCode sleep(@WebParam(name = "minutes") int minutes,
@WebParam(name = "seconds") int seconds);
}
/xservices/trunk/src/java/net/brutex/xservices/ws/MiscServiceImpl.java
56,6 → 56,29
false);
}
 
public ReturnCode sendMailSimpleWithAttachment(HostConnection mailhost, String from,
String tolist, String subject, String message,
FileSetResource res) {
return sendMail(from,
from,
tolist,
"",
"",
subject,
message,
"text/plain",
res,
mailhost.hostname,
mailhost.port,
mailhost.user,
mailhost.password,
"utf-8",
false,
false);
}
 
 
 
public ReturnCode sleep(int minutes, int seconds) {
return sleep(0, minutes, seconds, 0);
}