Lucene++ - a full-featured, c++ search engine
API Documentation


Loading...
Searching...
No Matches
ReusableStringReader.h
Go to the documentation of this file.
1
2// Copyright (c) 2009-2014 Alan Wright. All rights reserved.
3// Distributable under the terms of either the Apache License (Version 2.0)
4// or the GNU Lesser General Public License.
6
7#ifndef REUSABLESTRINGREADER_H
8#define REUSABLESTRINGREADER_H
9
10#include "Reader.h"
11
12namespace Lucene {
13
17public:
20
22
23public:
24 int32_t upto;
25 int32_t left;
26 String s;
27
28public:
29 virtual void init(const String& s);
30
31 using Reader::read;
32
34 virtual int32_t read(wchar_t* buffer, int32_t offset, int32_t length);
35
37 virtual void close();
38};
39
40}
41
42#endif
#define LUCENE_CLASS(Name)
Definition LuceneObject.h:24
Abstract class for reading character streams.
Definition Reader.h:15
virtual int32_t read()
Read a single character.
virtual int64_t length()
The number of bytes in the stream.
Used by DocumentsWriter to implemented a StringReader that can be reset to a new string; we use this ...
Definition ReusableStringReader.h:16
virtual int32_t read(wchar_t *buffer, int32_t offset, int32_t length)
Read characters into a portion of an array.
virtual void init(const String &s)
int32_t upto
Definition ReusableStringReader.h:24
int32_t left
Definition ReusableStringReader.h:25
String s
Definition ReusableStringReader.h:26
virtual void close()
Close the stream.
Definition AbstractAllTermDocs.h:12

clucene.sourceforge.net