001package Torello.JavaDoc;
002
003import java.lang.annotation.*;
004
005
006// @StaticFunctional Annotation
007// 
008// EXPORTS:
009//      public Excuse[] excuses() default {};
010//      public String[] excused() default {};
011// 
012// 
013// * Torello.JavaDoc.StaticFunctional
014//      This is the actual User-Annotation that is part of the API.  A user may place the
015//      @StaticFunctional Annotation on a Type / CIET (Class, Interface, Enum, Annotation or Rec)
016//      And the "StatelessClass" Simple-Feature will run.  
017// 
018// * Torello.JDUInternal.SimpleFeatures.StatelessClasses
019//      This class is the "Work-Horse" for the Static-Function JDU-API User-Annotation.  This class
020//      does the actual work of inserting an HTML-Message into a Java-Doc '.html'-File which 
021//      explains that the User wants to inform his/her user's that a particular class/type does not
022//      maintain any state.
023// 
024// * Torello.JDUInternal.Annotations.TypeAnnotations.Processor.StaticFunctionalProcessor
025//      This is Annotation-Processsor that is / can-be invoked by the 'javac' (Java-Compiler) at
026//      Compile-Time.  Of all of the Annotation-Processors that are used by the Java-Doc Upgrader,
027//      this one does THE MOST Error-Checking.  Most of them do nothing.
028// 
029// * Torello.JDUInternal.Annotations.TypeAnnotations.Mirror.SFMirror
030//      After the JDU Detects that a CIET / Type has had the @StaticFunctional Annotation placed
031//      upon it, this class extracts the relevant information out of the Annotation using the AST
032//      Library in 'com.sun.source.tree' and all of it's helper classes.  It stores the data into
033//      two lists.
034
035/**
036 * <B STYLE='color:darkred;'>Java-Annotation:</B>
037 * 
038 * A Java-Annotation for marking classes as 'Stateless Classes' -  used to insert 'The Spaghetti
039 * Report' into Java Doc Pages.
040 * 
041 * <EMBED CLASS='external-html' DATA-FILE-ID=STATICFUNC>
042 */
043@Retention(RetentionPolicy.SOURCE)
044@Target(ElementType.TYPE)
045@JDHeaderBackgroundImg
046
047public @interface StaticFunctional
048{
049    /**
050     * This must contain the names of fields in this {@code class} or {@code interface} that
051     * have been declared {@code static}, but have not been declared {@code final}.
052     * 
053     * <BR /><BR /><B STYLE='color: red;'>NOTE:</B> The values in the {@code 'Excused'} array
054     * must be parallel to the values in the {@code 'Excuses'} array.
055     */
056    String[] Excused() default { };
057
058    /**
059     * This must contain instances of the Enumerated-Type {@code 'Excuses'}.  These excuses
060     * should explain the reason why the named field has not been declared {@code 'final'} in any
061     * {@code class} or {@code interface} that has been marked with the {@code @StaticFunction}
062     * annotation.
063     *  
064     * <BR /><BR /><B STYLE='color: red;'>NOTE:</B> The values in the {@code 'Excuses'} array
065     * must be parallel to the values in the {@code 'Excused'} array.
066     */
067    Excuse[] Excuses() default { };
068}