Java Parser

Discussion in 'XML' started by John Bokma, Aug 7, 2003.

  1. John Bokma

    John Bokma Guest

    Frank wrote:

    > I am looking for a reccomendation as to what Java parser I should be
    > using. I'm looking for something that is freely distributed, has
    > documentation, and has a wide user base. Any suggestions?


    Have a look at: http://xml.apache.org/

    John

    --
    email: mail(at)johnbokma.com (or reply) home: http://johnbokma.com/
    Web site hints: http://johnbokma.com/websitedesign/ ~ ICQ 218175426
     
    John Bokma, Aug 7, 2003
    #1
    1. Advertising

  2. John Bokma

    Frank Guest

    I am looking for a reccomendation as to what Java parser I should be
    using. I'm looking for something that is freely distributed, has
    documentation, and has a wide user base. Any suggestions?
     
    Frank, Aug 7, 2003
    #2
    1. Advertising

  3. In article <3f32a153$0$186$>,
    John Bokma <> wrote:

    :> Frank wrote:
    :>
    :> > I am looking for a reccomendation as to what Java parser I should be
    :> > using. I'm looking for something that is freely distributed, has
    :> > documentation, and has a wide user base. Any suggestions?
    :>
    :> Have a look at: http://xml.apache.org/
    :>
    :> John

    And don't overlook the fact that a major portion of what was the
    Xerces-J parser has now been incorporated into Sun's Java.

    = Steve =
    --
    Steve W. Jackson
    Montgomery, Alabama
     
    Steve W. Jackson, Aug 7, 2003
    #3
  4. John Bokma

    John Bokma Guest

    Steve W. Jackson wrote:

    > In article <3f32a153$0$186$>,
    > John Bokma <> wrote:
    >
    > :> Frank wrote:
    > :>
    > :> > I am looking for a reccomendation as to what Java parser I should be
    > :> > using. I'm looking for something that is freely distributed, has
    > :> > documentation, and has a wide user base. Any suggestions?
    > :>
    > :> Have a look at: http://xml.apache.org/
    > :>
    > :> John
    >
    > And don't overlook the fact that a major portion of what was the
    > Xerces-J parser has now been incorporated into Sun's Java.


    Thanks Steve, didn't know that.

    John

    --
    email: mail(at)johnbokma.com (or reply) home: http://johnbokma.com/
    Web site hints: http://johnbokma.com/websitedesign/ ~ ICQ 218175426
     
    John Bokma, Aug 7, 2003
    #4
  5. John Bokma

    Frank Guest

    On Thu, 07 Aug 2003 12:48:18 -0700, Frank <> wrote:

    >I am looking for a reccomendation as to what Java parser I should be
    >using. I'm looking for something that is freely distributed, has
    >documentation, and has a wide user base. Any suggestions?


    Thany you both. I'm installing Xerces. That looks like it will meet
    my needs.
     
    Frank, Aug 8, 2003
    #5
  6. John Bokma

    woo hoo Guest

    I am using Xerces2 2.5. I am trying to validate my xml with
    schemas. Does anyone have any idea how to do this. My relevant code
    is:


    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;

    import org.apache.xerces.jaxp.DocumentBuilderFactoryImpl;

    import .....

    class foo {
    public void loadXML(URL url) throws
    ParserConfigurationException, SAXException, IOException {

    DocumentBuilder builder;

    DocumentBuilderFactory factory =
    DocumentBuilderFactoryImpl.newInstance();

    factory.isIgnoringElementContentWhitespace();

    factory.isValidating();

    builder = factory.newDocumentBuilder();

    Document document = builder.parse(url.toString());
    // Do stuff with DOM here...
    }

    // etc.
    }


    thanks alot
     
    woo hoo, Nov 8, 2003
    #6
  7. John Bokma

    woo hoo Guest

    never mind.. dur!!!!

    I am using Xerces2 2.5. I am trying to validate my xml with
    schemas. Does anyone have any idea how to do this. My relevant code
    is:


    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;

    import org.apache.xerces.jaxp.DocumentBuilderFactoryImpl;

    import .....

    class foo {
    public void loadXML(URL url) throws
    ParserConfigurationException, SAXException, IOException {

    DocumentBuilder builder;

    DocumentBuilderFactory factory =
    DocumentBuilderFactoryImpl.newInstance();

    factory.isIgnoringElementContentWhitespace();

    factory.isValidating();

    builder = factory.newDocumentBuilder();

    Document document = builder.parse(url.toString());
    // Do stuff with DOM here...
    }

    // etc.
    }


    thanks alot
     
    woo hoo, Nov 8, 2003
    #7
  8. Christian Ludwig, Nov 12, 2003
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Bernd Oninger
    Replies:
    0
    Views:
    772
    Bernd Oninger
    Jun 9, 2004
  2. ZOCOR

    XML Parser VS HTML Parser

    ZOCOR, Oct 3, 2004, in forum: Java
    Replies:
    11
    Views:
    832
    Paul King
    Oct 5, 2004
  3. Bernd Oninger
    Replies:
    0
    Views:
    829
    Bernd Oninger
    Jun 9, 2004
  4. Joel Hedlund
    Replies:
    2
    Views:
    522
    Joel Hedlund
    Nov 11, 2006
  5. Joel Hedlund
    Replies:
    0
    Views:
    314
    Joel Hedlund
    Nov 11, 2006
Loading...

Share This Page