/** Returns the class tag of a comment, e.g."header" or "interface". */ public static String getClassTag(String comment) { String[] tags = CommentUtils.getTags(comment).split(","); for (String tag : tags) { if (!tag.equals("") && CommentTags.isTag(tag)) return tag; } return ""; }
/** Returns true if comment contains no other information than java doc tags */ public static boolean hasOnlyJavaDoc(String comment) { comment = CommentUtils.removeCommentIdentifiers(comment); comment = CommentUtils.removeJavaDocElements(comment); comment = comment.replaceAll("\\s+", ""); return comment.length() == 0; }