-
Notifications
You must be signed in to change notification settings - Fork 5
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
Supports creating and deleting of multiple tags within one user input #37
Supports creating and deleting of multiple tags within one user input #37
Conversation
Updated CreateTagCommand and DeleteTagCommand to support creating and deleting of multiple tags within 1 instruction. Added new enum to SystemException to handle more specific missing information. Restructured the handling of exception in the prepare functions to return SystemException and catch them within the parseCommand function.
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.
Looks good, apart from some minor changes!
private int index; | ||
private String tagName; | ||
private String tagColor; | ||
private final int index; |
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.
Private final right, so should be all CAPS? Can just commit directly from my suggestion :D
private final int index; | |
private final int INDEX; |
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.
The intellji gave warning saying that the field may be final so I changed it. Will be reverting that since the int cannot be final. Likewise for the rest of the similar cases below
private String tagName; | ||
private String tagColor; | ||
private final int index; | ||
private final ArrayList<Tag> tags; |
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.
Same as above
private final ArrayList<Tag> tags; | |
private final ArrayList<Tag> TAGS; |
private static final String STRING_TAG_EMPTY = "There are no tags!"; | ||
private static final String STRING_TAG_LIST = "Here are the available tags:" + InterfaceManager.LS; | ||
|
||
private final Map<Tag, ArrayList<Note>> tagMap; |
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.
Should it be TAGMAP?
private final Map<Tag, ArrayList<Note>> tagMap; | |
private final Map<Tag, ArrayList<Note>> TAGMAP; |
Co-authored-by: R Ramana <54029207+R-Ramana@users.noreply.github.com>
… into JunXiang-branch-TagNote # Conflicts: # src/main/java/seedu/duke/data/notebook/Tag.java
# Conflicts: # src/main/java/seedu/duke/data/notebook/TagManager.java # src/main/java/seedu/duke/util/Parser.java # text-ui-test/EXPECTED.TXT Did some clean up of the code. Added more SystemException. Modified some of the prepare functions in parser to throw SystemException.
*Refactored prepareCreateTag and prepareDeleteTag into one function
*Created function to process TAG message
*Added more SystemException for specific missing information
*Modified the prepare functions to throw a SystemException, which is to be catched in the parseCommand function for the various missing information
*Included JColor library to support printing colored fonts
Closes #26
Closes #19