views:

19

answers:

3

It's hard to search for something when you don't know what it's called.

I am buffering a stream of data points with a sort of switchable buffer (imagine a garden hose with a valve): in one state ("true"), I let the data points through to their eventual consumer. In the other state ("false"), I retain those data points in a queue until I transition to the other state, at which point I send those data points to their consumer in order.

Do you have any suggestions for what to name the boolean property that controls this state? I have thought about "on", "buffering", "closed", "delayed", etc and none of them make me particularly happy. I need to come up with a good name before I publish my class to potential "customers" (other programmers here). I can reverse the logic from true <-> false if it makes more semantic sense.

(edit: feel free to just refer to the property as a name without is/get in it. I'm using Java so it will be a Bean-style property with setXXX/isXXX accessors.)

(edit 2: it seems like the property name should, unless it's clearer to do otherwise, reflect the "true" state where data is being letting through transparently without delay.)

A: 
IsQueueBufferingEnabled

Or

IsDiverted

(which doesn't expose any implementation details)

Mitch Wheat
A: 

HoldBackData?

should reflect the "true" state where data is being letting through transparently without delay

So, floodGatesOpen ? :)

Paul
A: 

hmmm... I'm temporarily using paused, not entirely happy but it's the best I can come up with. (suspended is of similar quality)

Jason S