abdera-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James M Snell <jasn...@gmail.com>
Subject Re: JSON writer not serializing entry links. Bug???
Date Thu, 04 Jan 2007 18:48:02 GMT
Elias wrote that code.  Unfortunately he's out on vacation right now
(sunning on a beach in Ecuador).  If I get some time I'll look at this
either this weekend or early next week.

- James

Yogesh Mujumdar wrote:
> Sample Entry XML :
> 
> <entry xmlns="http://www.w3.org/2005/Atom">
> <updated>2007-01-03T14:12:39.154Z</updated>
> <link
> href="http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf"
> rel="edit-media" />
> <id>urn:http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf</id>
> 
> <content src="
> http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf"
> type="application/pdf" />
> <link href="
> http://fooserver/MyMedia/media-gmail_image_test...._1167833330445.pdf.proxy"
> 
> rel="edit" />
> <title type="text">gmail_image_test....</title>
> <summary type="text">foo bar ggggggg</summary>
> <category term="draft" />
> <author><name>yogesh</name></author>
> </entry>
> 
> 
> Code :
> 
>        Abdera abdera = new Abdera();
>        InputStream ein = abtest.class.getResourceAsStream("./entry.xml");
>        Document doc = abdera.getParser().parse(ein);
>        Entry entry = (Entry)doc.getRoot();
>        System.out.println(entry + "\n\n\n");
>        Writer pw = abdera.getWriterFactory().getWriter("json");
>        pw.writeTo(entry, System.out);
> 
> 
> Output :
> 
> Buildfile: build.xml
> 
> clean:
>   [delete] DEPRECATED - Use of the implicit FileSet is deprecated.  Use a
> nested fileset element instead.
>   [delete] Deleting 2 files from
> E:\ScratchDisk\TestingCodebase\Abdera\build
>   [delete] DEPRECATED - Use of the implicit FileSet is deprecated.  Use a
> nested fileset element instead.
> 
> compile:
>    [javac] Compiling 1 source file to
> E:\ScratchDisk\TestingCodebase\Abdera\build
> 
> dist:
>      [jar] Building jar:
> E:\ScratchDisk\TestingCodebase\Abdera\build\abdera-test.jar
> 
> run:
>     [java] <entry xmlns="http://www.w3.org/2005/Atom
> "><updated>2007-01-03T14:12:39.154Z</updated><link href="
> http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf"
> rel="edit-media" /><id>urn:
> http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf</id><content
> 
> src="http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf"
> type="application/pdf" /><link href="
> http://fooserver/MyMedia/media-gmail_image_test...._1167833330445.pdf.proxy"
> 
> rel="edit" /><title type="text">gmail_image_test....</title><summary
> type="text">foo bar ggggggg</summary><category term="draft"
> /><author><name>yogesh</name></author></entry>
> 
> 
> 
>     [java] {"summary":"foo bar
> ggggggg","contributors":[],"title":"gmail_image_test....","content":{"value":"\"\"","type":"application/pdf"},"categories":[{"term":"draft"}],"authors":[{"name":"yogesh"}],"updated":"Wed
> 
> Jan 03 19:42:39 GMT+05:30 2007","id":"urn:
> http://fooserver/MyMedia/gmail_image_test...._1167833330445.pdf","links":[]}
> 
> 
> BUILD SUCCESSFUL
> Total time: 10 seconds
> 
> 

Mime
View raw message