Thanks for the reply Erik. However, my follow up question is this:
What about the block of code that appears in the startElement() method:
if(atts.getLength()>0){
attributeMap=new HashMap();
Do we need to modify it at all in anyway? Your suggestion works, but isn't
this redundant?
Fayyaz - that is the incorrect action to take. That will cause
future documents to have fields from all previous ones! All you
have to do is:
private HashMap attributeMap = new HashMap();
Erik
On Dec 6, 2007, at 9:53 PM, syedfa wrote:
Thanks very much for your reply. I co
Thanks very much for your reply. I commented out the line:
attributeMap.clear();
in the startElement() method, and the code ran!
Thanks for your prompt reply, and my apologies for the delay in responding.
All the best.
Fayyaz
Michael McCandless-2 wrote:
>
>
> I think you need to initial
I'll give it a try. I would be surprised if that is the problem, since the
code is straight from the book. Let's see what happens.
Fayyaz
Michael McCandless-2 wrote:
>
>
> I think you need to initialize attributeMap, eg add " = new HashMap()" in
> the declaration?
>
> Mike
>
> "syedfa"
I think you need to initialize attributeMap, eg add " = new HashMap()" in
the declaration?
Mike
"syedfa" <[EMAIL PROTECTED]> wrote:
>
> Dear Fellow Java & Lucene developers:
>
> I am a Java developer learning lucene and I am currently going through the
> book Lucene in Action. At present, I a