package edu.pdx.cs410J.chances;

import edu.pdx.cs410J.AbstractAppointmentBook;

/**
 * The main class for the CS410J appointment book Project
 */
public class Project1 {

  public static void main(String[] args) {
    Class c = AbstractAppointmentBook.class;  // Refer to one of Dave's classes so that we can be sure it is on the classpath
    System.err.println("Missing command line arguments");
    for (String arg : args) {
      System.out.println(arg);
    }
    System.exit(1);
  }

}

@@ -74,16 +74,65 @@
 tBook;%0A%0A
+import java.util.Arrays;%0Aimport java.util.List;%0A%0A
 /**%0A * T
@@ -265,278 +265,2116 @@
     
-Class c = AbstractAppointmentBook.class;  // Refer to one of Dave's classes so that we can be sure it is on the classpath%0A    System.err.println(%22Missing command line arguments%22);%0A    for (String arg : args) %7B%0A      System.out.println(arg);%0A    %7D%0A    System.exit(1);%0A  %7D%0A%0A%7D
+// Refer to one of Dave's classes so that we can be sure it is on the classpath%0A    Class c = AbstractAppointmentBook.class;%0A%0A    List%3CString%3E argsList = Arrays.asList(args);%0A%0A    // Print the README if flag is present%0A    if (argsList.contains(%22-README%22)) %7B%0A      System.out.println(%22Chance Snow - Project 1%5Cn%22 +%0A              %22%5CtAppointment Book Application%5Cn%5Cn%22 +%0A              %22Create an appointment in a new appointment book.%5Cn%22);%0A      System.out.print(%22usage: java edu.pdx.cs410J.chances.Project1 %5Boptions%5D %3Cargs%3E%5Cn%22 +%0A              %22%5Ctargs are (in this order):%5Cn%22 +%0A              %22%5Ct%5Ctowner The person whose owns the appt book%5Cn%22 +%0A              %22%5Ct%5Ctdescription A description of the appointment%5Cn%22 +%0A              %22%5Ct%5CtbeginTime When the appt begins (24-hour time)%5Cn%22 +%0A              %22%5Ct%5CtendTime When the appt ends (24-hour time)%5Cn%22 +%0A              %22%5Ctoptions are (options may appear in any order):%5Cn%22 +%0A              %22%5Ct%5Ct-print Prints a description of the new appointment%5Cn%22 +%0A              %22%5Ct%5Ct-README Prints a README for this project and exits%5Cn%22 +%0A              %22%5CtDate and time should be in the format: mm/dd/yyyy hh:mm%5Cn%22);%0A%0A      System.exit(0);%0A    %7D%0A%0A    for (String arg : args) %7B%0A      System.out.println(arg);%0A    %7D%0A%0A    // Default to error%0A    System.err.println(%22Missing command line arguments%22);%0A    System.exit(1);%0A  %7D%0A%0A%7D%0A%0A/*%0A%0AThe -print option cannot appear after the args, but the options can appear in any order.  That is, a command line like%0A%0A$ java -jar target/apptbook-1.0-SNAPSHOT.jar Dave -print 7/15/2016 14:39  7/15/2016 15:39%0A%0Ashould create an appointment whose description is %22-print%22.  Note that I won't test this case, though.%0A%0AA command line like%0A%0A$ java -jar target/apptbook-1.0-SNAPSHOT.jar Dave %22Save the whales%22 7/15/2016 14:39  7/15/2016 15:39 -print%0A%0Ashould issue an error because there are extraneous command line arguments.%0A%0AA command line like:%0A%0A$ java -jar target/apptbook-1.0-SNAPSHOT.jar -print -README Dave %22Save the whales%22 7/15/2016 14:39  7/15/2016 15:39%0A%0Ashould print the README and exit because that's what you always do when -README is provided.%0A%0A */
 %0A

Add README option and output