Bug 45517 Add a 'Field comment' code template
20031024 The user should be able to specify a 'field comment' template. See 'CodeTemplateContextType.TYPE_COMMENT' as an example You have to - define a new variable type - specify the variables avaiable in this template - create an API in Codetemplates so it can be used Users are: - AddJavadocCommentAction - JavadocTagsSubProcessor.getMissingJavadocCommentProposals
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/JavadocTagsSubProcessor.java
int line= buffer.getLineOfOffset(insertPosition);
			String lineContent= buffer.getLineContent(line);
			String indentString= Strings.getIndentString(lineContent, tabWidth);
			String str= Strings.changeIndent(comment, 0, tabWidth, indentString, buffer.getLineDelimiter());
			TextEdit rootEdit= proposal.getRootTextEdit();
			InsertEdit edit= new InsertEdit(insertPosition, str);
			rootEdit.addChild(edit); 
			if (comment.charAt(comment.length() - 1) != '\n') {
				rootEdit.addChild(new InsertEdit(insertPosition, buffer.getLineDelimiter())); 
				rootEdit.addChild(new InsertEdit(insertPosition, indentString));
			}
			
			return proposal;
		} finally {
			TextBuffer.release(buffer);
		}
	}
	
	public static void getMissingJavadocTagProposals(IInvocationContext context, IProblemLocation problem, Collection proposals) throws CoreException {
		ASTNode node= problem.getCoveringNode(context.getASTRoot());
		if (node == null) {
			return;
		}
		
		BodyDeclaration declaration= ASTResolving.findParentBodyDeclaration(node);
		if (!(declaration instanceof MethodDeclaration)) {
			return;
		}
		
		Javadoc javadoc= declaration.getJavadoc();