Labs
  1. Labs
  2. LABS-352

[refactoring][beanview] Carve single mode creation pieces out of producers

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: Current
    • Fix Version/s: Current
    • Component/s: Magma
    • Labels:
      None

      Description

      With LABS-351 we have intermediate types that can be inferred instead of more generic types like String, byte[] or streams.

      Now we need to implement a way to have beansview pieces to cope with them.

      This should be done in a pluggable way. Most importantly, pluggability is needed to extend both ShowBean and ShowList (and conseguently form and paginated list) customization.

      Right now, ShowBean delegates to a createMain method the creation of the inner content of a leaf in the ViewTree, the form producer then further delegates to specific methods to create drodowns, textareas etc..

      Similarly, ShowList delegates to createFieldNodeCell method, which is a bit less clean than createMain.

      Probably, we could refactor these methods a bit to give a clear path for extension using AspectJ around advices. For example, to handle file uploads, an around advice on createMain could intercept when the node contains a File intermediate type and output an upload field in the form or a link for downloading the file in a showbean.

      A similar approach should be taken for form binding, cause the two will most probably go in pairs.

      The final objective could be to declare an abstract aspect to customize appearance of certain intermediate types in lists, showbeans and forms, and parsing of incoming parameters for forms binding.

      Such aspects could then be implemented to support different form/display technologies, like JSF.

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Simone Gianni
            Reporter:
            Simone Gianni
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development