private Element findOrCreateClrElt(Atom classLoaderName) throws DOMException, UTFDataFormatException { if (clrElt == null) { clrElt = doc.createElement(E_CLASSLOADER); clrElt.setAttribute(A_NAME, classLoaderName.toUnicodeString()); rootElement.appendChild(clrElt); } return clrElt; }
private Element findOrCreateClassElt(Atom classLoaderName, Atom pkg, Atom className) throws UTFDataFormatException { Element classElt = classElts.get(className); if (classElt == null) { Element pkgElt = findOrCreatePkgElt(classLoaderName, pkg); classElt = doc.createElement(E_CLASS); classElt.setAttribute(A_NAME, className.toUnicodeString()); pkgElt.appendChild(classElt); classElts.put(className, classElt); } return classElt; }
private Element findOrCreatePkgElt(Atom classLoaderName, Atom pkg) throws UTFDataFormatException { if (pkgElt == null) { Element clrElt = findOrCreateClrElt(classLoaderName); pkgElt = doc.createElement(E_PACKAGE); pkgElt.setAttribute(A_NAME, pkg.toUnicodeString()); clrElt.appendChild(pkgElt); } return pkgElt; }
@SuppressWarnings("unused") private static String typeRefToStr(TypeReference fieldType) throws UTFDataFormatException { Atom className = fieldType.getName().getClassName(); Atom pkgName = fieldType.getName().getPackage(); if ( null == pkgName && null != className ) { return className.toUnicodeString(); } if (null == className ) { } return pkgName.toUnicodeString() + '/' + className.toUnicodeString(); }
public String toUnicodeString() { try { StringBuilder result = new StringBuilder(); toStringPrefix(result); if (packageName != null) { result.append(packageName.toUnicodeString()); result.append('/'); } result.append(className.toUnicodeString()); return result.toString(); } catch (UTFDataFormatException e) { e.printStackTrace(); Assertions.UNREACHABLE(); return null; } } }
public String toUnicodeString() { try { StringBuilder result = new StringBuilder(); toStringPrefix(result); if (packageName != null) { result.append(packageName.toUnicodeString()); result.append('/'); } result.append(className.toUnicodeString()); return result.toString(); } catch (UTFDataFormatException e) { e.printStackTrace(); Assertions.UNREACHABLE(); return null; } } }
public static MethodNamePattern patternForReference(MethodReference methodRef) throws UTFDataFormatException { String className = methodRef.getDeclaringClass().getName().toUnicodeString(); String methodName = methodRef.getName().toUnicodeString(); String descriptor = methodRef.getDescriptor().toUnicodeString(); MethodNamePattern pattern = new MethodNamePattern(className, methodName, descriptor); return pattern; } }
methElt.setAttribute(A_NAME, methodName.toUnicodeString());
elt.setAttribute(XMLSummaryWriter.A_TYPE, typeString); String nameString = callee.getName().toUnicodeString(); elt.setAttribute(XMLSummaryWriter.A_NAME, nameString);
String fieldName = null; try { fieldName = inst.getDeclaredField().getName().toUnicodeString(); } catch (UTFDataFormatException e) { Assertions.UNREACHABLE();
String fieldName = null; try { fieldName = inst.getDeclaredField().getName().toUnicodeString(); } catch (UTFDataFormatException e) { Assertions.UNREACHABLE();