Revision 104,
1.2 KB
checked in by wojtekp, 13 years ago
(diff) |
|
-
Property svn:mime-type set to
text/plain
|
Rev | Line | |
---|
[104] | 1 | package schedframe.scheduling.plan.impl; |
---|
| 2 | |
---|
| 3 | import java.io.StringWriter; |
---|
| 4 | import java.util.Date; |
---|
| 5 | |
---|
| 6 | import org.exolab.castor.xml.MarshalException; |
---|
| 7 | import org.exolab.castor.xml.ValidationException; |
---|
| 8 | |
---|
| 9 | import schedframe.scheduling.plan.ScheduledTimeInterface; |
---|
| 10 | |
---|
| 11 | |
---|
| 12 | public class ScheduledTime implements ScheduledTimeInterface<org.qcg.broker.schemas.schedulingplan.ScheduledTime>{ |
---|
| 13 | |
---|
| 14 | private static final long serialVersionUID = 8546333273529232717L; |
---|
| 15 | private org.qcg.broker.schemas.schedulingplan.ScheduledTime st; |
---|
| 16 | |
---|
| 17 | public ScheduledTime(){ |
---|
| 18 | st = new org.qcg.broker.schemas.schedulingplan.ScheduledTime(); |
---|
| 19 | } |
---|
| 20 | |
---|
| 21 | public ScheduledTime(org.qcg.broker.schemas.schedulingplan.ScheduledTime st){ |
---|
| 22 | this.st = st; |
---|
| 23 | } |
---|
| 24 | |
---|
| 25 | public org.qcg.broker.schemas.schedulingplan.ScheduledTime getDescription() { |
---|
| 26 | return st; |
---|
| 27 | } |
---|
| 28 | |
---|
| 29 | public String getDocument() { |
---|
| 30 | StringWriter writer = new StringWriter(); |
---|
| 31 | try { |
---|
| 32 | st.marshal(writer); |
---|
| 33 | } catch (MarshalException e) { |
---|
| 34 | e.printStackTrace(); |
---|
| 35 | } catch (ValidationException e) { |
---|
| 36 | e.printStackTrace(); |
---|
| 37 | } |
---|
| 38 | return writer.toString(); |
---|
| 39 | } |
---|
| 40 | |
---|
| 41 | public Date getEnd() { |
---|
| 42 | return st.getEnd(); |
---|
| 43 | } |
---|
| 44 | |
---|
| 45 | public Date getStart() { |
---|
| 46 | return st.getStart(); |
---|
| 47 | } |
---|
| 48 | |
---|
| 49 | public void setEnd(Date end) { |
---|
| 50 | st.setEnd(end); |
---|
| 51 | } |
---|
| 52 | |
---|
| 53 | public void setStart(Date start) { |
---|
| 54 | st.setStart(start); |
---|
| 55 | } |
---|
| 56 | |
---|
| 57 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.