01: /**
02: *
03: * Copyright 2005-2006 The Apache Software Foundation
04: *
05: * Licensed under the Apache License, Version 2.0 (the "License");
06: * you may not use this file except in compliance with the License.
07: * You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */package org.mortbay.jetty.xbean;
17:
18: import java.util.Collection;
19:
20: import org.mortbay.jetty.Server;
21: import org.mortbay.jetty.deployer.ContextDeployer;
22:
23: /**
24: * Creates an instance of Jetty inside an <a href="http://xbean.org/">XBean</a>
25: * configuration file
26: *
27: * @org.apache.xbean.XBean element="jetty" rootElement="true" description="Creates an
28: * embedded Jetty web server with optional web application
29: * context"
30: *
31: * @version $Revision: 1294 $
32: */
33: public class JettyFactoryBean extends Server {
34:
35: public Collection deployers;
36: public ContextDeployer hotDeployer;
37:
38: /**
39: * @org.apache.xbean.InitMethod
40: * @throws Exception
41: */
42: public void run() throws Exception {
43: start();
44: }
45:
46: public Collection getDeployers() {
47: return deployers;
48: }
49:
50: public void setDeployers(Collection deployers) {
51: this .deployers = deployers;
52: }
53:
54: public ContextDeployer getHotDeployer() {
55: return hotDeployer;
56: }
57:
58: public void setHotDeployer(ContextDeployer hotDeployer) {
59: this.hotDeployer = hotDeployer;
60: addLifeCycle(hotDeployer);
61: }
62:
63: }
|