/*
 * JORAM: Java(TM) Open Reliable Asynchronous Messaging
 * Copyright (C) 2003 - 2026 ScalAgent Distributed Technologies
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or any later version.
 * 
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
 * USA.
 *
 * Initial developer(s): Nicolas Tachker (ScalAgent)
 * Contributor(s):
 */
package org.objectweb.joram.mom.notifications;

import fr.dyade.aaa.agent.Notification;

// Be careful, this class is used 
public final class WakeUpNot extends Notification {
  private static final long serialVersionUID = 1L;
  
  /**
   *  This field is always visibly initialized to true.
   *  However, this class is also used in a hidden way (see default constructor), and update is then
   *  initialized to false.
   */
  private boolean update;

  /**
   * @return the update
   */
  public boolean isUpdate() {
    return update;
  }

  /**
   * Note that this class is used in a hidden way by the WakeUpTask class (package fr.dyade.aaa.agent).
   * It requires an empty constructor to enable this usage.
   * 
   * See the agentInitialize method of the Destination and UserAgent classes.
   */
  public WakeUpNot() {
    persistent = false;
  }
  
  public WakeUpNot(boolean update) {
    persistent = false;
    this.update = update;
  }
}
