private static void annotate(final PsiElementFactory factory, final PsiModifierListOwner listOwner, final String annotationQName)
throws IncorrectOperationException {
final PsiModifierList modifierList = listOwner.getModifierList();
LOG.assertTrue(modifierList != null);
modifierList.addAfter(factory.createAnnotationFromText("@" + annotationQName, listOwner), null);
<BUG>}
public static String suggestPropertyName(Project project, PsiField field) {</BUG>
JavaCodeStyleManager codeStyleManager = JavaCodeStyleManager.getInstance(project);
VariableKind kind = codeStyleManager.getVariableKind(field);
return codeStyleManager.variableNameToPropertyName(field.getName(), kind);

private static void annotate(final PsiElementFactory factory, final PsiModifierListOwner listOwner, final String annotationQName)
throws IncorrectOperationException {
final PsiModifierList modifierList = listOwner.getModifierList();
LOG.assertTrue(modifierList != null);
modifierList.addAfter(factory.createAnnotationFromText("@" + annotationQName, listOwner), null);
}
public static String suggestPropertyName(PsiField field) {
return suggestPropertyName(field.getProject(), field);
}
public static String suggestPropertyName(Project project, PsiField field) {
JavaCodeStyleManager codeStyleManager = JavaCodeStyleManager.getInstance(project);
VariableKind kind = codeStyleManager.getVariableKind(field);
return codeStyleManager.variableNameToPropertyName(field.getName(), kind);
