Class NbReceivedLabel

java.lang.Object
com.nilhcem.fakesmtp.gui.info.NbReceivedLabel
All Implemented Interfaces:
Observer

public final class NbReceivedLabel extends Object implements Observer
Label class to display the number of received emails.
Since:
1.0
Author:
Nilhcem
  • Constructor Details

    • NbReceivedLabel

      public NbReceivedLabel()
      Creates the label class (with a bold font).
  • Method Details

    • get

      public JLabel get()
      Returns the JLabel object.
      Returns:
      the JLabel object.
    • update

      public void update(Observable o, Object arg)
      Actions which will be done when the component will be notified by an Observable object.
      • If the observable element is a MailSaver object, the method will increment the number of received messages and update the UIModel;
      • If the observable element is a ClearAllButton, the method will reinitialize the number of received messages and update the UIModel;
      • When running on OS X the method will also update the Dock Icon with the number of received messages.
      Specified by:
      update in interface Observer
      Parameters:
      o - the observable element which will notify this class.
      arg - optional parameters (not used).