Automatically insert header in new java class

Posted on 2010-11-09
Medium Priority
Last Modified: 2012-05-10
How do I setup Eclipse to automatically insert a header when I create a new Java class?
e.g. I would like something like this at the top of every new Java class file:
 * Copyright 2010 Widgets Inc.,
 * All rights reserved.
 * This software is the confidential and proprietary information of Widgets Inc.
Question by:allelopath
  • 2

Expert Comment

ID: 34097539
Go to Eclipse Preferences, Java, Code Style, Code Templates.

Edit the Code template for New Java Files accordingly.

Accepted Solution

rodness earned 2000 total points
ID: 34097549
Sorry, my bad.  That was COMMENTS Template, not Code template:

Go to Eclipse Preferences, Java, Code Style, Code Templates.

Edit the COMMENTS template for FILES accordingly.

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question