예제 #1
0
파일: Atom.java 프로젝트: alanweide/coff
 /** Create a class name from a type name. For example Lfoo.bar$$; becomes the string foo.bar */
 @Pure
 public String annotationClassToAnnotationInterface() {
   if (VM.VerifyAssertions) {
     VM._assert(val.length > 0);
     VM._assert(val[0] == 'L' && val[val.length - 1] == ';', toString());
   }
   return StringUtilities.asciiBytesToString(val, 1, val.length - 4).replace('/', '.');
 }
예제 #2
0
파일: Atom.java 프로젝트: alanweide/coff
 /**
  * Return name of class file corresponding to "this" class descriptor. this: class descriptor -
  * something like "Ljava/lang/String;"
  *
  * @return class file name - something like "java/lang/String.class"
  */
 @Pure
 public String classFileNameFromDescriptor() {
   if (VM.VerifyAssertions) {
     VM._assert(val.length > 0);
     VM._assert(val[0] == 'L' && val[val.length - 1] == ';');
   }
   if (unicodeStringOrJTOCoffset == null) {
     return StringUtilities.asciiBytesToString(val, 1, val.length - 2) + ".class";
   } else {
     return toUnicodeStringInternal().substring(1, val.length - 1) + ".class";
   }
 }
예제 #3
0
파일: Atom.java 프로젝트: alanweide/coff
 /** Return printable representation of "this" atom. Does not correctly handle UTF8 translation. */
 @Override
 @Pure
 public String toString() {
   return StringUtilities.asciiBytesToString(val);
 }