libConsole/Console.java
changeset 55 2a20d0184041
parent 49 77094ec383cf
child 83 220d76d0d672
equal deleted inserted replaced
54:c064ce9f40f5 55:2a20d0184041
     1 public class Console {
     1 public class Console {
     2     public static native int getch ();
     2     public static native int getch ();
       
     3     private static void help () {
       
     4         String p = System.getProperty ("java.library.path");
       
     5         String[] msg = p.split (":");
       
     6         System.err.printf ("Console Error:\n");
       
     7 
       
     8         for (int i = 0; i < msg.length; i++)
       
     9             System.err.printf ("\t%s\n", msg[i]);
       
    10         System.exit (-1);
       
    11     };
       
    12 
     3     static {
    13     static {
     4         System.loadLibrary ("Console");
    14         try {
     5     }
    15             System.loadLibrary ("Console");
       
    16         } catch (UnsatisfiedLinkError ule) {
       
    17             System.err.println (ule.getLocalizedMessage ());
       
    18             help ();
       
    19         }
       
    20     };
     6 }
    21 }