use of org.glassfish.hk2.external.org.objectweb.asm.FieldVisitor in project Payara by payara.
the class CompositeUtil method createField.
/**
* Add the field to the class, adding the @XmlAttribute annotation for marshalling purposes.
*/
private void createField(ClassWriter cw, String name, Class<?> type) {
String internalType = getInternalTypeString(type);
FieldVisitor field = cw.visitField(ACC_PRIVATE, getPropertyName(name), internalType, null, null);
field.visitAnnotation("Ljavax/xml/bind/annotation/XmlAttribute;", true).visitEnd();
field.visitEnd();
}
Aggregations