Closed davyrolink closed 6 years ago
Why do think it is a good idea to make that class extendable?
For a project I had different requirements for the consume method, so I wanted to extend the class and implement a custom consume method. But since the properties used in the consume method are private, it wasn't possible without making the properties protected.
Could you please be more specific, what requirement made it necessary to extends TokenBucket?
Making this class extendable means increasing the public API. That's a big impact on maintainability. So you need to convince me in doing so. I obviously forgot to make those classes final. I'm sorry for causing confusion here. The next major release will fix that.