* @return null if unable to get or compute the key for this method, otherwise
* the key is returned
*/
public static String getKey(TreeLogger logger, KeyGenerator keyGenerator,
JMethod method, boolean isConstants) {
Key key = method.getAnnotation(Key.class);
if (key != null) {
return key.value();
}
String text;
try {
text = getTextString(method, null, isConstants);
} catch (AnnotationsError e) {