Code example for ObjectInput

Methods: readByte, readObject

0
        } 
    } 
 
    public void readExternal(ObjectInput in) throws ClassNotFoundException,
            IOException { 
        if (in.readByte() != NULL) {
            events = (List) in.readObject();
        } 
    } 
 
    // SAXEvent inner class 
    // ------------------------------------------------------------------------- 
    static class SAXEvent implements Externalizable {
        public static final long serialVersionUID = 1;
 
        static final byte PROCESSING_INSTRUCTION = 1;
 
        static final byte START_PREFIX_MAPPING = 2;
 
        static final byte END_PREFIX_MAPPING = 3;