KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > admin > monitor > registry > spi > StatsHolderMBean


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23
24 /* StatsHolderMBean.java
25  * $Id: StatsHolderMBean.java,v 1.3 2005/12/25 03:43:36 tcfujii Exp $
26  * $Revision: 1.3 $
27  * $Date: 2005/12/25 03:43:36 $
28  * Indentation Information:
29  * 0. Please (try to) preserve these settings.
30  * 1. Tabs are preferred over spaces.
31  * 2. In vi/vim -
32  * :set tabstop=4 :set shiftwidth=4 :set softtabstop=4
33  * 3. In S1 Studio -
34  * 1. Tools->Options->Editor Settings->Java Editor->Tab Size = 4
35  * 2. Tools->Options->Indentation Engines->Java Indentation Engine->Expand Tabs to Spaces = False.
36  * 3. Tools->Options->Indentation Engines->Java Indentation Engine->Number of Spaces per Tab = 4.
37  */

38
39 package com.sun.enterprise.admin.monitor.registry.spi;
40
41
42 /**
43  * Provides the management interface for a StatsHolder that represents a
44  * node in the arbitrary monitoring node hierarchy. It is purposely separated
45  * from the {@link javax.management.DynamicMBean} because the implementing class
46  * may use a Standard MBean instead, to get various attributes.
47  * @author <a HREF="mailto:Kedar.Mhaswade@sun.com">Kedar Mhaswade</a>
48  * @since S1AS8.0
49  * @version $Revision: 1.3 $
50  */

51 public interface StatsHolderMBean {
52     /**
53      * Returns the {@link javax.management.ObjectName}s of all the children of associated
54      * {@link com.sun.enterprise.admin.monitor.registry.StatsHolder} in an
55      * arbitrary hierarchy. A management application should be able to build a
56      * hierarchical view using on this method. Implementing class should always
57      * return an empty array in case there are no children.
58      *
59      * @return an array of ObjectNames representing this StatsHolder's children
60      */

61     javax.management.ObjectName JavaDoc[] getChildren();
62     
63     /**
64      * Returns the name of the StatsHolder node, that the MBean is exposing
65      * This usually refers to a specific name such as HelloWorldServlet or
66      * the name of the MonitoredObjectType such as TransactionService,
67      * when a specific name does not exist. Does not return a null.
68      *
69      * @see com.sun.enterprise.admin.monitor.registry.MonitoredObjectType
70      * @return name of the node
71      */

72     String JavaDoc getName();
73     
74     /**
75      * Returns the type of the StatsHolder Node. This refers to one of several
76      * monitored object types, such as ejb-methods, bean-pool.
77      * Does not return a null.
78      *
79      * @see com.sun.enterprise.admin.monitor.registry.MonitoredObjectType
80      * @return type of the node
81      */

82     String JavaDoc getType();
83         
84     /**
85      * Returns the result of executing the getXXX methods on the associated
86      * Stats object. The result is an array of serialized Statistic objects.
87      *
88      * @return array of Statistic objects
89      */

90     javax.management.j2ee.statistics.Statistic JavaDoc[] getStatistics();
91     
92     /**
93      * Returns an array containing the names of the Statistics, for a given
94      * Stats object
95      *
96      * @return array of statistic names
97      */

98     String JavaDoc[] getStatisticNames();
99     
100 }
101
Popular Tags