APIdia Launch Partner
Top Description Fields Constructors Methods
com.sun.management.internal

public Class GarbageCollectorExtImpl

extends GarbageCollectorImpl
implements GarbageCollectorMXBean
Class Inheritance
All Implemented Interfaces
com.sun.management.GarbageCollectorMXBean, java.lang.management.GarbageCollectorMXBean, java.lang.management.MemoryManagerMXBean, java.lang.management.PlatformManagedObject
Imports
com.sun.management.GarbageCollectionNotificationInfo, .GarbageCollectorMXBean, .GcInfo, java.lang.management.MemoryPoolMXBean, java.util.List, javax.management.ListenerNotFoundException, .MBeanNotificationInfo, .Notification, .NotificationFilter, .NotificationListener, javax.management.openmbean.CompositeData, sun.management.GarbageCollectorImpl, .ManagementFactoryHelper

Implementation class for the garbage collector. Standard and committed hotspot-specific metrics if any. ManagementFactory.getGarbageCollectorMXBeans() returns a list of instances of this class.

Field Summary

Modifier and TypeField and Description
private GcInfoBuilder
private static final String[]
private static final String
private String[]
private static long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public synchronized void
private static GarbageCollectorMXBean
protected void
createGCNotification(long timestamp, String gcName, String gcAction, String gcCause, GcInfo gcInfo)

private synchronized String[]
private synchronized GcInfoBuilder
public GcInfo
getLastGcInfo()

Implements com.sun.management.GarbageCollectorMXBean.getLastGcInfo.

Returns the GC information about the most recent GC.

private static long
public MBeanNotificationInfo[]
getNotificationInfo()

Overrides sun.management.MemoryManagerImpl.getNotificationInfo.

Implements javax.management.NotificationBroadcaster.getNotificationInfo.

Returns an array indicating, for each notification this MBean may send, the name of the Java class of the notification and the notification type.

public synchronized void
public synchronized void
private native void
Inherited from sun.management.GarbageCollectorImpl:
getCollectionCountgetCollectionTimegetObjectName

Field Detail

gcInfoBuilderback to summary
private GcInfoBuilder gcInfoBuilder
gcNotifTypesback to summary
private static final String[] gcNotifTypes
notifNameback to summary
private static final String notifName
poolNamesback to summary
private String[] poolNames
seqNumberback to summary
private static long seqNumber

Constructor Detail

GarbageCollectorExtImplback to summary
public GarbageCollectorExtImpl(String name)

Method Detail

addNotificationListenerback to summary
public synchronized void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)

Overrides sun.management.NotificationEmitterSupport.addNotificationListener.

Implements javax.management.NotificationBroadcaster.addNotificationListener.

Doc from javax.management.NotificationBroadcaster.addNotificationListener.

Adds a listener to this MBean.

createGarbageCollectorback to summary
private static GarbageCollectorMXBean createGarbageCollector(String name, String type)
createGCNotificationback to summary
protected void createGCNotification(long timestamp, String gcName, String gcAction, String gcCause, GcInfo gcInfo)
getAllPoolNamesback to summary
private synchronized String[] getAllPoolNames()
getGcInfoBuilderback to summary
private synchronized GcInfoBuilder getGcInfoBuilder()
getLastGcInfoback to summary
public GcInfo getLastGcInfo()

Implements com.sun.management.GarbageCollectorMXBean.getLastGcInfo.

Doc from com.sun.management.GarbageCollectorMXBean.getLastGcInfo.

Returns the GC information about the most recent GC. This method returns a GcInfo. If no GC information is available, null is returned. The collector-specific attributes, if any, can be obtained via the CompositeData interface.

MBeanServer access: The mapped type of GcInfo is CompositeData with attributes specified in GcInfo.

getNextSeqNumberback to summary
private static long getNextSeqNumber()
getNotificationInfoback to summary
public MBeanNotificationInfo[] getNotificationInfo()

Overrides sun.management.MemoryManagerImpl.getNotificationInfo.

Implements javax.management.NotificationBroadcaster.getNotificationInfo.

Doc from javax.management.NotificationBroadcaster.getNotificationInfo.

Returns an array indicating, for each notification this MBean may send, the name of the Java class of the notification and the notification type.

It is not illegal for the MBean to send notifications not described in this array. However, some clients of the MBean server may depend on the array being complete for their correct functioning.

removeNotificationListenerback to summary
public synchronized void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException

Overrides sun.management.NotificationEmitterSupport.removeNotificationListener.

Implements javax.management.NotificationBroadcaster.removeNotificationListener.

Doc from javax.management.NotificationBroadcaster.removeNotificationListener.

Removes a listener from this MBean. If the listener has been registered with different handback objects or notification filters, all entries corresponding to the listener will be removed.

Exceptions
ListenerNotFoundException:
The listener is not registered with the MBean.
removeNotificationListenerback to summary
public synchronized void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback) throws ListenerNotFoundException

Overrides sun.management.NotificationEmitterSupport.removeNotificationListener.

Implements javax.management.NotificationEmitter.removeNotificationListener.

Doc from javax.management.NotificationEmitter.removeNotificationListener.

Removes a listener from this MBean. The MBean must have a listener that exactly matches the given listener, filter, and handback parameters. If there is more than one such listener, only one is removed.

The filter and handback parameters may be null if and only if they are null in a listener to be removed.

Exceptions
ListenerNotFoundException:
The listener is not registered with the MBean, or it is not registered with the given filter and handback.
setNotificationEnabledback to summary
private native void setNotificationEnabled(GarbageCollectorMXBean gc, boolean enabled)