Bug 21183 Class javadoc created during "New Class" operation doesn't fill in variables properly [javadoc] [code manipulation]
If you use the enclosing_type variable in your javadoc comment template, it is not properly filled in when you make a new class (using the New Class dialog). Probably the class should be created, then after creating and saving, javadoc should be added. I suspect the variables don't have valid values yet at the time the javadoc is prepended to the class.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/javadoc/JavaDocAutoIndentStrategy.java
return d.get(lineOffset, index - lineOffset);
	}
	private String getLineContents(IDocument d, int line) throws BadLocationException {
		int offset = d.getLineOffset(line);
		int length = d.getLineLength(line) - d.getLineDelimiter(line).length();
		String lineContents = d.get(offset, length);
		int trim = jdocExtractLinePrefix(d, line).length();
		return lineContents.substring(trim);
	}
	
	private static String getLine(IDocument document, int line) throws BadLocationException {
		IRegion region= document.getLineInformation(line);		
		return document.get(region.getOffset(), region.getLength());		
	}
	/**
	 * Returns <code>true</code> if the javadoc line is too short, <code>false</code> otherwise.
	 */
	private boolean isLineTooShort(IDocument document, int line) throws BadLocationException {
		if (!isJavaDocLine(document, line + 1))
			return false;
		String nextLine= getLineContents(document, line + 1);
		if (nextLine.trim().length() == 0)
			return false;
		return true;
	}
	/**
	 * Returns <code>true</code> if the line is too long, <code>false</code> otherwise.
	 */
	private boolean isLineTooLong(IDocument document, int line) throws BadLocationException {
		String lineContents= getLine(document, line);