/** * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved. * * 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 (at your option) * 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. */ package de.uhh.l2g.plugins.model.impl; import java.util.Date; import com.liferay.portal.kernel.exception.PortalException; import com.liferay.portal.kernel.exception.SystemException; import com.liferay.portal.model.User; import com.liferay.portal.service.UserLocalServiceUtil; /** * The extended model implementation for the Coordinator service. Represents a row in the "LG_Coordinator" database table, with each column mapped to a property of this class. * * <p> * Helper methods and all application logic should be put in this class. Whenever methods are added, rerun ServiceBuilder to copy their definitions into the {@link de.uhh.l2g.plugins.model.Coordinator} interface. * </p> * * @author Iavor Sturm */ public class CoordinatorImpl extends CoordinatorBaseImpl { /* * NOTE FOR DEVELOPERS: * * Never reference this class directly. All methods that expect a coordinator model instance should use the {@link de.uhh.l2g.plugins.model.Coordinator} interface instead. */ private String lastName; private String firstName; private String emailAddress; private Date lastLoginDate; public String getLastName() { return lastName; } public void setLastName(String lastName) { this.lastName = lastName; } public String getFirstName() { return firstName; } public void setFirstName(String firstName) { this.firstName = firstName; } public String getEmailAddress() { return emailAddress; } public void setEmailAddress(String emailAddress) { this.emailAddress = emailAddress; } public Date getLastLoginDate() { return lastLoginDate; } public void setLastLoginDate(Date lastLoginDate) { this.lastLoginDate = lastLoginDate; } public CoordinatorImpl() { } public CoordinatorImpl(Long coordinatorId) throws PortalException, SystemException { User lu = UserLocalServiceUtil.getUser(coordinatorId); lastName = lu.getLastName(); firstName = lu.getFirstName(); emailAddress = lu.getEmailAddress(); lastLoginDate = lu.getLastLoginDate(); } }