APIdia Launch Partner
Top Description Constructors Methods
sun.management

public Class GarbageCollectorImpl

extends MemoryManagerImpl
implements GarbageCollectorMXBean
Class Inheritance
All Implemented Interfaces
java.lang.management.GarbageCollectorMXBean, java.lang.management.MemoryManagerMXBean, java.lang.management.PlatformManagedObject
Imports
java.lang.management.GarbageCollectorMXBean, .ManagementFactory, javax.management.ObjectName

Implementation class for the garbage collector. ManagementFactory.getGarbageCollectorMXBeans() returns a list of instances of this class.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public native long
getCollectionCount()

Implements java.lang.management.GarbageCollectorMXBean.getCollectionCount.

Returns the total number of collections that have occurred.

public native long
getCollectionTime()

Implements java.lang.management.GarbageCollectorMXBean.getCollectionTime.

Returns the approximate accumulated collection elapsed time in milliseconds.

public ObjectName
getObjectName()

Overrides sun.management.MemoryManagerImpl.getObjectName.

Implements java.lang.management.PlatformManagedObject.getObjectName.

Returns an ObjectName instance representing the object name of this platform managed object.

Inherited from sun.management.MemoryManagerImpl:
getMemoryPoolNamesgetMemoryPoolsgetNamegetNotificationInfoisValid

Constructor Detail

GarbageCollectorImplback to summary
protected GarbageCollectorImpl(String name)

Method Detail

getCollectionCountback to summary
public native long getCollectionCount()

Implements java.lang.management.GarbageCollectorMXBean.getCollectionCount.

Doc from java.lang.management.GarbageCollectorMXBean.getCollectionCount.

Returns the total number of collections that have occurred. This method returns -1 if the collection count is undefined for this collector.

Annotations
@Override
getCollectionTimeback to summary
public native long getCollectionTime()

Implements java.lang.management.GarbageCollectorMXBean.getCollectionTime.

Doc from java.lang.management.GarbageCollectorMXBean.getCollectionTime.

Returns the approximate accumulated collection elapsed time in milliseconds. This method returns -1 if the collection elapsed time is undefined for this collector.

The Java virtual machine implementation may use a high resolution timer to measure the elapsed time. This method may return the same value even if the collection count has been incremented if the collection elapsed time is very short.

Annotations
@Override
getObjectNameback to summary
public ObjectName getObjectName()

Overrides sun.management.MemoryManagerImpl.getObjectName.

Implements java.lang.management.PlatformManagedObject.getObjectName.

Doc from java.lang.management.PlatformManagedObject.getObjectName.

Returns an ObjectName instance representing the object name of this platform managed object.

Annotations
@Override