1 11 12 package freeforums.message; 13 14 import java.rmi.RemoteException ; 15 import java.util.Date ; 16 import javax.ejb.*; 17 18 public class MessageBean implements EntityBean { 19 20 transient private EntityContext context; 21 22 public Integer messageID; 23 public String subject; 24 public String description; 25 public Integer replyToID; 26 public Integer forumID; 27 public String attachmentFile; 28 public String userName; 29 public Date messageDate; 30 31 public Integer ejbCreate(Integer messageID, String subject, String description, Integer forumID, String userName) { 32 33 this.messageID = messageID; 34 this.subject = subject; 35 this.description = description; 36 this.forumID = forumID; 37 this.userName = userName; 38 return null; 39 40 } 41 42 public void ejbPostCreate(Integer messageID, String subject, String description, Integer forumID, String userName) { } 43 44 public void setEntityContext(EntityContext context) { this.context = context; } 45 46 public void unsetEntityContext() { context = null; } 47 48 public void ejbActivate() { } 49 public void ejbPassivate() { } 50 public void ejbLoad() { } 51 public void ejbStore() { } 52 public void ejbRemove() { } 53 54 57 58 public Integer getMessageID() throws RemoteException { return messageID; } 59 public void setMessageID(Integer messageID) throws RemoteException { this.messageID = messageID; } 60 61 public String getSubject() throws RemoteException { return subject; } 62 public void setSubject(String subject) throws RemoteException { this.subject = subject; } 63 64 public String getDescription() throws RemoteException { return description; } 65 public void setDescription(String descrption) throws RemoteException { this.description = description; } 66 67 public Integer getReplyToID() throws RemoteException { return replyToID; } 68 public void setReplyToID(Integer replyToID) throws RemoteException { this.replyToID = replyToID; } 69 70 public Integer getForumID() throws RemoteException { return forumID; } 71 public void setForumID(Integer forumID) throws RemoteException { this.forumID = forumID; } 72 73 public String getAttachmentFile() throws RemoteException { return attachmentFile; } 74 public void setAttachmentFile(String attachmentFile) throws RemoteException { this.attachmentFile = attachmentFile; } 75 76 public String getUserName() throws RemoteException { return userName; } 77 public void setUserName(String userName) throws RemoteException { this.userName = userName; } 78 79 public Date getMessageDate() throws RemoteException { return messageDate; } 80 public void setMessageDate(Date messageDate) throws RemoteException { this.messageDate = messageDate; } 81 82 } 83 | Popular Tags |