XStream
  1. XStream
  2. XSTR-428

transient member field named 'id' caused bad deserialization

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 1.2.2
    • Fix Version/s: 1.3
    • Component/s: Converters
    • Labels:
      None
    • JDK version and platform:
      JDK 1.6.02, win xp

      Description

      See attached test case
      scenario:
      1. create a class with member field called "id" and some more member fields
      2. serialize it to XML
      3. deserialize from XML
      Outcome:
      all member fields will be null in deserialized instance

      IMHO,
      apparently what cause it, is com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter#doUnmarshal()
      on line 143, after attribute named "id" was approved as transient member field, Reader is instructed to move out from current XML element, which causes all information in this element to be passed over.

        People

        • Assignee:
          Jörg Schaible
          Reporter:
          Mirron
        • Votes:
          0 Vote for this issue
          Watchers:
          0 Start watching this issue

          Dates

          • Created:
            Updated:
            Resolved: