View Javadoc

1    /****************************************************************************
2    * Copyright (c) 2005, 2006, 2007, 2008, 2009 Imola Informatica.
3    * All rights reserved. This program and the accompanying materials
4    * are made available under the terms of the LGPL License v2.1
5    * which accompanies this distribution, and is available at
6    * http://www.gnu.org/licenses/lgpl.html
7    ****************************************************************************/
8   /*
9    * DefaultComponentLifeCycle.java
10   *
11   */
12  
13  package it.imolinfo.jbi4corba.jbi.component.runtime;
14  
15  import javax.jbi.JBIException;
16  import javax.management.ObjectName;
17  import javax.management.StandardMBean;
18  
19  /**
20   * Default ComponentLifeCycle implementation.
21   *
22   * @author <a href="mailto:mpiraccini@imolinfo.it">Marco Piraccini</a>
23   */
24  public class DefaultComponentLifeCycle extends AbstractComponentLifeCycle {
25      
26      public DefaultComponentLifeCycle(ComponentRuntime compRuntime) {
27          super(compRuntime);
28      }
29      
30      protected void activateServiceProviders() throws JBIException {
31          // NOOP
32      }
33      
34      protected void deactivateServiceProviders() throws JBIException {
35          // NOOP
36      }
37      
38      protected void activateServiceConsumers() throws JBIException {
39          // NOOP
40      }
41      
42      protected void deactivateServiceConsumers() throws JBIException {
43          // NOOP
44      }
45      
46      protected void initMessageExchangeHandlerFactory() throws JBIException {
47          RuntimeContext.getInstance().setMessageExchangeHandlerFactory(
48                  new MessageExchangeHandlerFactory.DefaultMessageExchangeHandlerFactory());
49      }
50      
51      protected MessageExchangeReceiver createMessageExchangeReceiver() throws Exception {
52          return new MessageExchangeReceiver();
53      }
54      
55      /**
56       * no extension mbean
57       */
58      protected ObjectName createExtensionMBeanName() {
59          return null;
60      }
61      
62      /**
63       * no extension mbean
64       */
65      protected StandardMBean createExtensionMBean() {
66          return null;
67      }
68      
69  }