Coverage Report - org.mule.management.mbeans.ModelService
 
Classes in this File Line Coverage Branch Coverage Complexity
ModelService
24%
5/21
N/A
1
 
 1  
 /*
 2  
  * $Id: ModelService.java 7963 2007-08-21 08:53:15Z dirk.olmes $
 3  
  * --------------------------------------------------------------------------------------
 4  
  * Copyright (c) MuleSource, Inc.  All rights reserved.  http://www.mulesource.com
 5  
  *
 6  
  * The software in this package is published under the terms of the CPAL v1.0
 7  
  * license, a copy of which has been included with this distribution in the
 8  
  * LICENSE.txt file.
 9  
  */
 10  
 
 11  
 package org.mule.management.mbeans;
 12  
 
 13  
 import org.mule.umo.UMODescriptor;
 14  
 import org.mule.umo.UMOException;
 15  
 import org.mule.umo.model.UMOModel;
 16  
 
 17  
 /**
 18  
  * <code>ModelService</code> exposes service information and actions on the Mule
 19  
  * Model.
 20  
  */
 21  
 public class ModelService implements ModelServiceMBean
 22  
 {
 23  
     private UMOModel model;
 24  
 
 25  
     public ModelService(UMOModel model)
 26  36
     {
 27  36
         this.model = model;
 28  
 
 29  36
     }
 30  
 
 31  
     public void start() throws UMOException
 32  
     {
 33  0
         model.start();
 34  0
     }
 35  
 
 36  
     public void stop() throws UMOException
 37  
     {
 38  0
         model.stop();
 39  0
     }
 40  
 
 41  
     public void startComponent(String name) throws UMOException
 42  
     {
 43  0
         model.startComponent(name);
 44  0
     }
 45  
 
 46  
     public void stopComponent(String name) throws UMOException
 47  
     {
 48  0
         model.stopComponent(name);
 49  0
     }
 50  
 
 51  
     public void pauseComponent(String name) throws UMOException
 52  
     {
 53  0
         model.pauseComponent(name);
 54  0
     }
 55  
 
 56  
     public void resumeComponent(String name) throws UMOException
 57  
     {
 58  0
         model.resumeComponent(name);
 59  0
     }
 60  
 
 61  
     public void unregisterComponent(String name) throws UMOException
 62  
     {
 63  0
         model.unregisterComponent(model.getDescriptor(name));
 64  0
     }
 65  
 
 66  
     public boolean isComponentRegistered(String name)
 67  
     {
 68  0
         return model.isComponentRegistered(name);
 69  
     }
 70  
 
 71  
     public UMODescriptor getComponentDescriptor(String name)
 72  
     {
 73  0
         return model.getDescriptor(name);
 74  
     }
 75  
 
 76  
     public String getName()
 77  
     {
 78  36
         return model.getName();
 79  
     }
 80  
 
 81  
     public String getType()
 82  
     {
 83  36
         return model.getType();
 84  
     }
 85  
 }