Last change
on this file since 425 was
204,
checked in by sherbold, 13 years ago
|
+ added functionality to generate replays for GUITAR from models generated for EFGs.
|
-
Property svn:mime-type set to
text/plain
|
File size:
1.4 KB
|
Line | |
---|
1 | package de.ugoe.cs.eventbench.efg.data;
|
---|
2 |
|
---|
3 | import de.ugoe.cs.eventbench.data.IReplayable;
|
---|
4 | import de.ugoe.cs.util.StringTools;
|
---|
5 |
|
---|
6 | /**
|
---|
7 | * <p>
|
---|
8 | * {@link IReplayable} used to generate test cases for the GUITAR suite.
|
---|
9 | * </p>
|
---|
10 | *
|
---|
11 | * @author Steffen Herbold
|
---|
12 | * @version 1.0
|
---|
13 | */
|
---|
14 | public class EFGReplayable implements IReplayable {
|
---|
15 |
|
---|
16 | /**
|
---|
17 | * <p>
|
---|
18 | * EventId in the EFG and GUI files.
|
---|
19 | * </p>
|
---|
20 | */
|
---|
21 | String eventId;
|
---|
22 |
|
---|
23 | /**
|
---|
24 | * <p>
|
---|
25 | * Id for object serialization.
|
---|
26 | * </p>
|
---|
27 | */
|
---|
28 | private static final long serialVersionUID = 1L;
|
---|
29 |
|
---|
30 | /**
|
---|
31 | * <p>
|
---|
32 | * Constructor. Creates a new {@link EFGReplayable}.
|
---|
33 | * </p>
|
---|
34 | *
|
---|
35 | * @param eventId
|
---|
36 | */
|
---|
37 | public EFGReplayable(String eventId) {
|
---|
38 | this.eventId = eventId;
|
---|
39 | }
|
---|
40 |
|
---|
41 | /*
|
---|
42 | * (non-Javadoc)
|
---|
43 | *
|
---|
44 | * @see de.ugoe.cs.eventbench.data.IReplayable#getReplay()
|
---|
45 | */
|
---|
46 | @Override
|
---|
47 | public String getReplay() {
|
---|
48 | StringBuilder replay = new StringBuilder();
|
---|
49 | replay.append("<Step>" + StringTools.ENDLINE);
|
---|
50 | replay.append("<EventId>" + eventId + "</EventId>" + StringTools.ENDLINE);
|
---|
51 | replay.append("<ReachingStep>false</ReachingStep>" + StringTools.ENDLINE);
|
---|
52 | replay.append("</Step>" + StringTools.ENDLINE);
|
---|
53 | return replay.toString();
|
---|
54 | }
|
---|
55 |
|
---|
56 | /*
|
---|
57 | * (non-Javadoc)
|
---|
58 | *
|
---|
59 | * @see de.ugoe.cs.eventbench.data.IReplayable#getTarget()
|
---|
60 | */
|
---|
61 | @Override
|
---|
62 | public String getTarget() {
|
---|
63 | return null; // target indirectly included in replay through the eventId
|
---|
64 | }
|
---|
65 |
|
---|
66 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.