package seedu.task.logic.commands;


//@@author A0127570H
/**
 * Abstract class to represent generic add operations.  
 * @author kian ming
 */

public abstract class AddCommand extends UndoableCommand {
    
    public static final String COMMAND_WORD = "add";
    public static final String MESSAGE_USAGE = COMMAND_WORD + "\n" 
    		+ "Adds a task or event to the task book.\n"
            + "The order of the parameters is flexible\n\n"
    		+ "Adding a task.\n"
            + "Parameters: TASK_NAME [/desc DESCRIPTION] [/by DEADLINE]\n"
    		+ "DEADLINE can be in words or MM-DD-YY\n"
            + "Example: " + COMMAND_WORD
            + " CS2103 Lab 6 /desc hand in through codecrunch /by tomorrow\n\n"
            + "Adding an event.\n"
            + "Parameters: EVENT_NAME [/desc DESCRIPTION] [/from START_DURATION] [/to END_DURATION]\n"
            + "DURATION can be in words or MM-DD-YY\n"
            + "Entering either one or both durations are accepted.\n"
            + "Duration is set to 1 hour at default if only one duration is entered.\n"
            + "Example: " + COMMAND_WORD
            + " CS2103 Workshop /desc OOP workshop /from tomorrow /to thursday\n"
            + "DURATION: Event is assumed to terminate on the same day if a single date is entered";
    
    /**
     * Executes the command and returns the result message.
     * @return feedback message of the operation result for display
     */
    public abstract CommandResult execute();
}

@@ -343,405 +343,231 @@
 s a 
-task or event to the task book.%5Cn%22%0A            + %22The order of the parameters is flexible%5Cn%5Cn%22%0A    %09%09+ %22Adding a task.%5Cn%22%0A            + %22Parameters: TASK_NAME %5B/desc DESCRIPTION%5D %5B/by DEADLINE%5D%5Cn%22%0A    %09%09+ %22DEADLINE can be in words or MM-DD-YY%5Cn%22%0A            + %22Example: %22 + COMMAND_WORD%0A            + %22 CS2103 Lab 6 /desc hand in through codecrunch /by tomorrow%5Cn%5Cn%22%0A            + %22Adding an event
+purchased stock to the stock manager.%5Cn%22%0A    %09%09+ %22If stock is existing, details will be integrated to the stock manager.%5Cn%22%0A            + %22The order of the parameters is flexible%5Cn%5Cn%22%0A    %09%09+ %22Adding a newly purchased stock
 .%5Cn%22
@@ -598,518 +598,238 @@
 rs: 
-EVENT
+STOCK
 _NAME 
-%5B
 /d
-esc DESCRIPTION%5D %5B/from START_DURATION%5D %5B/to END_DURATION%5D%5Cn%22%0A            + %22DURATION can be in words or MM-DD-YY%5Cn%22%0A            + %22Entering either one or both durations are accepted.%5Cn%22%0A            + %22Duration is set to 1 hour at default if only one duration is entered.%5Cn%22%0A            + %22Example: %22 + COMMAND_WORD%0A            + %22 CS2103 Workshop /desc OOP workshop /from tomorrow /to thursday%5Cn%22%0A            + %22DURATION: Event is assumed to terminate on the same day if a single date is entered
+ DATEOFPURCHASE /l NUMOFSHARES /p PURCHASE PRICE %5Cn%22%0A    %09%09+ %22DATEOFPURCHASE can be in words or MM-DD-YY%5Cn%22%0A            + %22Example: %22 + COMMAND_WORD%0A            + %22 DBS GROUP HOLDINGS LTD /l 1000 /p 23.05 /d today%5Cn%5Cn
 %22;%0A 

add command message