SandMark version 3.0


sandmark.util
Class Misc

java.lang.Object
  |
  +--sandmark.util.Misc

public class Misc
extends java.lang.Object

The sandmark.util.Misc class holds utility methods that don't fit anywhere else.


Constructor Summary
Misc()
           
 
Method Summary
static void abort(java.lang.String msg)
           
static void exit(int val, java.lang.String msg)
           
static java.lang.String getClassForKey(java.lang.String key)
           
static java.lang.String getKeyForApp()
          Returns a String to use as a hashkey to hash the whole application.
static java.lang.String getKeyForClass(java.lang.String classname)
          Returns a String to use as a hashkey to hash a class.
static java.lang.String getKeyForMethod(java.lang.String classname, java.lang.String methodname, java.lang.String signature)
          Returns a String to use as a hashkey to hash a method.
static java.lang.String[] getMethodForKey(java.lang.String key)
          Given the hashkey from getKeyForMethod, returns an array of Strings {class name, method name, signature} for the method.
static java.lang.String int2String(int k)
           
static java.lang.String joinArgs(java.lang.String[] arglist, int first, int len)
           
static void main(java.lang.String[] args)
           
static java.lang.String matrix2String(int[][] M)
           
static java.lang.String row2String(int[] row)
           
static java.lang.String[] splitArgs(java.lang.String argstring)
           
static void writeToFile(java.lang.String fileName, java.lang.String string)
          Write a string to a file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Misc

public Misc()
Method Detail

getKeyForClass

public static java.lang.String getKeyForClass(java.lang.String classname)
Returns a String to use as a hashkey to hash a class.


getKeyForMethod

public static java.lang.String getKeyForMethod(java.lang.String classname,
                                               java.lang.String methodname,
                                               java.lang.String signature)
Returns a String to use as a hashkey to hash a method.


getMethodForKey

public static java.lang.String[] getMethodForKey(java.lang.String key)
Given the hashkey from getKeyForMethod, returns an array of Strings {class name, method name, signature} for the method. If a malformed key is passed to this method, the result is not defined.


getClassForKey

public static java.lang.String getClassForKey(java.lang.String key)

getKeyForApp

public static java.lang.String getKeyForApp()
Returns a String to use as a hashkey to hash the whole application.


abort

public static void abort(java.lang.String msg)

exit

public static void exit(int val,
                        java.lang.String msg)

matrix2String

public static java.lang.String matrix2String(int[][] M)

row2String

public static java.lang.String row2String(int[] row)

int2String

public static java.lang.String int2String(int k)

joinArgs

public static java.lang.String joinArgs(java.lang.String[] arglist,
                                        int first,
                                        int len)

splitArgs

public static java.lang.String[] splitArgs(java.lang.String argstring)

writeToFile

public static void writeToFile(java.lang.String fileName,
                               java.lang.String string)
                        throws java.lang.Exception
Write a string to a file.

Parameters:
fileName - The name of the file to be written.
string - The string to be written.
java.lang.Exception

main

public static void main(java.lang.String[] args)

SandMark version 3.0

Wed Jan 29 10:30:05 MST 2003