KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > mx4j > tools > adaptor > http > HttpCommandProcessorAdaptor


1 /*
2  * Copyright (C) The MX4J Contributors.
3  * All rights reserved.
4  *
5  * This software is distributed under the terms of the MX4J License version 1.0.
6  * See the terms of the MX4J License in the documentation provided with this software.
7  */

8 package mx4j.tools.adaptor.http;
9
10
11 import java.io.IOException JavaDoc;
12 import javax.management.JMException JavaDoc;
13 import javax.management.MBeanServer JavaDoc;
14 import javax.xml.parsers.DocumentBuilder JavaDoc;
15
16 import org.w3c.dom.Document JavaDoc;
17
18 /**
19  * HttpCommandProcessor sets the structure of a command processor
20  *
21  * @version $Revision: 1.3 $
22  */

23 public abstract class HttpCommandProcessorAdaptor implements HttpCommandProcessor
24 {
25    protected MBeanServer JavaDoc server;
26
27    protected DocumentBuilder JavaDoc builder;
28
29    public abstract Document JavaDoc executeRequest(HttpInputStream in) throws IOException JavaDoc, JMException JavaDoc;
30
31    /**
32     * Sets the target MBeanServer
33     */

34    public void setMBeanServer(MBeanServer JavaDoc server)
35    {
36       this.server = server;
37    }
38
39    /**
40     * Sets the Document Builder factory
41     */

42    public void setDocumentBuilder(DocumentBuilder JavaDoc builder)
43    {
44       this.builder = builder;
45    }
46 }
47
Popular Tags