fi.hu.cs.titokone
Class Loader
java.lang.Object
fi.hu.cs.titokone.Loader
- public class Loader
- extends java.lang.Object
This class can load a TTK91Application. It changes the processor
state accordingly. Everything is loaded when loadApplication is
called. Function returns the state of memory after loading. If it
runs out of memory it throws a TTK91AddressOutOfBounds exception.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
application
private Application application
- This variable holds the current application to be loaded.
processor
private Processor processor
binInterpreter
private BinaryInterpreter binInterpreter
Loader
public Loader(Processor processor)
setApplicationToLoad
public void setApplicationToLoad(Application application)
- You can set the file to load. Each time an application is set to load, the counter is set to
one.
loadApplication
public LoadInfo loadApplication()
throws TTK91AddressOutOfBounds
- Loads an application to memory. LoadInfo contains all the needed information about the process.
- Returns:
- Info from the load procedure, null if no application has been set for loading.
- Throws:
TTK91AddressOutOfBounds