abdera-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bryon Jacob <br...@jacobtx.net>
Subject Re: Non-standard elements in Atom
Date Fri, 27 Feb 2009 20:04:58 GMT
Johnny -

What you want to do is supported, but you will need to put the  
elements into a different namespace (since there is no <summary>  
element on a <feed> element in the http://www.w3.org/2005/Atom  

Your XML will look something like:

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:tolliver="http://johnny.tollivers.namespace.url

    <title type="text">title goes here...</title>
    <tolliver:summary>Here's your Summary Element</tolliver:summary>
       ... you get the drift from here ...

The Abdera API supports this nicely - you would do something like the  
above as follows:

    Feed feed = getMyFeedObjectSomehow();
    QName summaryQName = new QName("http://johnny.tollivers.namespace.url 
", "summary", "tolliver");
    feed.addSimpleExtension(summaryQName, "Here's your Summary  

if you needed a richer structure to an extension, Abdera supports  
that, too - but it's a bit more coding.

  - Bryon

On Feb 27, 2009, at 1:17 PM, Johnny Tolliver wrote:

> Hi! I'm new to Abdera and the mailing list and have just one question.
> I need to be able to build an Atom document that has some extra non- 
> standard elements in it. For example, in addition to <title> and  
> <subtitle> for a <feed>, I need to add a <summary> element. The name
> <summary> was chosen to match the <summary> that's available in an  
> <entry>, but I need it at the <feed> level in addition to the  
> entries. Similarly, I need a <subtitle> and a <published> in an  
> <entry>.
> Is that usage supported in Abdera? Perhaps in the extension mechanism?
> Thanks,
> Johnny Tolliver
> tolliver@ornl.gov
> 865-574-1305

View raw message