Package it.unimi.dsi.fastutil.io

Examples of it.unimi.dsi.fastutil.io.FastBufferedInputStream.position()


          if ( DEBUG ) LOGGER.debug( "Setting markers <" + currStart + "," + currInter + ", " + currStop + ">" );
          descriptors.add( new TRECDocumentDescriptor( fileIndex, currStart, currInter, currStop ) );
          startedBlock = pastHeader = false;
        }
        else if ( startedBlock && !pastHeader && equals( buffer, l, DOCHDR_CLOSE ) ) {
          currInter = fbis.position();
          pastHeader = true;
        }
        oldPos = fbis.position();
      }
    }
View Full Code Here


        }
        else if ( startedBlock && !pastHeader && equals( buffer, l, DOCHDR_CLOSE ) ) {
          currInter = fbis.position();
          pastHeader = true;
        }
        oldPos = fbis.position();
      }
    }

    fbis.close();
  }
View Full Code Here

    for( String f : file ) {
      p.clear();
      final FastBufferedInputStream fbis = gzipped ? new FastBufferedInputStream( new GZIPInputStream( new FileInputStream( f ) ) ) : new FastBufferedInputStream( new FileInputStream( f ) );
      long position;
      for(;;) {
        position = fbis.position();
        if ( readLine( fbis ) == -1 ) break;
        if ( startsWith( lineBuffer, DOC_MARKER ) ) p.add( position );
        if ( phrase && startsWith( lineBuffer, SENTENCE_MARKER ) ) p.add( position );
      }
     
View Full Code Here

        if ( startsWith( lineBuffer, DOC_MARKER ) ) p.add( position );
        if ( phrase && startsWith( lineBuffer, SENTENCE_MARKER ) ) p.add( position );
      }
     
      count += p.size();
      p.add( fbis.position() );
      fbis.close();
     
      pointers.add( new EliasFanoMonotoneLongBigList( p ) );
      firstDocument[ pointers.size() ] = count;
     
View Full Code Here

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.