1 18 19 package org.apache.beehive.netui.tools.testrecorder.shared; 20 21 import org.apache.beehive.netui.tools.testrecorder.shared.util.DateHelper; 22 23 import java.util.Calendar ; 24 import java.text.ParseException ; 25 26 31 public class SessionBean { 32 33 protected String sessionName; 34 private String tester; 35 private Calendar startDate; 36 private Calendar endDate; 37 private String description; 38 39 public String getSessionName() { 40 return sessionName; 41 } 42 43 public String getTester() { 44 return tester; 45 } 46 47 public void setTester( String tester ) { 48 this.tester = tester; 49 } 50 51 protected Calendar getStartDate() { 52 return startDate; 53 } 54 55 public void setStartDate( Calendar startDate ) { 56 this.startDate = startDate; 57 } 58 59 public void setStartDate( String date ) throws ParseException { 60 startDate = DateHelper.getCalendarInstance(date); 61 } 62 63 public String getStartDateString() { 64 if ( getStartDate() == null ) { 65 return null; 66 } 67 return DateHelper.formatToString(getStartDate()); 68 } 69 70 protected Calendar getEndDate() { 71 return endDate; 72 } 73 74 public void setEndDate( Calendar endDate ) { 75 this.endDate = endDate; 76 } 77 78 public void setEndDate( String date ) throws ParseException { 79 endDate = DateHelper.getCalendarInstance(date); 80 } 81 82 public String getEndDateString() { 83 if ( getEndDate() == null ) { 84 return null; 85 } 86 else return DateHelper.formatToString(getEndDate()); 87 } 88 89 public String getDescription() { 90 return description; 91 } 92 93 public void setDescription( String description ) { 94 this.description = description; 95 } 96 97 } 98 | Popular Tags |