-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code quality tweaks #12
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Few points
|
||
public long getLowestEndTime() { | ||
return lowestEndTime; | ||
return soonestEndTime; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to do something with result here
private float remainder; | ||
public long soonestEndTime; | ||
public Map<String, Float> regenValue = new HashMap<>(); | ||
public Map<String, Long> regenEndTime = new HashMap<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you can find a way, make this a map sorted on the long
value. It will greatly improve performance because at present to find min, & to remove below a specific amount then you can quickly and easily do this. It does make removing by id harder, but this is not as often needed.
Closing as superseded by #16, which is now merged 👍 |
Remove logs and unused events.
Update tests for regeneration