Java Mozilla Html Parser
http://sourceforge.net/projects/mozillaparser
| Home |  Sourceforge |  Dapper | Contact Us |



Links
    Home
 Download
 Quick Start
  Features   TODO
  Contact
 
 

News
 

21/1/2008

   Mozilla Java Html Parser   v.0.2.0 released

 

 
 
SourceForge.net Logo
Quick Start

Four (more or less) easy steps to integrate Mozilla parser into your code :

  1. Download And include the source code

  2. Insert both the dist/bin and the dist/bin/components directories to the right enviroment variable.

    On windows it is PATH variable and you can manipulate it threw Start->ControlPanel->System->Advanced->Enviroment Vairables

    On Linux you should add it to LD_LIBRARY_PATH
    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/path/to/dist/bin:/path/to/dist/bin/components

    On MacOSX you should add it to DYLD_LIBRARY_PATH
    export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/path/to/dist/bin:/path/to/dist/bin/components 

    I know it's a pain , but it's the only way I managed to do it. if someone happens to be smarter than I , please send me a note.

  3. include this code in your code. You can find it on com.dappit.Dapper.parser.example.ParserExample :

    File parserLibraryFile = new File("./native/bin/MozillaParser" + EnviromentController.getSharedLibraryExtension());
    String parseLibrary = parserLibraryFile.getAbsolutePath();
    MozillaParser.init(parseLibrary, "C:\\dapper\\mozilla\\dist\\bin");
    Document domDocument = MozillaParser.getInstance().parse("<html>Hello world!</html>");
    MozillaParser.getInstance().stopRunning();


  4. You can include junit into your jars and run the Unit test for checks (TestMozillaParser)

 


Contact Ohad Serfaty at ohad@dapper.net