-
Notifications
You must be signed in to change notification settings - Fork 454
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
[Bernard Wan De Yuan] iP #461
Open
bernardwan
wants to merge
40
commits into
nus-cs2103-AY2122S1:master
Choose a base branch
from
bernardwan:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit
Hold shift + click to select a range
d839859
Add Gradle support
f38a22a
Level-1
bernardwan b98c16f
Level-2
bernardwan feac61e
Level-3
bernardwan 83381b8
Level-4
bernardwan 3c1011c
Added automated text UI testing
bernardwan 7551481
Implemented Level-5, updated test cases
bernardwan 2565300
Implemented Level-6. updated tests
bernardwan 5ff4233
Implemented Level-7
bernardwan 0266c78
Implemented Level-8
bernardwan 33921a6
Merge branch 'branch-Level-8'
bernardwan 48d97f1
Updated tests
bernardwan 09721a2
Resolved conflict errors
bernardwan e4d0342
Refactor code to make it more OOP
bernardwan c3e9b99
Organise into package
bernardwan 6db07e9
Add Junit tests
bernardwan fe6833c
Create JAR File
bernardwan 5f6bf33
Add Javadocs
bernardwan 9dbf7dd
Tweak code to follow coding standard
bernardwan 06609b4
Implement Level-9 Find feature
bernardwan d093898
Merge branch 'branch-A-CodingStandard'
bernardwan d2d6805
Merge branch 'branch-Level-9'
bernardwan bcefd1c
Fix minor javadocs errors
bernardwan 679bfa8
Merge remote-tracking branch 'origin/add-gradle-support'
bernardwan 341051c
Add Gradle to project
bernardwan 5dcd832
Add ability to use checkstyle
bernardwan 62293f6
Add GUI
bernardwan c786acd
Modify config for proper Gradle usage
bernardwan 9d41498
Add Assert statements
bernardwan e710891
Check code for code quality and clean up code
bernardwan f787e9d
Merge pull request #1 from bernardwan/branch-A-Assertions
bernardwan 879b551
Merge branch 'master' into branch-A-CodeQuality
bernardwan 558ea60
Merge pull request #2 from bernardwan/branch-A-CodeQuality
bernardwan fceed2d
Implement B-DoWithinPeriodTasks
bernardwan fd12c10
Refactor code
bernardwan a57ca3c
Add User Guide
bernardwan d45e077
Rename boolean variable
bernardwan 6e830cf
Improve GUI
bernardwan 4714d9b
Handle some exceptions and change font
bernardwan 0d11fb8
Update README.md
bernardwan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
package duke.Command; | ||
|
||
import duke.Command.Command; | ||
import duke.Storage; | ||
import duke.TaskList; | ||
import duke.Ui; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package duke.Command; | ||
|
||
import duke.*; | ||
|
||
import java.util.ArrayList; | ||
|
||
public class FindCommand extends Command{ | ||
String keyword; | ||
|
||
public FindCommand(String keyword) { | ||
this.keyword = keyword; | ||
} | ||
|
||
@Override | ||
public void execute(TaskList tasks, Ui ui, Storage storage) throws DukeException { | ||
ArrayList<Task> list = tasks.getList(); | ||
list.removeIf(task -> !task.getDescription().contains(this.keyword)); | ||
if (list.size() == 0) { | ||
ui.print("No matching tasks found."); | ||
} else { | ||
ui.print(list.size() + " matching task(s):"); | ||
ui.print(new TaskList(list).allTasks()); | ||
} | ||
} | ||
|
||
@Override | ||
public boolean isExit() { | ||
return false; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think you should import package by package, for example
import duke.TaskList
rather than usingimport duke.*