< prev index next >

agent/src/share/classes/sun/jvm/hotspot/debugger/windbg/WindbgAddress.java

Print this page




 275     }
 276     return new WindbgAddress(debugger, value);
 277   }
 278 
 279   public Address    orWithMask(long mask) throws UnsupportedOperationException {
 280     long value = addr | mask;
 281     if (value == 0) {
 282       return null;
 283     }
 284     return new WindbgAddress(debugger, value);
 285   }
 286 
 287   public Address    xorWithMask(long mask) throws UnsupportedOperationException {
 288     long value = addr ^ mask;
 289     if (value == 0) {
 290       return null;
 291     }
 292     return new WindbgAddress(debugger, value);
 293   }
 294 

 295 
 296   //--------------------------------------------------------------------------------
 297   // Internals only below this point
 298   //
 299 
 300   long getValue() {
 301     return addr;
 302   }
 303 
 304 
 305   private static void check(boolean arg, String failMessage) {
 306     if (!arg) {
 307       System.err.println(failMessage + ": FAILED");
 308       System.exit(1);
 309     }
 310   }
 311 
 312   // Test harness
 313   public static void main(String[] args) {
 314     // p/n indicates whether the interior address is really positive




 275     }
 276     return new WindbgAddress(debugger, value);
 277   }
 278 
 279   public Address    orWithMask(long mask) throws UnsupportedOperationException {
 280     long value = addr | mask;
 281     if (value == 0) {
 282       return null;
 283     }
 284     return new WindbgAddress(debugger, value);
 285   }
 286 
 287   public Address    xorWithMask(long mask) throws UnsupportedOperationException {
 288     long value = addr ^ mask;
 289     if (value == 0) {
 290       return null;
 291     }
 292     return new WindbgAddress(debugger, value);
 293   }
 294 
 295   public long asLongValue() { return addr; }
 296 
 297   //--------------------------------------------------------------------------------
 298   // Internals only below this point
 299   //
 300 
 301   long getValue() {
 302     return addr;
 303   }
 304 
 305 
 306   private static void check(boolean arg, String failMessage) {
 307     if (!arg) {
 308       System.err.println(failMessage + ": FAILED");
 309       System.exit(1);
 310     }
 311   }
 312 
 313   // Test harness
 314   public static void main(String[] args) {
 315     // p/n indicates whether the interior address is really positive


< prev index next >