abdera-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chad Lung <chad.l...@gmail.com>
Subject NullPointerException (FOMElement) with Abdera Entry to JSON example code
Date Thu, 25 Aug 2011 21:24:25 GMT
Using the Apache Abdera example for converting an Entry to JSON I'm seeing
the following error:

Exception in thread "main" java.lang.NullPointerException
    at org.apache.abdera.parser.stax.FOMElement.writeTo(FOMElement.java:315)
    at org.apache.abdera.parser.stax.FOMElement.writeTo(FOMElement.java:793)

This happens in the call to: entry.writeTo("json", System.out);

Is this a known issue currently?

Source code I'm using:

import java.io.IOException;
import org.apache.abdera.Abdera;
import org.apache.abdera.model.Entry;

public class App
    public static void main( String[] args )
        Abdera abdera = new Abdera();
        Entry entry = abdera.newEntry();

        try {
            entry.writeTo("json", System.out);
        catch(IOException ioex) {
            System.out.println("IO Error: " + ioex.getMessage());

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message