Skip to content

A-CodeQuality

Choose a tag to compare

@WeeMee03 WeeMee03 released this 19 Sep 03:18
Improve code quality across Task hierarchy and core modules

Refactored Task, Todo, Deadline, and Event classes to enhance readability,
consistency, and maintainability. Key improvements include:

- Unified toString() and toSaveFormat() implementations across all task types
  to reduce code duplication and ensure consistent behavior.
- Standardized use of type.getCode() for task type identification instead of
  hardcoded strings.
- Preserved immutability for deadline and event time fields and improved
  assertion checks for safety.
- Retained and clarified Javadoc comments to improve code documentation.
- Improved method contracts and assertions to enforce valid state and
  input handling.

These changes improve overall code quality by enhancing clarity, reducing
redundancy, and making the codebase more maintainable and less error-prone.