Top Description Methods
org.osgi.service.resourcemonitoring.monitor

public Interface DiskStorageMonitor

extends ResourceMonitor<Long>
Imports
org.osgi.service.resourcemonitoring.ResourceContext, .ResourceMonitor, .ResourceMonitoringService

A ResourceMonitor for the ResourceMonitoringService#RES_TYPE_DISK_STORAGE resource type. A DiskStorageMonitor instance monitors and limits the persistent storage of the bundle belonging to the ResourceContext
Author
$Id: 503c6bd306ddb27d34644b471b35ba953d8f7437 $
Version
1.0

Method Summary

Modifier and TypeMethod and Description
public long

Returns:

the sum of the sizes of the persistent storage areas in bytes
getUsedDiskStorage
()

Returns the sum of the size of the persistent storage areas of the bundles in this resource context.

Inherited from org.osgi.service.resourcemonitoring.ResourceMonitor:
deletedisableenableequalsgetContextgetMonitoredPeriodgetResourceTypegetSamplingPeriodgetUsagehashCodeisDeletedisEnabled

Method Detail

getUsedDiskStorageback to summary
public long getUsedDiskStorage()

Returns the sum of the size of the persistent storage areas of the bundles in this resource context.

The getUsage() method returns the same value, wrapped in a long.

Returns:long

the sum of the sizes of the persistent storage areas in bytes