|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.cornell.cs.sam.core.Sys
public class Sys
The Sys class provides a centralized point of access to all the system components. It should be instantiated by the first class to use the new system, and sets up both the CPU and the memory. It should be passed to any other components that need access to the Processor, Memory, or Video components of the system. Also, please remember to the the video component by calling setVideo().
Field Summary | |
---|---|
static java.lang.String |
SAM_VERSION
The version of the SaM Core |
Constructor Summary | |
---|---|
Sys()
Creates a new single cpu Sys. |
|
Sys(int n)
Creates a new Sys with processor(s) and memory |
Method Summary | |
---|---|
Processor |
cpu()
Returns the first CPU (or null if no CPUs) |
java.util.Collection<Processor> |
cpus()
Returns the CPU collection (or null if no CPUs are available) |
Memory |
mem()
Returns the shared memory (or null if no memory) |
void |
setVideo(Video v)
Sets the video card to the provided component |
Video |
video()
Returns the video card (or null if no video card) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String SAM_VERSION
Constructor Detail |
---|
public Sys()
public Sys(int n)
n
- - The number of processors to launchMethod Detail |
---|
public Processor cpu()
public java.util.Collection<Processor> cpus()
public Memory mem()
public Video video()
public void setVideo(Video v)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |