Package nz.govt.natlib.fx

Examples of nz.govt.natlib.fx.DataSource


    public void processPOIFSReaderEvent(POIFSReaderEvent event) {
      if (maskDone)
        return;

      DataSource ftk = null;
      try {
        long dopPos = into.getIntAttribute("Word.FIB.dopOffset");
        ftk = new DocumentDataSource(event.getStream());
        into.fireStartParseEvent("Properties");
        WordUtils.getDOPProperties(ftk, (int) dopPos, into);
        into.fireEndParseEvent("Properties");
      } catch (Exception ex) {
        ex.printStackTrace();
      } finally {
        if (ftk != null) {
          try {
            ftk.close();
          } catch (Exception ex) {
            ;
          }
        }
        maskDone = true;
View Full Code Here


    public MainStreamReader(ParserContext into) {
      this.into = into;
    }

    public void processPOIFSReaderEvent(POIFSReaderEvent event) {
      DataSource ftk = null;
      try {
        ftk = new DocumentDataSource(event.getStream());

        into.fireStartParseEvent("header");
        WordUtils.getHeader(ftk, into);
        into.fireEndParseEvent("header");

        FIB oFib = new FIB(langMap, Offset_To_DOP);
        into.fireStartParseEvent("FIB");
        oFib.read(ftk, into);
        into.fireEndParseEvent("FIB");

        // processText(oFib,ftk, into);
      } catch (Exception ex) {
        ex.printStackTrace();
      } finally {
        if (ftk != null) {
          try {
            ftk.close();
          } catch (Exception ex) {
            ;
          }
        }
      }
View Full Code Here

TOP

Related Classes of nz.govt.natlib.fx.DataSource

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.