2 Copyright 2009 senju@users.sourceforge.jp
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
8 http://www.apache.org/licenses/LICENSE-2.0
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
17 package jp.sourceforge.rabbitBTS.models;
19 import java.util.Date;
21 import javax.jdo.annotations.IdGeneratorStrategy;
22 import javax.jdo.annotations.IdentityType;
23 import javax.jdo.annotations.NotPersistent;
24 import javax.jdo.annotations.PersistenceCapable;
25 import javax.jdo.annotations.Persistent;
26 import javax.jdo.annotations.PrimaryKey;
28 import org.springmodules.validation.bean.conf.loader.annotation.handler.Length;
29 import org.springmodules.validation.bean.conf.loader.annotation.handler.NotBlank;
30 import org.springmodules.validation.bean.conf.loader.annotation.handler.NotNull;
32 @PersistenceCapable(identityType = IdentityType.APPLICATION)
33 public class BbsPost {
35 @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
38 private Long authorId;
44 private String content;
48 private Account author;
54 public BbsPost(Long author, String content, Date date) {
55 this.authorId = author;
56 this.content = content;
64 public String getContent() {
68 public Date getDate() {
72 public void setContent(String content) {
73 this.content = content;
76 public void setDate(Date date) {
81 * @return the authorId
83 public Long getAuthorId() {
91 public void setAuthorId(Long author) {
92 this.authorId = author;
98 public Account getAuthor() {
106 public void setAuthor(Account author) {
107 this.author = author;