Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
PerformRI |
|
| 0.0;0 |
1 | /* | |
2 | wsmo4j extension - a Choreography API and Reference Implementation | |
3 | ||
4 | Copyright (c) 2005, University of Innsbruck, Austria | |
5 | ||
6 | This library is free software; you can redistribute it and/or modify it under | |
7 | the terms of the GNU Lesser General Public License as published by the Free | |
8 | Software Foundation; either version 2.1 of the License, or (at your option) | |
9 | any later version. | |
10 | This library is distributed in the hope that it will be useful, but WITHOUT | |
11 | ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS | |
12 | FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more | |
13 | details. | |
14 | You should have received a copy of the GNU Lesser General Public License along | |
15 | with this library; if not, write to the Free Software Foundation, Inc., | |
16 | 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
17 | */ | |
18 | ||
19 | package org.deri.wsmo4j.rule; | |
20 | ||
21 | import org.deri.wsmo4j.io.serializer.wsml.*; | |
22 | import org.wsmo.common.*; | |
23 | import org.wsmo.service.rule.*; | |
24 | ||
25 | /** | |
26 | * Perform Implementation. | |
27 | * | |
28 | * <pre> | |
29 | * Created on Jul 26, 2005 | |
30 | * Committed by $Author: haselwanter $ | |
31 | * $Source$ | |
32 | * </pre> | |
33 | * | |
34 | * @author Thomas Haselwanter | |
35 | * | |
36 | * @version $Revision: 1859 $ $Date: 2006-11-03 15:43:37 +0200 (Fri, 03 Nov 2006) $ | |
37 | */ | |
38 | public abstract class PerformRI implements Perform { | |
39 | ||
40 | private IRI performance; | |
41 | ||
42 | /** | |
43 | * @param fact | |
44 | * A CompoundFact object defining the fact of the Add rule | |
45 | */ | |
46 | public PerformRI(IRI performance) { | |
47 | 0 | super(); |
48 | 0 | this.performance = performance; |
49 | 0 | } |
50 | ||
51 | /* | |
52 | * (non-Javadoc) | |
53 | * | |
54 | * @see org.wsmo.service.choreography.rule.Rule#accept(org.wsmo.service.choreography.rule.Visitor) | |
55 | */ | |
56 | public abstract void accept(Visitor visitor); | |
57 | ||
58 | /* (non-Javadoc) | |
59 | * @see org.wsmo.service.choreography.rule.Rule#toString(org.wsmo.common.TopEntity) | |
60 | */ | |
61 | public String toString(TopEntity te) { | |
62 | 0 | VisitorSerializeWSMLTransitionRules visitor = new VisitorSerializeWSMLTransitionRules(te); |
63 | 0 | visitor.visitPerform(this); |
64 | 0 | return visitor.getSerializedObject(); |
65 | } | |
66 | ||
67 | @Override | |
68 | public String toString() { | |
69 | 0 | return toString(null); |
70 | } | |
71 | ||
72 | public IRI getPerformIRI() { | |
73 | 0 | return performance; |
74 | } | |
75 | ||
76 | public void setPerformIRI(IRI iri) { | |
77 | 0 | performance = iri; |
78 | ||
79 | 0 | } |
80 | } |