Re: XMLEncoder/XMLDecoder Beta 2

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Tue Dec 21 2004 - 14:02:46 EST

  • Next message: jir..bjectstyle.org: "[OS-JIRA] Created: (CAY-251) NPE on calling stored proc for SQL Server"

    Kevin,

    You can treat this as legacy. No support on the decoding end is expected.

    Andrus

    > Hi Andrus,
    >
    > Any comment on this?
    >
    > --
    > Kevin
    >
    > On Dec 16, 2004, at 8:23 AM, Kevin Menard wrote:
    >>
    >>>
    >>> You mean XML encoding map, not Cayenne DataMap? No, Cayenne doesn't
    >>> have
    >>> any support for that. IIRC our latest agreement was to keep
    >>> WebObjects format for the XML map. Am I talking about the same thing?
    >>>
    >>
    >> Sorry for the ambiguity. I meant java.util.Map. XMLEncoder currently
    >> has:
    >>
    >> /**
    >> * Utility method that prints all map values,
    >> * assuming they are XMLSerializable objects.
    >> */
    >> public void print(Map map) {
    >> Iterator it = map.entrySet().iterator();
    >> while (it.hasNext()) {
    >> Map.Entry entry = (Map.Entry) it.next();
    >> ((XMLSerializable) entry.getValue()).encodeAsXML(this);
    >> }
    >> }
    >>
    >> I wanted to provide an analog using JDOM, thus my encodeMap(). The
    >> problem is that during decoding, I can't reconstruct the above map
    >> because I don't know what the keys are. Likewise, I don't know when
    >> Cayenne would ever create a map like this, so I was asking if it was
    >> just legacy code.



    This archive was generated by hypermail 2.0.0 : Tue Dec 21 2004 - 14:02:48 EST