Tapestry 5
  1. Tapestry 5
  2. TAP5-98

The TypeCoercer should be able to coerce String to Enum types, even without a specific contribution

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 5.0.15
    • Fix Version/s: 5.3
    • Component/s: tapestry-ioc
    • Labels:
      None

      Description

      In the current implementation to allow coersion form string literal to Enum we need to add contribution to the TypeCoercer. This is working. But this coersion can be performed by default using just Enum.valueOf (Class, String), so there are not required to register new coersion for every used enum type. In this case whe are lost the case insensibility of enum coersions, but if this is meaningfull for everyone we can still use contributed coersions, and if no one is found fallback do the default. Enum.valueOf

        Activity

        Alexander Gavrilov created issue -
        Howard M. Lewis Ship made changes -
        Field Original Value New Value
        Fix Version/s 5.0.12 [ 12313048 ]
        Fix Version/s 5.0.13 [ 12313205 ]
        Howard M. Lewis Ship made changes -
        Fix Version/s 5.0 [ 12312018 ]
        Fix Version/s 5.0.13 [ 12313205 ]
        Howard M. Lewis Ship made changes -
        Key TAPESTRY-2402 TAP5-98
        Fix Version/s 5.0 [ 12312018 ]
        Issue Type Improvement [ 4 ] Bug [ 1 ]
        Project Tapestry [ 10573 ] Tapestry 5 [ 12310833 ]
        Affects Version/s 5.0.11 [ 12312968 ]
        Howard M. Lewis Ship made changes -
        Affects Version/s 5.0.15 [ 12313429 ]
        Howard M. Lewis Ship made changes -
        Issue Type Bug [ 1 ] Improvement [ 4 ]
        Howard M. Lewis Ship made changes -
        Assignee Howard M. Lewis Ship [ hlship ]
        Howard M. Lewis Ship made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Howard M. Lewis Ship made changes -
        Summary Tapestry should be smarter about coersing string literals to Enum's The TypeCoercer should be able to coerce String to Enum types, even without a specific contribution
        Component/s tapestry-ioc [ 12312469 ]
        Howard M. Lewis Ship made changes -
        Status In Progress [ 3 ] Closed [ 6 ]
        Fix Version/s 5.3.0 [ 12316023 ]
        Resolution Fixed [ 1 ]
        Howard M. Lewis Ship made changes -
        Fix Version/s 5.3 [ 12316024 ]
        Fix Version/s 5.3.0 [ 12316023 ]

          People

          • Assignee:
            Howard M. Lewis Ship
            Reporter:
            Alexander Gavrilov
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development