Bug 17779 - [PATCH] null should mean "all records" and NOT "all known records"
Summary: [PATCH] null should mean "all records" and NOT "all known records"
Status: RESOLVED INVALID
Alias: None
Product: POI
Classification: Unclassified
Component: HSSF (show other bugs)
Version: unspecified
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-03-07 17:23 UTC by Csaba
Modified: 2004-11-16 19:05 UTC (History)
0 users



Attachments
implementation proposal (1.49 KB, patch)
2003-03-07 18:00 UTC, Csaba
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Csaba 2003-03-07 17:23:18 UTC
The HSSF event model is filtering out any unknown records unless the listener is
explicitly registered to receive all record sids it wants to pass through... the
null parameter for record sids to be processed will default to the list of known
records.

In my opinion this is not the best behavior, as there's no way to specify "pass
through all records, even if unknown". The current behavior ("pass through all
known records") can be achieved easily by passing
EventRecordFactory.getAllKnownRecordSIDs() when registering the filter.

My proposal is just pass through all records if the list of sids is null.

I'm aware that this might brake some existing applications which rely on the
current behavior, causing them to potentially receive unknown records, but they
are easily fixed by passing EventRecordFactory.getAllKnownRecordSIDs() instead
of null.
(Not to mention that some of the applications will suddenly work better by
keeping images and the like :)
Comment 1 Csaba 2003-03-07 18:00:18 UTC
Created attachment 5214 [details]
implementation proposal
Comment 2 Csaba 2003-03-07 18:00:42 UTC
The code change is minimal to implement this.
I've added a patch.
The tests are running, had no time to add a test case for this one.
Comment 3 Andy Oliver 2003-04-11 02:47:02 UTC
I don't mind it if both behaviors are provided.  however I don't much care for
just changing the behavior.  I think this should be done but I'd rather reject
this and hope a more complete patch is submitted prefferably with a unit test.