1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
package Torello.JavaDoc;

import java.lang.annotation.*;


// @StaticFunctional Annotation
// 
// EXPORTS:
//      public Excuse[] excuses() default {};
//      public String[] excused() default {};
// 
// 
// * Torello.JavaDoc.StaticFunctional
//      This is the actual User-Annotation that is part of the API.  A user may place the
//      @StaticFunctional Annotation on a Type / CIET (Class, Interface, Enum, Annotation or Rec)
//      And the "StatelessClass" Simple-Feature will run.  
// 
// * Torello.JDUInternal.SimpleFeatures.StatelessClasses
//      This class is the "Work-Horse" for the Static-Function JDU-API User-Annotation.  This class
//      does the actual work of inserting an HTML-Message into a Java-Doc '.html'-File which 
//      explains that the User wants to inform his/her user's that a particular class/type does not
//      maintain any state.
// 
// * Torello.JDUInternal.Annotations.TypeAnnotations.Processor.StaticFunctionalProcessor
//      This is Annotation-Processsor that is / can-be invoked by the 'javac' (Java-Compiler) at
//      Compile-Time.  Of all of the Annotation-Processors that are used by the Java-Doc Upgrader,
//      this one does THE MOST Error-Checking.  Most of them do nothing.
// 
// * Torello.JDUInternal.Annotations.TypeAnnotations.Mirror.SFMirror
//      After the JDU Detects that a CIET / Type has had the @StaticFunctional Annotation placed
//      upon it, this class extracts the relevant information out of the Annotation using the AST
//      Library in 'com.sun.source.tree' and all of it's helper classes.  It stores the data into
//      two lists.

/**
 * <B STYLE='color:darkred;'>Java-Annotation:</B>
 * 
 * A Java-Annotation for marking classes as 'Stateless Classes' -  used to insert 'The Spaghetti
 * Report' into Java Doc Pages.
 * 
 * <EMBED CLASS='external-html' DATA-FILE-ID=STATICFUNC>
 */
@Retention(RetentionPolicy.SOURCE)
@Target(ElementType.TYPE)
@JDHeaderBackgroundImg

public @interface StaticFunctional
{
    /**
     * This must contain the names of fields in this {@code class} or {@code interface} that
     * have been declared {@code static}, but have not been declared {@code final}.
     * 
     * <BR /><BR /><B STYLE='color: red;'>NOTE:</B> The values in the {@code 'Excused'} array
     * must be parallel to the values in the {@code 'Excuses'} array.
     */
    String[] Excused() default { };

    /**
     * This must contain instances of the Enumerated-Type {@code 'Excuses'}.  These excuses
     * should explain the reason why the named field has not been declared {@code 'final'} in any
     * {@code class} or {@code interface} that has been marked with the {@code @StaticFunction}
     * annotation.
     *  
     * <BR /><BR /><B STYLE='color: red;'>NOTE:</B> The values in the {@code 'Excuses'} array
     * must be parallel to the values in the {@code 'Excused'} array.
     */
    Excuse[] Excuses() default { };
}