Annotation Type Include


  • @Target(FIELD)
    public @interface Include
    Marks the annotated field as being included in it's declaring class. All public methods are exposed to the declaring class using the delegate pattern. The Autowired annotation is added to the field automatically.

    Usage example:
     class MyPage {
       @Include
       MyComponent component
     
       static class MyComponent {
         def void someMethod() {
         }
       }
     }
     
    Leads to:
     public class MyPage {
       public static class MyComponent {
         public void someMethod() {
         }
       }
     
       @Autowired
       private MyPage.MyComponent component;
     
       public void someMethod() {
         this.component.someMethod();
       }
     }
     
    Since:
    2.0.0
    Author:
    Oliver Libutzki <[email protected]>