예제 #1
0
 static void checkStatus(long s) throws DBException {
   NativeStatus status = new NativeStatus(s);
   try {
     if (!status.isOk()) {
       throw new DBException(status.toString(), status.isNotFound());
     }
   } finally {
     status.delete();
   }
 }
예제 #2
0
 void connect(InetSocketAddress addr) throws IOException {
   byte[] status = connect(handle, addr.getAddress().getHostAddress(), addr.getPort());
   NativeStatus stat = new NativeStatus(status);
   stat.checkForIOException();
 }