01: /*
02: * Copyright (C) The MX4J Contributors.
03: * All rights reserved.
04: *
05: * This software is distributed under the terms of the MX4J License version 1.0.
06: * See the terms of the MX4J License in the documentation provided with this software.
07: */
08: package mx4j.tools.adaptor.http;
09:
10: import java.io.IOException;
11: import javax.management.JMException;
12:
13: import org.w3c.dom.Document;
14: import org.w3c.dom.Element;
15:
16: /**
17: * EmptyCommandProcessor, returns an empty xml tree
18: *
19: * @version $Revision: 1.3 $
20: */
21: public class EmptyCommandProcessor extends HttpCommandProcessorAdaptor {
22:
23: /**
24: * Constructs a new EmptyCommandProcessor
25: */
26: public EmptyCommandProcessor() {
27: }
28:
29: public Document executeRequest(HttpInputStream in)
30: throws IOException, JMException {
31: Document document = builder.newDocument();
32:
33: Element root = document.createElement("empty");
34: document.appendChild(root);
35:
36: return document;
37: }
38:
39: }
|