Package factbookxml.converter.schema

Examples of factbookxml.converter.schema.AppendixList


          pivotCells[row][col][1] = cellRow[3];
          pivotCells[row][col][2] = cellRow[4];
        }
        int tableColumns = Integer.parseInt(tableRow[3]);
        if (tableColumns == 0) { // list
          AppendixList lst = new AppendixList();
          appendix.setList(lst);
          if (tableRow[1].equals("1"))
            lst.setLettergrouped(1);
          for (int i = 1; i < pivotCells.length; i++) {
            AppendixList.Entry e = new AppendixList.Entry();
            lst.getEntry().add(e);
            e.setName(pivotCells[i][0][0]);
            e.setValue(parseAppendixListEntryValue(pivotCells[i][1][0]));
          }
        } else { // table
          AppendixTable tbl = new AppendixTable();
View Full Code Here


    Table cellTable = new Table("appendixcells", "tableid", "row", "column", "value", "center", "country");

    for (Factbook.Appendix app : doc.getAppendix()) {
      int appendixId = appendixTable.insert(app.getLetter(), html(app.getName()));
      // list
      AppendixList lst = app.getList();
      {
        int tableId = tableTable.insert("" + appendixId, lst.getLettergrouped() == null ? "0" : "1", "", "0");
        int row = 0;
        for (AppendixList.Entry entry : lst.getEntry()) {
          StringBuilder sb = new StringBuilder();
          boolean written = false;
          for (Serializable content : entry.getValue().getContent())
          {
            if (content instanceof String) {
View Full Code Here

  }

  private void writeAppendix(String ltr, Factbook.Appendix app) throws Exception {
    System.out.println("  "+ltr.toUpperCase());
    BufferedWriter fw = openHTML("appendix-"+ltr+".html", "Appendix "+ltr.toUpperCase(), "Appendix "+ltr.toUpperCase()+": "+app.getName());
    AppendixList lst =app.getList();
    boolean lettergrouped = lst.getLettergrouped() != null;
    if (lettergrouped) {
      for(char i='A'; i<='Z'; i++) {
        fw.write(" <a href=\"#"+mkid(fw,"lst"+i)+"\">"+i+"</a>");
      }
    }
    char current = '@';
    boolean indl = false;
    for(AppendixList.Entry entry: lst.getEntry()) {
      char firstchar = entry.getName().length() == 0 ? ' ' : entry.getName().toUpperCase().charAt(0);
      while (lettergrouped && firstchar > current) {
        if (indl)
        {
          fw.write("</dl>");
View Full Code Here

TOP

Related Classes of factbookxml.converter.schema.AppendixList

Copyright © 2018 www.massapicom. 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.