Releases: point85/Shift
Work Schedule Library
- By Claude Sonnet 4.5
Bugs Fixed:
Named.java - Fixed equals/hashCode contract violation
Changed equals() to use Objects.equals() for proper null handling
Changed hashCode() to use Objects.hash() for consistency
Fixed toString() to handle null description gracefully
RotationSegment.java - Added null safety checks
Added defensive null checks before calling getName() on rotation and shift to prevent NullPointerException
ShiftInstance.java - Added null safety checks
Added defensive null checks in equals() method to prevent NullPointerException
Performance Improvements:
Team.java - Optimized cache synchronization
Replaced ConcurrentHashMap with HashMap since the method is already synchronized
Improved cache initialization logic to avoid unnecessary clear operations
Optimized string concatenation in toString() methods (replaced += with StringBuilder)
Work schedule library
- Fix WorkSchedule.deleteShift() bug
- Team.calculateWorkingTime() calls minusDays(1), remove member exception method, build cache synch
- Rotation: invalidate cache
- Use isZero() in NonWorkingPeriod.setDuration()
- Shift Instance: use equals()
- TeamMemberException: add equals() and hashcode() methods
Work Schedule Library
Added members for a team and exceptions for assigned personel
Java Work Schedule Library
- Created a Maven repository at org.point85.workschedule:
- Upgraded hamcrest to 2.2
- Removed unused Maven dependencies
Work Schedule Library
Removed JavaFX test code
Upgraded to Java 11
Upgraded slf4j to version 1.7.26
Upgraded junit to version 4.13.2
Work schedule library
Changed to HSQL test database
Code changes as per SonarLint recommendations
Work schedule library
Added a method to get all shift instances with working time in a given day.
Work schedule library
- Converted to a Maven project only
- Added a bi-directional relationship between WorkSchedule and Rotation
- Upgraded to JPA version 2.2
Stable work schedule library
Java work schedule library