org.appfuse.model
Class User

java.lang.Object
  extended byorg.appfuse.model.BaseObject
      extended byorg.appfuse.model.User
All Implemented Interfaces:
Serializable

public class User
extends BaseObject

User class This class is used to generate the Struts Validator Form as well as the Hibernate mapping files.

View Source

Version:
$Revision: 1.1 $ $Date: 2004/03/31 13:04:16 $
Author:
Matt Raible
See Also:
Serialized Form
Class:
table="app_user"
Form Name:
include-all="true" extends="BaseForm"

Field Summary
protected  String address
           
protected  String city
           
protected  String confirmPassword
           
protected  String country
           
protected  String email
           
protected  String firstName
           
protected  Long id
           
protected  String lastName
           
protected  String password
           
protected  String passwordHint
           
protected  String phoneNumber
           
protected  String postalCode
           
protected  String province
           
protected  List roles
           
protected  String username
           
protected  String website
           
 
Constructor Summary
User()
           
 
Method Summary
 void addRole(String rolename)
          Adds a role for the user
 String getAddress()
          Returns the address.
 String getCity()
          Returns the city.
 String getConfirmPassword()
          Returns the confirmedPassword.
 String getCountry()
          Returns the country.
 String getEmail()
          Returns the email.
 String getFirstName()
          Returns the firstName.
 Long getId()
          Returns the id.
 String getLastName()
          Returns the lastName.
 String getPassword()
          Returns the password.
 String getPasswordHint()
          Returns the passwordHint.
 String getPhoneNumber()
          Returns the phoneNumber.
 String getPostalCode()
          Returns the postalCode.
 String getProvince()
          Returns the province.
 List getRoles()
          Returns the user's roles.
 String getUsername()
          Returns the username.
 String getWebsite()
          Returns the website.
 void setAddress(String address)
          Sets the address.
 void setCity(String city)
          Sets the city.
 void setConfirmPassword(String confirmPassword)
          Sets the confirmedPassword.
 void setCountry(String country)
          Sets the country.
 void setEmail(String email)
          Sets the email.
 void setFirstName(String firstName)
          Sets the firstName.
 void setId(Long id)
          Sets the id.
 void setLastName(String lastName)
          Sets the lastName.
 void setPassword(String password)
          Sets the password.
 void setPasswordHint(String passwordHint)
           
 void setPhoneNumber(String phoneNumber)
          Sets the phoneNumber.
 void setPostalCode(String postalCode)
          Sets the postalCode.
 void setProvince(String province)
          Sets the province.
 void setRoles(List roles)
          Sets the roles.
 void setUsername(String username)
          Sets the username.
 void setWebsite(String website)
          Sets the website.
 
Methods inherited from class org.appfuse.model.BaseObject
equals, hashCode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected Long id

username

protected String username

password

protected String password

confirmPassword

protected String confirmPassword

firstName

protected String firstName

lastName

protected String lastName

address

protected String address

city

protected String city

province

protected String province

country

protected String country

postalCode

protected String postalCode

phoneNumber

protected String phoneNumber

email

protected String email

website

protected String website

passwordHint

protected String passwordHint

roles

protected List roles
Constructor Detail

User

public User()
Method Detail

getId

public Long getId()
Returns the id.

Returns:
String
Id:
column="id" generator-class="increment" unsaved-value="null"

getUsername

public String getUsername()
Returns the username.

Returns:
String
Property:
column="username" not-null="true" unique="true"

getPassword

public String getPassword()
Returns the password.

Returns:
String
Property:
column="password" not-null="true"

getConfirmPassword

public String getConfirmPassword()
Returns the confirmedPassword.

Returns:
String

getFirstName

public String getFirstName()
Returns the firstName.

Returns:
String
Property:
column="firstName" not-null="true"

getLastName

public String getLastName()
Returns the lastName.

Returns:
String
Property:
column="lastName" not-null="true"

getAddress

public String getAddress()
Returns the address.

Returns:
String
Property:
column="address" not-null="false"

getCity

public String getCity()
Returns the city.

Returns:
String
Property:
column="city" not-null="true"

getCountry

public String getCountry()
Returns the country.

Returns:
String
Property:
column="country" length="100"

getEmail

public String getEmail()
Returns the email. This is an optional field for specifying a different e-mail than the username.

Returns:
String
Property:
column="email" not-null="false"

getPhoneNumber

public String getPhoneNumber()
Returns the phoneNumber.

Returns:
String
Property:
column="phoneNumber" not-null="false"

getPostalCode

public String getPostalCode()
Returns the postalCode.

Returns:
String
Property:
column="postalCode" not-null="true"

getProvince

public String getProvince()
Returns the province.

Returns:
String
Property:
column="province" length="100"

getWebsite

public String getWebsite()
Returns the website.

Returns:
String
Property:
column="website" not-null="false"

getPasswordHint

public String getPasswordHint()
Returns the passwordHint.

Returns:
String
Property:
column="passwordHint" not-null="false"

getRoles

public List getRoles()
Returns the user's roles.

Returns:
List

addRole

public void addRole(String rolename)
Adds a role for the user


setId

public void setId(Long id)
Sets the id.

Parameters:
id - The id to set

setPassword

public void setPassword(String password)
Sets the password.

Parameters:
password - The password to set

setConfirmPassword

public void setConfirmPassword(String confirmPassword)
Sets the confirmedPassword.

Parameters:
confirmPassword - The confirmed password to set

setAddress

public void setAddress(String address)
Sets the address.

Parameters:
address - The address to set

setCity

public void setCity(String city)
Sets the city.

Parameters:
city - The city to set

setCountry

public void setCountry(String country)
Sets the country.

Parameters:
country - The country to set

setEmail

public void setEmail(String email)
Sets the email.

Parameters:
email - The email to set

setFirstName

public void setFirstName(String firstName)
Sets the firstName.

Parameters:
firstName - The firstName to set

setLastName

public void setLastName(String lastName)
Sets the lastName.

Parameters:
lastName - The lastName to set

setPhoneNumber

public void setPhoneNumber(String phoneNumber)
Sets the phoneNumber.

Parameters:
phoneNumber - The phoneNumber to set

setPostalCode

public void setPostalCode(String postalCode)
Sets the postalCode.

Parameters:
postalCode - The postalCode to set

setProvince

public void setProvince(String province)
Sets the province.

Parameters:
province - The province to set

setUsername

public void setUsername(String username)
Sets the username.

Parameters:
username - The username to set

setWebsite

public void setWebsite(String website)
Sets the website.

Parameters:
website - The website to set

setPasswordHint

public void setPasswordHint(String passwordHint)
Parameters:
passwordHint - The password hint to set

setRoles

public void setRoles(List roles)
Sets the roles.

Parameters:
roles - The roles to set


Copyright © 2002-2004