Re: turning off AN error message
- From: Henry Townsend <henry.townsend@xxxxxxxx>
- Date: Fri, 15 Jul 2005 23:07:16 -0400
Dale King wrote:
A copyright annotation is even one of the examples in documentation for annotations. You can even have the annotation specify the default value so that the copyright text appears in only one place:
So how about something like this:
@Retention( RetentionPolicy.CLASS ) public @interface CopyrightCanadianMindProducts { String text() dafault "copyright (c) 1998-2005 Roedy Green, " + "Canadian Mind Products, http://mindprod.com"; }
So then to use it:
@CopyrightCanadianMindProducts public class RoedysClass { ... }
When 2006 rolls around and you want to update the dates you only have to update the one piece of text.
Nice trick. I wonder, though: this will have the effect of embedding the full copyright notice in class files. But does it protect the source itself as well as the low-tech one-string-per-sourcefile technique does?
IANAL and all that.
-- Henry Townsend .
- Follow-Ups:
- Re: turning off AN error message
- From: Dale King
- Re: turning off AN error message
- References:
- turning off AN error message
- From: Roedy Green
- Re: turning off AN error message
- From: Dale King
- turning off AN error message
- Prev by Date: Re: turning off AN error message
- Next by Date: Re: turning off AN error message
- Previous by thread: Re: turning off AN error message
- Next by thread: Re: turning off AN error message
- Index(es):