Mail.java
01 package com.bea.medrec.value;
02 
03 /**
04  <p>This class represents information in a mail message.</p>
05  *
06  @author Copyright (c) 2006 by BEA Systems. All Rights Reserved.
07  */
08 public class Mail extends BaseVO {
09 
10   private String message = null;
11   private String from = null;
12   private String to = null;
13   private String subject = null;
14 
15   public Mail() {
16   }
17 
18   public Mail(String pMessage,
19               String pFrom,
20               String pTo,
21               String pSubject) {
22     this.message = pMessage;
23     this.from = pFrom;
24     this.to = pTo;
25     this.subject = pSubject;
26   }
27 
28   public String getMessage() {
29     return this.message;
30   }
31 
32   public String getFrom() {
33     return this.from;
34   }
35 
36   public String getTo() {
37     return this.to;
38   }
39 
40   public String getSubject() {
41     return this.subject;
42   }
43 
44   public void setMessage(String pMessage) {
45     this.message = pMessage;
46   }
47 
48   public void setFrom(String pFrom) {
49     this.from = pFrom;
50   }
51 
52   public void setTo(String pTo) {
53     this.to = pTo;
54   }
55 
56   public void setSubject(String pSubject) {
57     this.subject = pSubject;
58   }
59 
60   public String toString() {
61     StringBuffer str = new StringBuffer();
62     str.append("Mail[To: "+to);
63     str.append(" | From: "+from);
64     str.append(" | Message: "+message);
65     str.append(" | Subject: "+subject);
66     str.append("]");
67 
68     return str.toString();
69   }
70 }