Java tutorial
/* * Copyright (c) 2013 ITOCHU Techno-Solutions Corporation. * * 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 jp.co.ctc_g.jse.csv.showcase.business.domain; import java.io.Serializable; import jp.co.ctc_g.jse.core.csv.CSVColumn; import jp.co.ctc_g.jse.core.validation.constraints.Email; import jp.co.ctc_g.jse.core.validation.constraints.Katakana; import jp.co.ctc_g.jse.core.validation.constraints.MaxLength; import jp.co.ctc_g.jse.core.validation.constraints.Required; import jp.co.ctc_g.jse.core.validation.constraints.ZipCode; import org.apache.commons.lang.builder.ToStringBuilder; import org.apache.commons.lang.builder.ToStringStyle; /** * <p> * ???????? * </p> * @author ITOCHU Techno-Solutions Corporation. */ public class UserProfile implements Serializable { private static final long serialVersionUID = 1L; /** * ID */ private Long id; /** * ?? */ @CSVColumn(seq = 1) @Required @MaxLength(50) private String name; /** * ??() */ @CSVColumn(seq = 2) @Required @Katakana @MaxLength(100) private String kana; /** * */ @CSVColumn(seq = 3) @Email private String email; /** * ? */ @CSVColumn(seq = 4) @Required @ZipCode(separator = "-") private String zip; /** * ?? */ public UserProfile() { } /** * ID ??? * @return id */ public Long getId() { return id; } /** * ID ??? * @param id id */ public void setId(Long id) { this.id = id; } /** * ?? ??? * @return ?? */ public String getName() { return name; } /** * ?? ??? * @param name ?? */ public void setName(String name) { this.name = name; } /** * ??() ??? * @return ??() */ public String getKana() { return kana; } /** * ??() ??? * @param kana ??() */ public void setKana(String kana) { this.kana = kana; } /** * ??? * @return */ public String getEmail() { return email; } /** * ??? * @param email */ public void setEmail(String email) { this.email = email; } /** * ? ??? * @return ? */ public String getZip() { return zip; } /** * ? ??? * @param zip ? */ public void setZip(String zip) { this.zip = zip; } /** * {@inheritDoc} */ @Override public String toString() { return ToStringBuilder.reflectionToString(this, ToStringStyle.DEFAULT_STYLE); } }