001 /* PAVLOV -- Multiple Choice Study System
002 * Copyright (C) 2000 - 2004 T.J. Willis
003 *
004 * This program is free software; you can redistribute it and/or
005 * modify it under the terms of the GNU General Public License
006 * as published by the Free Software Foundation; either version 2
007 * of the License, or (at your option) any later version.
008 *
009 * This program is distributed in the hope that it will be useful,
010 * but WITHOUT ANY WARRANTY; without even the implied warranty of
011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
012 * GNU General Public License for more details.
013 *
014 * You should have received a copy of the GNU General Public License
015 * along with this program; if not, write to the Free Software
016 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
017 *
018 * $Header: /cvsroot/pavlov/net/sourceforge/pavlov/event/LogonEvent.java,v 1.1 2004/05/10 14:52:50 tj_willis Exp $
019 */
020 package net.sourceforge.pavlov.event;
021 import net.sourceforge.pavlov.user.User;
022
023 public class LogonEvent
024 {
025
026 private String userName;
027 private String password;
028 private boolean create = false;
029 private User user;
030
031 public LogonEvent(String userName, String password, boolean create){
032 this.userName = userName;
033 this.password = password;
034 this.create = create;
035 }
036
037 public LogonEvent(User user){
038 this.user = user;
039 this.userName = user.getName();
040 this.create = false;
041 }
042 public String getUserName() { return userName; }
043 public String getPassword() { return password; }
044 public void setCreateRequest(boolean create) { this.create = create; }
045 public boolean getCreateRequest() { return create; }
046 public User getUser(){ return user; }
047 public void setUser(User user) { this.user = user; }
048 }