[operations] [attributes] [fields] [template] [definition]
[implementation] [documentation]
To use the search tool you need to use a browser which supports JAVA (c)

[next] [prev] [superclass] [next peer] [prev peer] [subclass] [index] [hierarchy]

MemoryDevice

abstract
inherits from Object
inherits from ContainerDevice
inherits from HasFreeMemory
inherits from CanRunOutOfMemory
inherits from HasDate
inherits from SupportsBackup

Object <- MemoryDevice



Operations

Get list of all operations

AppendAvailablePackages
AttemptMemoryRecoveryIn
CheckPendingLowOnMemoryOften
ClusterForCopying
CompactAll
CompactContainer
CopyBetweenContainerDevices
CopyToContainerDevice
EachClusterInContainer
FinishFullBackup
FinishFullRestore
HandlePendingLowOnMemory
HandlePendingOutOfMemory
PerformFullBackup
PerformFullRestore
ReadPackageInfo
ReinitializeClass
RunAllHousekeepers
RunHousekeepersOnContainer
ScrambleContainer
SuggestionsForDiscarding
WritePackageInfo


Attributes

Get list of all attributes

BytesNeededToRecoverFromLowMemory
DisplayedTotalFreeBytes
LowOnMemory
LowOnMemory
Name
OutOfMemory
OutOfMemory
PendingLowOnMemory
PendingLowOnMemory
PercentUsed
TotalFreeKBytes
VolumeRosterAddress


Fields

Field Type
ContainerDevice: shelf: Viewable
containsNewObjects: Boolean
writeable: Boolean
HasDate: dateCreated: Signed
timeCreated: Unsigned
dateModified: Signed
timeModified: Unsigned
MemoryDevice: volumeRosterAddress: Pointer


Instance template

Class MemoryDevice cannot be instantiated.


Class definition

Define Class MemoryDevice;
    abstract;
    inherits from Object;
    inherits from ContainerDevice;
    inherits from HasFreeMemory;
    inherits from CanRunOutOfMemory;
    inherits from HasDate;
    inherits from SupportsBackup;

    field volumeRosterAddress: Pointer, getter, setter;

    // public interface
    
    overrides SetName;
    overrides AppendAvailablePackages;
    overrides ReadPackageInfo, WritePackageInfo;
    overrides CopyBetweenContainerDevices, CopyToContainerDevice;
    overrides PerformFullBackup, FinishFullBackup;
    overrides PerformFullRestore, FinishFullRestore;
    overrides ReinitializeClass;

    overrides TotalFreeKBytes, PercentUsed, DisplayedTotalFreeBytes;
    overrides BytesNeededToRecoverFromLowMemory;

    // low and out of memory handling
    overrides AttemptMemoryRecoveryIn;
    overrides CheckPendingLowOnMemoryOften;
    overrides HandlePendingOutOfMemory, HandlePendingLowOnMemory;
    overrides SuggestionsForDiscarding;
    
    overrides LowOnMemory, SetLowOnMemory;
    overrides PendingLowOnMemory, SetPendingLowOnMemory;
    overrides OutOfMemory, SetOutOfMemory;
    
    // copying onto device
    operation ClusterForCopying(): ObjectCluster;

    // calls used privately by the MemoryDevice and inheritors
    
    attribute VolumeRosterAddress: Pointer;
        // reference to the corresponding container's volume roster
        // we can obtain the corresponding heap from the roster as well
        // as the storage volume cluster
    
    operation CompactContainer();
        // run all compactors on containers heap
    operation RunHousekeepersOnContainer();
        // run all compactors on containers heap
    operation ScrambleContainer();
        // for debugging purposes only; moves every single block in the heap to a
        // different spot
    class operation CompactAll();
        // force all the compactors to be run on all the heaps
    class operation RunAllHousekeepers();
        // force only the housekeeping compactors to be run on all the heaps
    
    operation EachClusterInContainer(number: ClassNumber; function: EachFunction; 
        parameters: Pointer): Object;
        // iterates through all clusters implementing class <clusterClassNumber> on a given
        // container
end class;