/*
- * Copyright (C) 2016 Roland Haeder
+ * Copyright (C) 2016, 2017 Roland Häder
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
package org.mxchange.pizzaapplication.beans.contact;
import java.io.Serializable;
-import java.util.Date;
import java.util.List;
import org.mxchange.jcontacts.contact.Contact;
-import org.mxchange.jcontacts.contact.gender.Gender;
-import org.mxchange.jcontacts.events.contact.add.AdminAddedContactEvent;
-import org.mxchange.jcontacts.events.contact.update.AdminUpdatedContactEvent;
import org.mxchange.jcontacts.exceptions.ContactNotFoundException;
-import org.mxchange.jcountry.data.Country;
-import org.mxchange.jcustomercore.events.customer.added.AdminAddedCustomerEvent;
-import org.mxchange.jphone.phonenumbers.mobileprovider.MobileProvider;
-import org.mxchange.jusercore.events.confirmation.UserConfirmedAccountEvent;
-import org.mxchange.jusercore.events.login.UserLoggedInEvent;
-import org.mxchange.jusercore.events.registration.UserRegisteredEvent;
-import org.mxchange.jusercore.events.user.add.AdminAddedUserEvent;
/**
* An interface for user beans
* <p>
- * @author Roland Haeder<roland@mxchange.org>
+ * @author Roland Häder<roland@mxchange.org>
*/
public interface PizzaContactWebSessionController extends Serializable {
public static final Integer MINIMUM_PASSWORD_LENGTH = 5;
/**
- * Returns a list of all found contacts
- * <p>
- * @return A list of all contacts.
- */
- List<Contact> allContacts();
-
- /**
- * Checks whether there are contacts.
+ * Getter for email address
* <p>
- * @return Whether contacts are there
+ * @return Email address
*/
- boolean hasContacts ();
+ String getEmailAddress ();
/**
- * Event observer for newly added users by adminstrator
- * <p>
- * @param event Event being fired
+ * Clears both email address field
*/
- void afterAdminAddedUserEvent (final AdminAddedUserEvent event);
+ void clearEmailAddresses ();
/**
- * Event observer when user confirmed account.
+ * Returns a list of all found contacts
* <p>
- * @param event Event being fired
+ * @return A list of all contacts.
*/
- void afterUserConfirmedAccount (final UserConfirmedAccountEvent event);
+ List<Contact> allContacts ();
/**
* Updates all data from bean in given contact instance
*/
Contact lookupContactById (final Long contactId) throws ContactNotFoundException;
- /**
- * Event observer for new user registrations
- * <p>
- * @param event User registration event
- */
- void afterRegistrationEvent (final UserRegisteredEvent event);
-
- /**
- * Observes events being fired when an administrator has added a new
- * customer.
- * <p>
- * @param event Event being fired
- */
- void afterAdminAddedCustomer (final AdminAddedCustomerEvent event);
-
- /**
- * Observes events being fired when an administrator has added a new
- * contact.
- * <p>
- * @param event Event being fired
- */
- void afterAdminAddedContact (final AdminAddedContactEvent event);
-
- /**
- * Event observer for updated contact data by admins
- * <p>
- * @param event Updated contact data event
- */
- void afterAdminUpdatedContactDataEvent (final AdminUpdatedContactEvent event);
-
- /**
- * Event observer for logged-in user
- * <p>
- * @param event Event instance
- */
- void afterUserLogin (final UserLoggedInEvent event);
-
/**
* Creates an instance from all properties
* <p>
*/
Contact createContactInstance ();
- /**
- * Getter for birth day
- * <p>
- * @return Birth day
- */
- Date getBirthday ();
-
- /**
- * Setter for birth day
- * <p>
- * @param birthday Birth day
- */
- void setBirthday (final Date birthday);
-
- /**
- * Getter for ellphone number's carrier
- * <p>
- * @return Cellphone number's carrier
- */
- MobileProvider getCellphoneCarrier ();
-
- /**
- * Setter for cellphone number's carrier prefix
- * <p>
- * @param cellphoneCarrier Cellphone number's carrier prefix
- */
- void setCellphoneCarrier (final MobileProvider cellphoneCarrier);
-
- /**
- * Getter for ellphone number
- * <p>
- * @return Cellphone number
- */
- Long getCellphoneNumber ();
-
- /**
- * Setter for ellphone number
- * <p>
- * @param cellphoneNumber Cellphone number
- */
- void setCellphoneNumber (final Long cellphoneNumber);
-
- /**
- * City
- * <p>
- * @return the city
- */
- String getCity ();
-
- /**
- * City
- * <p>
- * @param city the city to set
- */
- void setCity (final String city);
-
- /**
- * Getter for comments
- * <p>
- * @return Comments
- */
- String getComment ();
-
- /**
- * Setter for comment
- * <p>
- * @param comment Comments
- */
- void setComment (final String comment);
-
- /**
- * Getter for country instance
- * <p>
- * @return Country instance
- */
- Country getCountry ();
-
- /**
- * Setter for country instance
- * <p>
- * @param country Country instance
- */
- void setCountry (final Country country);
-
- /**
- * Getter for email address
- * <p>
- * @return Email address
- */
- String getEmailAddress ();
-
- /**
- * Setter for email address
- * <p>
- * @param emailAddress Email address
- */
- void setEmailAddress (final String emailAddress);
-
- /**
- * Getter for email address, repeated
- * <p>
- * @return the emailAddress, repeated
- */
- String getEmailAddressRepeat ();
-
- /**
- * Setter for email address repeated
- * <p>
- * @param emailAddressRepeat the emailAddress to set
- */
- void setEmailAddressRepeat (final String emailAddressRepeat);
-
- /**
- * Family name
- * <p>
- * @return the familyName
- */
- String getFamilyName ();
-
- /**
- * Family name
- * <p>
- * @param familyName the familyName to set
- */
- void setFamilyName (final String familyName);
-
- /**
- * Getter for fax number's area code
- * <p>
- * @return Fax number's area code
- */
- Integer getFaxAreaCode ();
-
- /**
- * Setter for fax number's area code
- * <p>
- * @param faxAreaCode Fax number's area code
- */
- void setFaxAreaCode (final Integer faxAreaCode);
-
- /**
- * Getter for fax's country instance
- * <p>
- * @return Fax' country instance
- */
- Country getFaxCountry ();
-
- /**
- * Setter for fax's country instance
- * <p>
- * @param faxCountry Fax' country instance
- */
- void setFaxCountry (final Country faxCountry);
-
- /**
- * Getter for fax number
- * <p>
- * @return Fax number
- */
- Long getFaxNumber ();
-
- /**
- * Setter for fax number
- * <p>
- * @param faxNumber Fax number
- */
- void setFaxNumber (final Long faxNumber);
-
- /**
- * First name
- * <p>
- * @return the first name
- */
- String getFirstName ();
-
- /**
- * First name
- * <p>
- * @param firstName the first name to set
- */
- void setFirstName (final String firstName);
-
- /**
- * Gender of the contact
- * <p>
- * @return the gender
- */
- Gender getGender ();
-
- /**
- * Gender of the contact
- * <p>
- * @param gender the gender to set
- */
- void setGender (final Gender gender);
-
- /**
- * House number
- * <p>
- * @return the houseNumber
- */
- Short getHouseNumber ();
-
- /**
- * House number
- * <p>
- * @param houseNumber the houseNumber to set
- */
- void setHouseNumber (final Short houseNumber);
-
- /**
- * Getter for house number extension, example: 123a 'a' is then the
- * extension and 123 is the house number.
- * <p>
- * @return House number extension
- */
- String getHouseNumberExtension ();
-
- /**
- * Setter for house number extension
- * <p>
- * @param houseNumberExtension House number extension
- */
- void setHouseNumberExtension (final String houseNumberExtension);
-
- /**
- * Getter for phone number's area code
- * <p>
- * @return Phone number's area code
- */
- Integer getPhoneAreaCode ();
-
- /**
- * Setter for phone number's area code
- * <p>
- * @param phoneAreaCode Phone number's area code
- */
- void setPhoneAreaCode (final Integer phoneAreaCode);
-
- /**
- * Getter for phone number's country instance
- * <p>
- * @return Phone number's country instance
- */
- Country getPhoneCountry ();
-
- /**
- * Setter for phone number's country instance
- * <p>
- * @param phoneCountry Phone number's country instance
- */
- void setPhoneCountry (final Country phoneCountry);
-
- /**
- * Getter for phone number
- * <p>
- * @return Phone number
- */
- Long getPhoneNumber ();
-
- /**
- * Setter for phone number
- * <p>
- * @param phoneNumber Phone number
- */
- void setPhoneNumber (final Long phoneNumber);
-
- /**
- * Street
- * <p>
- * @return the street
- */
- String getStreet ();
-
- /**
- * Street
- * <p>
- * @param street the street to set
- */
- void setStreet (final String street);
-
- /**
- * ZIP code
- * <p>
- * @return the zipCode
- */
- Integer getZipCode ();
-
- /**
- * ZIP code
- * <p>
- * @param zipCode the zipCode to set
- */
- void setZipCode (final Integer zipCode);
-
/**
* Getter for controller type
* <p>
* Setter for controller type
* <p>
* @param controllerType Controller type
+ * <p>
* @deprecated Don't use this method.
*/
@Deprecated