List of usage examples for org.eclipse.jdt.internal.compiler.env IBinaryField getGenericSignature
char[] getGenericSignature();
From source file:com.codenvy.ide.ext.java.server.internal.core.BinaryField.java
License:Open Source License
public String getTypeSignature() throws JavaModelException { IBinaryField info = (IBinaryField) getElementInfo(); char[] genericSignature = info.getGenericSignature(); if (genericSignature != null) { return new String(ClassFile.translatedName(genericSignature)); }//from w w w. ja v a 2s . c o m return new String(ClassFile.translatedName(info.getTypeName())); }
From source file:org.eclipse.che.jdt.BinaryTypeConvector.java
License:Open Source License
private static JsonElement toJsonField(IBinaryField field) { JsonObject object = new JsonObject(); object.addProperty("modifiers", field.getModifiers()); object.add("constant", toJsonConstant(field.getConstant())); object.add("genericSignature", field.getGenericSignature() == null ? JsonNull.INSTANCE : new JsonPrimitive(new String(field.getGenericSignature()))); object.add("name", field.getName() == null ? JsonNull.INSTANCE : new JsonPrimitive(new String(field.getName()))); object.addProperty("tagBits", String.valueOf(field.getTagBits())); object.add("typeName", field.getTypeName() == null ? JsonNull.INSTANCE : new JsonPrimitive(new String(field.getTypeName()))); object.add("annotations", toJsonAnnotations(field.getAnnotations())); return object; }