Package net.sf.jpluck.test

Source Code of net.sf.jpluck.test.BookmarkTest

package net.sf.jpluck.test;

import java.io.File;

import net.sf.jpluck.plucker.Document;
import net.sf.jpluck.plucker.TextRecord;

public class BookmarkTest {

  public static void main(String[] args) throws Exception {
    Document document = new Document("Bookmark Test");
    for (int i = 1; i <= 10; i++) {
      String uri = "page" + i;
      TextRecord page = new TextRecord(uri);
      String name = "Page " + i;
      page.addParagraph().addFontH1().addText(name).addAnchor("anchor");
     
      document.addBookmark(name, uri + "#anchor");
      document.addRecord(page);
    }
    document.setIncludeURIInfo(true);
    document.setHome("page1");
    document.write(new File(args[0]));   
  }
}
TOP

Related Classes of net.sf.jpluck.test.BookmarkTest

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.