Class Student


class Student extends Object
  • Field Details

    • studentName

      String studentName
    • studentEmail

      String studentEmail
    • mySessions

      HashMap<LocalDate,​Session> mySessions
    • amountPaid

      double amountPaid
    • partyForPayment

      String partyForPayment
    • finishedPaying

      boolean finishedPaying
  • Constructor Details

    • Student

      public Student(String studentName, String studentEmail, HashMap<LocalDate,​Session> mySessions, double amountPaid, String partyForPayment, boolean finishedPaying)
      Initializes a new student with the given parameters. studentName must be a valid String. studentEmail must be a valid email. mySessions must be an initialized HashMap amountPaid must be a valid double in dollars.
      Parameters:
      studentName - Name of the student
      studentEmail - Email of the student
      mySessions - Session list
      amountPaid - Amount paid in dollars
      partyForPayment - Party for payment
      finishedPaying - If student is finished paying
  • Method Details

    • getStudentName

      public String getStudentName()
      Returns the student's name
      Returns:
      The student name
    • getStudentEmail

      public String getStudentEmail()
      Returns the student's email
      Returns:
      The student's email
    • getMySessions

      public HashMap<LocalDate,​Session> getMySessions()
      Returns the HashMap of sessions
      Returns:
      HashMap of sessions
    • getASessions

      public Session getASessions(LocalDate date)
      Returns the session at the given date. The date parameter must link to a valid session.
      Parameters:
      date -
      Returns:
      The session at the given date
    • getAmountPaid

      public double getAmountPaid()
      Returns the amount paid.
      Returns:
      The amount paid
    • getPartyForPayment

      public String getPartyForPayment()
      Returns the party for payment
      Returns:
      the party for payment
    • getFinishedPaying

      public boolean getFinishedPaying()
      Returns if the student is finished paying.
      Returns:
      if the student is finished paying.
    • setStudentName

      public void setStudentName(String name)
      Sets the student's name.
      Parameters:
      name -
    • setStudentEmail

      public void setStudentEmail(String email)
      Sets the student's email.
      Parameters:
      email -
    • setMySessions

      public void setMySessions(HashMap<LocalDate,​Session> sessions)
      Set the student's sessions to the given HashMap. The sessions argument must be a valid HashMap.
      Parameters:
      sessions - HashMap of sessions
    • setAmountPaid

      public void setAmountPaid(double amount)
      Sets amount payed. The amount argument must be a valid double.
      Parameters:
      amount - amount paid in dollars
    • setPartyForPayment

      public void setPartyForPayment(String payment)
      Sets the party for payment.
      Parameters:
      payment -
    • setFinishedPaying

      public void setFinishedPaying(boolean payed)
      Sets if the student has finished paying.
      Parameters:
      payed - true if finished, false otherwise