date update

This commit is contained in:
HeshamTB 2019-01-28 14:15:46 +03:00
parent f97260e256
commit a26e9a9a9f
2 changed files with 21 additions and 8 deletions

View File

@ -23,5 +23,11 @@
<artifactId>json-simple</artifactId>
<version>1.1.1</version>
</dependency>
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<version>2.9.9</version>
</dependency>
</dependencies>
</project>

View File

@ -1,12 +1,16 @@
import java.sql.Date;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Scanner;
import org.joda.*;
import org.joda.time.LocalDate;
//TODO: save Person as JSON
//TODO: save Persons as list (databse)
public class Main {
public static void main(String[] args) {
Person p = new Person(12345, "Hesham", Level.BA);
System.out.println("-------------------------------------------------");
@ -51,8 +55,11 @@ public class Main {
* @since 0.1
*/
public static void Print(Person p) {
LocalDate date = new LocalDate();
System.out.println(
"\n\n\n\t---------INFO---------\n"
+ "\t --- "+ date.toString()+" ---\n"
+ "\tName: "+p.getAccount().getName()+"\n"
+ "\tID: "+p.getAccount().getID()+"\n"
+ "\tMajor: "+p.getEdu().getMajor()+"\n"