Skip to content

ThemiraChathumina/EmailClientFinal

Repository files navigation

Command-Line Email Client

This project is a command-line-based email client that allows users to manage and send emails to official and personal recipients. The email client supports the following features:

Features

  1. Recipient Management:

    • The details of official and personal recipients are stored in a text file (clientList.txt).
    • Official recipient records have the format: Official: <name>, <email>, <designation>.
    • Official friends' records include their birthday: Office_friend: <name>, <email>, <designation>, <birthday>.
    • Personal recipients' records include their birthday: Personal: <name>, <nick-name>, <email>, <birthday>.
    • Users can add new recipients to the text file via the command-line.
  2. Birthday Greetings:

    • The email client loads recipient details from the text file into the application.
    • On the recipient's birthday, the application sends a birthday greeting email.
    • Official friends and personal recipients receive different birthday messages.
  3. Recipient Count:

    • The system keeps track of the number of recipient objects using static members.
  4. Email Logging:

    • All emails sent by the email client are saved to the hard disk as serialized objects.
    • Users can retrieve information about all the emails sent on a specific day using a command-line option.

Usage

The email client supports the following command-line options:

  1. Add a New Recipient:

    • Add a new recipient to the text file.
    • Example: java Email_Client --add-recipient <details>
  2. Send an Email:

    • Send an email to a recipient.
    • Example: java Email_Client --send-email <recipient-email> <subject> <message>
  3. Print Recipients with Birthday Today:

    • List all recipients who have their birthday set to the current date.
    • Example: java Email_Client --print-birthday-today
  4. Print Emails Sent on a Specific Date:

    • Retrieve details (time sent, recipient, subject, and body) of all emails sent on a user-specified date.
    • Example: java Email_Client --print-emails-sent-on <date>
  5. Print Recipient Count:

    • Display the total number of recipient objects in the application.
    • Example: java Email_Client --print-recipient-count

Implementation Details

  • The email sending functionality is correctly implemented, including sending birthday greetings and user-specified emails.
  • Object-oriented programming principles are followed for better code organization and maintainability.
  • Coding best practices are adhered to throughout the project.

Getting Started

To run the email client, use the provided Email_Client.java file as the starting point. Make sure to download the javax.mail.jar package from here and include it in your project for email functionality.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages