Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-5573

FilterToolbar generics broken

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 6.15.0
    • 6.16.0, 7.0.0-M2
    • wicket-extensions
    • None

    Description

      Once you were able to create DataTable<User> wrapped inside of
      FilterForm<UserFilterDto>

      currently FilterToolbar requires you for those two types to be identical:

      public <T, S> FilterToolbar(final DataTable<T, S> table, final
      FilterForm<T> form,
      final IFilterStateLocator<T> stateLocator)
      

      It looks like commit 9b3f9ca1df064fe9c6fde64ccc37fecc504b09a6
      introduced a bug long time ago and it carried on:

      -       public <T> FilterToolbar(final DataTable<?> table, final
      FilterForm<T> form,
      +       public <T> FilterToolbar(final DataTable<T> table, final
      FilterForm<T> form,
      

      FilterToolbar constructor should state:

      public <T, F, S> FilterToolbar(final DataTable<T, S> table, final
      FilterForm<F> form,
      final IFilterStateLocator<F> stateLocator)
      

      Attachments

        Activity

          People

            bitstorm Andrea Del Bene
            lgawron Leszek Gawron
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: