Commons Lang
  1. Commons Lang
  2. LANG-751

Include the actual type in the Validate.isInstance and isAssignableFrom exception messages.

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.1
    • Fix Version/s: 3.1
    • Component/s: lang.*
    • Labels:
      None
    • Environment:

      Description

      The message for the exception thrown by Validate.isInstance and isAssignableFrom do not mention the actual type, only the expected type.

      trunk: "The validated object is not an instance of %s"

      Proposal:

      • isAssignableFrom: "Cannot assign a java.lang.String to a java.util.List"
      • isInstance: "Expected type: java.util.List, actual: java.lang.String"

        Activity

        Hide
        Gary Gregory added a comment -

        In SVN.

        Show
        Gary Gregory added a comment - In SVN.

          People

          • Assignee:
            Gary Gregory
            Reporter:
            Gary Gregory
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development