JanosVM v0.6.0 Java API Documentation: Class MemorySpec
JanosVM v0.6.0 Java API

edu.utah.janosvm.resources
Class MemorySpec

java.lang.Object
  |
  +--edu.utah.janosvm.resources.ResourceSpec
        |
        +--edu.utah.janosvm.resources.MemorySpec

public final class MemorySpec
extends ResourceSpec
implements java.lang.Cloneable

Specification for memory resources. There are currently two details in a memory specification: the amount of memory and the policy for the GC. The amount of memory is specified in bytes, but will be rounded to the GC's internal page granularity.

Author:
Tim Stack, Utah Janos Team

Fields inherited from interface java.lang.Cloneable
KAFFE_VERSION
 
Constructor Summary
MemorySpec(int max)
          Construct a memory resource specification that requires the given amount of memory.
MemorySpec(int max, java.lang.String policyClass)
          Construct a memory resource specification that requires the given amount of memory and needs the given GCPolicy class to be used.
 
Method Summary
 java.lang.Object clone()
           
static MemorySpec currentSpec()
           
static MemorySpec defaultSpec()
           
protected  void finalize()
           
 int getMax()
           
 java.lang.String getPolicyClass()
           
 java.lang.String toString()
           
 
Methods inherited from class edu.utah.janosvm.resources.ResourceSpec
find
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MemorySpec

public MemorySpec(int max)
Construct a memory resource specification that requires the given amount of memory.
Parameters:
max - The amount of memory, in bytes, required for the team to run.

MemorySpec

public MemorySpec(int max,
                  java.lang.String policyClass)
Construct a memory resource specification that requires the given amount of memory and needs the given GCPolicy class to be used.
Parameters:
max - The amount of memory, in bytes, required for the team to run.
policyClass - The name of the policy class the new team should use when initializing the GC.
Method Detail

getMax

public int getMax()
Returns:
The maximum amount of memory, in bytes, as stored in the spec.

getPolicyClass

public java.lang.String getPolicyClass()
Returns:
The name of the policy class as stored in the spec.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

finalize

protected void finalize()
Overrides:
finalize in class java.lang.Object

clone

public java.lang.Object clone()
Overrides:
clone in class java.lang.Object

currentSpec

public static MemorySpec currentSpec()
Returns:
A MemorySpec describing the current team's memory requirements.

defaultSpec

public static MemorySpec defaultSpec()
Returns:
A MemorySpec with the default values.

JanosVM v0.6.0 Java API

This documentation is Copyright (C) 2000-2002 The University of Utah. All Rights Reserved. See the documentation license for distribution terms and restrictions.
Documentation, software, and mailing lists for the JanosVM can be found at the Janos Project web page: http://www.cs.utah.edu/flux/janos/
Generated on Mar 17, 2002