package seedu.ezdo.logic.commands;

import java.util.Set;

/**
 * Finds and lists all tasks in ezDo whose name contains any of the argument keywords.
 * Keyword matching is case sensitive.
 */
public class FindCommand extends Command {

    public static final String COMMAND_WORD = "find";
    public static final String SHORT_COMMAND_WORD = "f";

    public static final String MESSAGE_USAGE = COMMAND_WORD + ": Finds all tasks whose names contain any of "
            + "the specified keywords (case-sensitive) and displays them as a list with index numbers.\n"
            + "Parameters: KEYWORD [MORE_KEYWORDS]...\n"
            + "Example: " + COMMAND_WORD + " buy milk clean";

    private final Set<String> keywords;

    public FindCommand(Set<String> keywords) {
        this.keywords = keywords;
    }

    @Override
    public CommandResult execute() {
        model.updateFilteredTaskList(keywords);
        return new CommandResult(getMessageForTaskListShownSummary(model.getFilteredTaskList().size()));
    }

}

@@ -46,19 +46,203 @@
 va.util.
-Set
+Optional;%0Aimport java.util.Set;%0A%0Aimport seedu.ezdo.model.todo.DueDate;%0Aimport seedu.ezdo.model.todo.Priority;%0Aimport seedu.ezdo.model.todo.StartDate;%0Aimport seedu.ezdo.model.todo.TaskDate
 ;%0A%0A/**%0A 
@@ -858,16 +858,20 @@
 lk clean
+ p/3
 %22;%0A%0A    
@@ -910,88 +910,637 @@
 ds;%0A
-%0A    public FindCommand(Set%3CString%3E keywords) %7B%0A        this.keywords = keywords
+    private final Optional%3CPriority%3E priorityToMatch;%0A    private final Optional%3CTaskDate%3E startDateToMatch;%0A    private final Optional%3CTaskDate%3E dueDateToMatch;%0A    private final Set%3CString%3E tagsToMatch;%0A    %0A    public FindCommand(Set%3CString%3E keywords, Optional%3CPriority%3E priorityToMatch,%0A                       Optional%3CTaskDate%3E startDateToMatch, Optional%3CTaskDate%3E dueDateToMatch, Set%3CString%3E tagsToMatch) %7B%0A        this.keywords = keywords;%0A        this.priorityToMatch = priorityToMatch;%0A        this.startDateToMatch = startDateToMatch;%0A        this.dueDateToMatch = dueDateToMatch;%0A        this.tagsToMatch = tagsToMatch
 ;%0A  
@@ -1640,16 +1640,80 @@
 keywords
+, priorityToMatch, startDateToMatch, dueDateToMatch, tagsToMatch
 );%0A     

Update FindCommand to find multiple fields