Uploaded image for project: 'Tapestry 5'
  1. Tapestry 5
  2. TAP5-2496

Inconsistent behavior of EnumValueEncoder

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.4
    • Fix Version/s: 5.4
    • Component/s: None
    • Labels:
      None

      Description

      EnumValueEncoder uses java.lang.Enum.name() in toClient(E) but uses typeCoercer.coerce(clientValue, enumType) in toValue(String clientValue).
      I have a custom coercer in my project and this causes the value encoder to be unable to decode the client-side value back to a server-side value.
      I think we should remove EnumValueEncoderFactory altogether because TypeCoercedValueEncoderFactory should do its job just fine.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jkemnade Jochen Kemnade
                Reporter:
                jkemnade Jochen Kemnade
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: