Uploaded image for project: 'Causeway'
  1. Causeway
  2. CAUSEWAY-2100

Reduce call-site complexity of 'BuilderScripts'

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.0.0-M3
    • Core
    • None

    Description

      Removing type-params, where redundant ...

      @Accessors(chain = true)
      public class SimpleObjectBuilder 
      extends BuilderScriptAbstract<SimpleObject> { // <= only 1 type param
      
          @Getter
          private SimpleObject object;
      
      	...
      }
      
      @AllArgsConstructor
      public enum SimpleObject_persona 
      implements PersonaWithBuilderScript<SimpleObjectBuilder> /* <= only 1 type param */ ... {
      
          FOO("Foo"),
          BAR("Bar"),
      	
      	...
      
          public SimpleObjectBuilder builder() {
              return new SimpleObjectBuilder().setName(name);
          }
      
          public static class PersistAll
          extends PersonaEnumPersistAll<SimpleObject_persona, SimpleObject> /* <= only 2 type params */ {
      		...
          }
      }
      

      Attachments

        Activity

          People

            hobrom Andi Huber
            hobrom Andi Huber
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: