forked from AY2324S1-CS2103-F13-4/tp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request AY2324S1-CS2103-F13-4#42 from junhonglow/branch-Ad…
…d-Calendar-Storage Add calendar storage functionality
- Loading branch information
Showing
44 changed files
with
1,011 additions
and
54 deletions.
There are no files selected for viewing
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
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
2 changes: 1 addition & 1 deletion
2
...seedu/address/model/ReadOnlyCalendar.java → ...ress/model/calendar/ReadOnlyCalendar.java
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
32 changes: 32 additions & 0 deletions
32
src/main/java/seedu/address/model/util/SampleCalendarUtil.java
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,32 @@ | ||
package seedu.address.model.util; | ||
|
||
import seedu.address.model.calendar.Calendar; | ||
import seedu.address.model.calendar.ReadOnlyCalendar; | ||
import seedu.address.model.event.Event; | ||
import seedu.address.model.event.EventDescription; | ||
import seedu.address.model.event.EventPeriod; | ||
|
||
/** | ||
* Contains utility methods for populating {@code Calendar} with sample data. | ||
*/ | ||
public class SampleCalendarUtil { | ||
public static Event[] getSampleEvents() { | ||
return new Event[] { | ||
new Event(new EventDescription("Weekly team meeting"), | ||
new EventPeriod("2023-10-25 09:00", "2023-10-25 10:30")), | ||
new Event(new EventDescription(" Annual health checkup"), | ||
new EventPeriod("2023-11-10 15:15", "2023-11-10 16:00")), | ||
new Event(new EventDescription(" Birthday celebration"), | ||
new EventPeriod("2023-11-15 18:00", "2023-11-15 22:00")) | ||
}; | ||
} | ||
|
||
public static ReadOnlyCalendar getSampleCalendar() { | ||
Calendar sampleCalendar = new Calendar(); | ||
for (Event sampleEvent : getSampleEvents()) { | ||
sampleCalendar.addEvent(sampleEvent); | ||
} | ||
return sampleCalendar; | ||
} | ||
|
||
} |
Oops, something went wrong.