Return-Path: Delivered-To: apmail-incubator-abdera-dev-archive@locus.apache.org Received: (qmail 120 invoked from network); 7 Mar 2008 07:43:20 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 7 Mar 2008 07:43:20 -0000 Received: (qmail 68268 invoked by uid 500); 7 Mar 2008 07:43:17 -0000 Delivered-To: apmail-incubator-abdera-dev-archive@incubator.apache.org Received: (qmail 68168 invoked by uid 500); 7 Mar 2008 07:43:17 -0000 Mailing-List: contact abdera-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: abdera-dev@incubator.apache.org Delivered-To: mailing list abdera-dev@incubator.apache.org Received: (qmail 68159 invoked by uid 99); 7 Mar 2008 07:43:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Mar 2008 23:43:16 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [63.246.7.16] (HELO mail.mulesource.com) (63.246.7.16) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Mar 2008 07:42:38 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.mulesource.com (Postfix) with ESMTP id 78E152830FBE for ; Fri, 7 Mar 2008 01:42:48 -0600 (CST) X-Virus-Scanned: amavisd-new at X-Spam-Score: -0.519 X-Spam-Level: Received: from mail.mulesource.com ([127.0.0.1]) by localhost (mail.mulesource.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xm8kwFmowYwH for ; Fri, 7 Mar 2008 01:42:46 -0600 (CST) Received: from [192.168.1.102] (unknown [71.141.148.182]) by mail.mulesource.com (Postfix) with ESMTP id 439202830FB1 for ; Fri, 7 Mar 2008 01:42:46 -0600 (CST) Message-ID: <47D0F1CF.9020103@mulesource.com> Date: Thu, 06 Mar 2008 23:42:07 -0800 From: Dan Diephouse User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: abdera-dev@incubator.apache.org Subject: Re: Entity/DTO serialization in entry.content References: <86FB4BFB698D4E048EF5BF5F0776157C@ArrovaL001> <95AC86B72AC74091A026D811F777FD36@ArrovaL001> <47C7602F.60405@mulesource.com> In-Reply-To: <47C7602F.60405@mulesource.com> Content-Type: text/plain; charset=windows-1250; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Old-Spam-Status: No, score=-0.519 tagged_above=-10 required=6.6 tests=[AWL=0.034, BAYES_00=-2.599, RCVD_IN_SORBS_DUL=2.046] I've been thinking about this some more today. I'd really like to write some code like this: Entry entry = ....; entry.addElement(new JAXBElement(myJaxbPojo)); Then when the entry is serialized, it would call out to JAXB and marshal the "myJaxbPojo" object using an XMLStreamWriter. Anyone have any pointers as to how to actually achieve this? Dan Dan Diephouse wrote: > I've been meaning to write a JAXB plugin for this purpose, but time > hasn't quite allowed me. What I *really* want though is an XHTML > databinding framework... Frameworks fix everything! :-) > > http://netzooid.com/blog/2007/12/11/lazyweb-microformat-databinding/ > > Dan > > Remy Gendron wrote: >> After looking at this a bit more, XMLEncoder would be a better fit. >> >> R. >> >> -----Original Message----- >> From: Remy Gendron [mailto:remy@arrova.ca] Sent: February 28, 2008 12:13 >> To: abdera-user@incubator.apache.org >> Subject: Entity/DTO serialization in entry.content >> >> Hello all, >> >> >> >> My entries are backed by simple entity pojos. >> >> >> >> To prevent business rules from being implemented outside my service >> layer, >> the service APIs use interfaces on these pojos. The interface make only >> certain fields available to the caller, and some of those fields are >> only >> readable (only a getter is available in the interface). So, no DTOs. >> Only my >> entities wrapped by interfaces. >> >> >> >> I was looking for a way to automate (when appropriate) the serialization >> (both ways) of a backing entity in the entry.content atom field. >> >> >> >> Any recommendations? >> >> >> >> I was thinking of using something like XStream� Does Abdera provides >> internal support for this, something working hand in hand with FOMEntry? >> >> >> >> Thanks! >> >> >> >> Remy >> >> >> No virus found in this outgoing message. >> Checked by AVG Free Edition. Version: 7.5.516 / Virus Database: >> 269.21.1/1302 - Release Date: 2008.02.27 >> 16:34 >> >> >> No virus found in this incoming message. >> Checked by AVG Free Edition. Version: 7.5.516 / Virus Database: >> 269.21.1/1302 - Release Date: 2008.02.27 >> 16:34 >> >> >> No virus found in this outgoing message. >> Checked by AVG Free Edition. Version: 7.5.516 / Virus Database: >> 269.21.1/1302 - Release Date: 2008.02.27 >> 16:34 >> >> >> > > -- Dan Diephouse MuleSource http://mulesource.com | http://netzooid.com