/* * Copyright 1999-2011 Alibaba Group. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.alibaba.dubbo.common.model.person; import java.io.Serializable; /** * @author tony.chenl */ public class BigPerson implements Serializable { private static final long serialVersionUID = 1L; String personId; String loginName; PersonStatus status; String email; String penName; PersonInfo infoProfile; public BigPerson() { } public BigPerson(String id) { this.personId = id; } public String getPersonId() { return personId; } public void setPersonId(String personId) { this.personId = personId; } public PersonInfo getInfoProfile() { return infoProfile; } public void setInfoProfile(PersonInfo infoProfile) { this.infoProfile = infoProfile; } public void setLoginName(String loginName) { this.loginName = loginName; } public void setStatus(PersonStatus status) { this.status = status; } public void setEmail(String email) { this.email = email; } public void setPenName(String penName) { this.penName = penName; } public String getEmail() { return this.email; } public String getLoginName() { return this.loginName; } public PersonStatus getStatus() { return this.status; } public String getPenName() { return penName; } @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((email == null) ? 0 : email.hashCode()); result = prime * result + ((infoProfile == null) ? 0 : infoProfile.hashCode()); result = prime * result + ((loginName == null) ? 0 : loginName.hashCode()); result = prime * result + ((penName == null) ? 0 : penName.hashCode()); result = prime * result + ((personId == null) ? 0 : personId.hashCode()); result = prime * result + ((status == null) ? 0 : status.hashCode()); return result; } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; BigPerson other = (BigPerson) obj; if (email == null) { if (other.email != null) return false; } else if (!email.equals(other.email)) return false; if (infoProfile == null) { if (other.infoProfile != null) return false; } else if (!infoProfile.equals(other.infoProfile)) return false; if (loginName == null) { if (other.loginName != null) return false; } else if (!loginName.equals(other.loginName)) return false; if (penName == null) { if (other.penName != null) return false; } else if (!penName.equals(other.penName)) return false; if (personId == null) { if (other.personId != null) return false; } else if (!personId.equals(other.personId)) return false; if (status != other.status) return false; return true; } @Override public String toString() { return "BigPerson [personId=" + personId + ", loginName=" + loginName + ", status=" + status + ", email=" + email + ", penName=" + penName + ", infoProfile=" + infoProfile + "]"; } }