public Object getStreamObject() throws IOException {

        Object o = getToken();
        if (o instanceof String) {
            if (o.equals("<<")) {
                Hashtable h = new Hashtable();
                Object o1 = getStreamObject();
                while (!o1.equals(">>")) {
                    h.put(o1, getStreamObject());
                    o1 = getStreamObject();
                }
                o = h;
            }
            // arrays are only used for CID mappings, the hex decoding is delayed
            // as a result using the CID_STREAM flag
            else if (o.equals("[")) {
                Vector v = new Vector();
                Object o1 = getStreamObject();
                while (!o1.equals("]")) {
                    v.addElement(o1);
                    o1 = getStreamObject();
                }
                v.trimToSize();
                o = v;
            }
        }
        //System.err.println("GET=" + o + " - " + o.getClass().getName());
        return o;
    }