KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > java > lang > management > MemoryManagerMXBean


1 /*
2  * @(#)MemoryManagerMXBean.java 1.10 04/04/20
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7
8 package java.lang.management;
9
10 /**
11  * The management interface for a memory manager.
12  * A memory manager manages one or more memory pools of the
13  * Java virtual machine.
14  *
15  * <p> A Java virtual machine has one or more memory managers.
16  * An instance implementing this interface is
17  * an <a HREF="ManagementFactory.html#MXBean">MXBean</a>
18  * that can be obtained by calling
19  * the {@link ManagementFactory#getMemoryManagerMXBeans} method or
20  * from the {@link ManagementFactory#getPlatformMBeanServer
21  * platform <tt>MBeanServer</tt>} method.
22  *
23  * <p>The <tt>ObjectName</tt> for uniquely identifying the MXBean for
24  * a memory manager within an MBeanServer is:
25  * <blockquote>
26  * {@link ManagementFactory#MEMORY_MANAGER_MXBEAN_DOMAIN_TYPE
27  * <tt>java.lang:type=MemoryManager</tt>}<tt>,name=</tt><i>manager's name</i>
28  * </blockquote>
29  *
30  * @see MemoryMXBean
31  *
32  * @see <a HREF="../../../javax/management/package-summary.html">
33  * JMX Specification.</a>
34  * @see <a HREF="package-summary.html#examples">
35  * Ways to Access MXBeans</a>
36  *
37  * @author Mandy Chung
38  * @version 1.10, 04/20/04
39  * @since 1.5
40  */

41 public interface MemoryManagerMXBean {
42     /**
43      * Returns the name representing this memory manager.
44      *
45      * @return the name of this memory manager.
46      */

47     public String JavaDoc getName();
48
49     /**
50      * Tests if this memory manager is valid in the Java virtual
51      * machine. A memory manager becomes invalid once the Java virtual
52      * machine removes it from the memory system.
53      *
54      * @return <tt>true</tt> if the memory manager is valid in the
55      * Java virtual machine;
56      * <tt>false</tt> otherwise.
57      */

58     public boolean isValid();
59
60     /**
61      * Returns the name of memory pools that this memory manager manages.
62      *
63      * @return an array of <tt>String</tt> objects, each is
64      * the name of a memory pool that this memory manager manages.
65      */

66     public String JavaDoc[] getMemoryPoolNames();
67 }
68
69
Popular Tags