Wicket
  1. Wicket
  2. WICKET-4815

Interface to mark components with type safe models

    Details

    • Type: New Feature New Feature
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 6.1.1
    • Fix Version/s: 6.2.0
    • Component/s: wicket
    • Labels:
      None

      Description

      Could we please have an interface to tag components that support type safe default models (Think Link, GenericPanel etc). This would help enforce consistency across these types of components.

      Something like:

      public interface IGenericComponent<T>

      { IModel<T> getModel(); void setModel(IModel<T> model); void setModelObject(T object); T getModelObject(); }

      It may also be a good idea to implement a helper utility that does all the casting etc, and takes an additional Component argument per method.

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        6h 51m 1 Martin Grigorov 15/Oct/12 14:36
        Martin Grigorov made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Martin Grigorov [ mgrigorov ]
        Fix Version/s 6.2.0 [ 12323295 ]
        Resolution Fixed [ 1 ]
        Hide
        Martin Grigorov added a comment -

        I didn't add the helper.
        I think we can make all components typesafe for Wicket 7. It will use JDK7 and diamonds will help to keep the amount of typing not that big.

        Show
        Martin Grigorov added a comment - I didn't add the helper. I think we can make all components typesafe for Wicket 7. It will use JDK7 and diamonds will help to keep the amount of typing not that big.
        Jesse Long created issue -

          People

          • Assignee:
            Martin Grigorov
            Reporter:
            Jesse Long
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development