public void startElement(String name, Attributes atts)
    {
        try
        {
            // pretty-print if applicable
            if (prettyPrint_)
                indent();

            // write <
            out_.write('<');

            // write element's name
            out_.write(name, 0, name.length());

            // write element's attributes, if any
            if(atts != null)
                for(int i=0; i<atts.getLength(); i++){
                	out_.write(" "+atts.getName(i)+"=\""+atts.getValue(i)+"\"");
                }

            // write >
            out_.write('>');

            // pretty-print if applicable
            if (prettyPrint_)
            {
                out_.newLine();
                indentLevel_++;
            }
        }
        catch (IOException E)
        {
            throw new RuntimeException("Error: I/O error " + E.getMessage());
        }
    }