|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.vub.at.objects.natives.NATNil
edu.vub.at.objects.natives.NATByCopy
edu.vub.at.objects.natives.OBJSystem
The sole instance of the class OBJSystem represents the 'system' object, accessible from the lexical root during execution of 'iat'. This object contains various native methods to interface with the shell environment. The interface of the system object is as follows: def system := object: { def argv := the table of extra command-line arguments passed to iat def exit() { quits iat } def print(@objs) { print objects to standard output } def println(@objs) { print objects to standard output, followed by a newline } def read() { read character from standard input } def readln() { read next line from input } def reset() { reset VM into fresh startup state and re-evaluates init and argument file } }
Field Summary | |
private NATTable |
argv_
|
Fields inherited from class edu.vub.at.objects.natives.NATNil |
_INSTANCE_ |
Constructor Summary | |
OBJSystem(java.lang.String[] argv)
|
Method Summary | |
ATNil |
base_exit()
def exit() { quits iat } |
ATTable |
base_getArgv()
def argv := command-line arguments passed to iat |
ATNil |
base_print(ATObject[] objs)
def print(@obj) { print obj to standard output } |
ATNil |
base_println(ATObject[] objs)
def println(@obj) { self.print(#[@obj, '\n']) } |
ATObject |
base_read()
def read() { read character from standard input } |
ATObject |
base_readln()
def readln() { read next line from input } |
ATObject |
base_reset()
def reset() { reset VM into fresh startup state and re-evaluates init and main file } Resets the global lexical scope to an empty object. |
NATText |
meta_print()
Prints out the object in a human-readable way. |
Methods inherited from class edu.vub.at.objects.natives.NATByCopy |
meta_pass, meta_resolve |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
private NATTable argv_
Constructor Detail |
public OBJSystem(java.lang.String[] argv)
Method Detail |
public NATText meta_print() throws InterpreterException
ATObject
meta_print
in interface ATObject
meta_print
in class NATNil
InterpreterException
public ATTable base_getArgv()
public ATNil base_exit()
public ATNil base_print(ATObject[] objs) throws InterpreterException
InterpreterException
- if obj cannot be converted into a native text valuepublic ATNil base_println(ATObject[] objs) throws InterpreterException
InterpreterException
public ATObject base_read() throws XIOProblem
XIOProblem
public ATObject base_readln() throws XIOProblem
XIOProblem
- if unable to read from standard inputpublic ATObject base_reset()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |