frysk.isa.syscalls
Class Syscall

java.lang.Object
  extended by frysk.isa.syscalls.Syscall

public abstract class Syscall
extends Object

A class that holds static information about a system call. It is used in combination with SyscallEventInfo and the task to get information about a particular system call event.


Field Summary
static Syscall INVALID
           
 
Method Summary
 boolean equals(Object other)
          Return true if this object equals the argument.
 String[] extractCallArguments(Task task)
          Get call arguments as a vector of Objects.
 String extractReturnValue(Task task)
          Extract system call return value.
 String getArgList()
          Return the argument list.
abstract  long getArguments(Task task, int n)
           
 String getName()
          Return the name of the system call.
 int getNumArgs()
          Return the number of arguments.
 int getNumber()
          Return the system call's number.
abstract  long getReturnCode(Task task)
           
 boolean isNoReturn()
          Does the system call return a result?
 PrintWriter printCall(PrintWriter writer, Task task)
          Print a textual representation of a system call.
 PrintWriter printReturn(PrintWriter writer, Task task)
          Print a textual representation of the return result of a system call.
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

INVALID

public static final Syscall INVALID
Method Detail

getName

public String getName()
Return the name of the system call.


getNumber

public int getNumber()
Return the system call's number.


getNumArgs

public int getNumArgs()
Return the number of arguments.


getArgList

public String getArgList()
Return the argument list.


isNoReturn

public boolean isNoReturn()
Does the system call return a result?


equals

public boolean equals(Object other)
Return true if this object equals the argument.

Overrides:
equals in class Object

getArguments

public abstract long getArguments(Task task,
                                  int n)

getReturnCode

public abstract long getReturnCode(Task task)

extractCallArguments

public String[] extractCallArguments(Task task)
Get call arguments as a vector of Objects. Currently returns simpy a vector of formatted strings.

Parameters:
task - the task which supplies information about the arguments

printCall

public PrintWriter printCall(PrintWriter writer,
                             Task task)
Print a textual representation of a system call.

Parameters:
writer - where to print the representation
task - the task which supplies information about the arguments
Returns:
writer

toString

public String toString()
Overrides:
toString in class Object

extractReturnValue

public String extractReturnValue(Task task)
Extract system call return value. Currently returns formatted string.


printReturn

public PrintWriter printReturn(PrintWriter writer,
                               Task task)
Print a textual representation of the return result of a system call.

Parameters:
writer - where to print the representation
task - the task which supplies information about the return value
Returns:
writer