[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Java code example of transforming via SAX with JAX

Subject: RE: Java code example of transforming via SAX with JAXP1.1?
From: David Nelson <David.Nelson@xxxxxxxxxxxxxx>
Date: Thu, 20 Jun 2002 07:21:26 -0500
jax sax
Yes but I believe the error listed is caused by configuration issues, not
code.  

-->  -----Original Message-----
-->  From: Andrew Welch [mailto:awelch@xxxxxxxxxxxxxxx]
-->  Sent: Thursday, June 20, 2002 2:56 AM
-->  To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
-->  Subject: RE:  Java code example of transforming via SAX with
-->  JAXP1.1?
-->  
-->  
-->  
-->  Wasn't the original request about SAX parsing??
-->  
-->  (for help on what all this means visit http://www.saxproject.org )
-->  
-->  import java.io.*;
-->  import org.xml.sax.*;
-->  import org.xml.sax.helpers.DefaultHandler;
-->  import javax.xml.parsers.SAXParserFactory;
-->  import javax.xml.parsers.ParserConfigurationException;
-->  import javax.xml.parsers.SAXParser;
-->  import com.icl.saxon.*;
-->  
-->  public class ASaxParser extends DefaultHandler {
-->     
-->      private String currentElement_ = null;
-->      private StringBuffer currentContent_ = null;
-->      private Attributes currentAtts_ = null;
-->      
-->      public void getFile(String path) {
-->          SAXParserFactory factory = SAXParserFactory.newInstance();
-->          try {
-->              SAXParser saxParser = factory.newSAXParser();
-->              saxParser.parse( new File(path), this );
-->  
-->          } catch (Throwable t) {
-->              t.printStackTrace();
-->          }
-->      }
-->      
-->      public void startDocument()
-->      {
-->      }
-->  
-->      public void endDocument()
-->      {
-->      }
-->    
-->      public void startElement(String uri, String name,String qName,
-->  Attributes atts)
-->      {
-->      }
-->  
-->      public void endElement(String uri, String name, String qName) 
-->      {
-->      }
-->   }
-->  
-->  ---
-->  Outgoing mail is certified Virus Free.
-->  Checked by AVG anti-virus system (http://www.grisoft.com).
-->  Version: 6.0.350 / Virus Database: 196 - Release Date: 17/04/2002
-->   
-->  
-->   XSL-List info and archive:  
-->  http://www.mulberrytech.com/xsl/xsl-list
-->  

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.