Source Code Cross Referenced for ProcessImpl.java in  » Workflow-Engines » bexee » bexee » model » process » impl » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Workflow Engines » bexee » bexee.model.process.impl 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * $Id: ProcessImpl.java,v 1.12 2004/12/09 12:34:44 kowap Exp $
003:         *
004:         * Copyright (c) 2004 Patric Fornasier, Pawel Kowalski
005:         * Berne University of Applied Sciences
006:         * School of Engineering and Information Technology
007:         * All rights reserved.
008:         */
009:        package bexee.model.process.impl;
010:
011:        import bexee.core.ProcessController;
012:        import bexee.core.ProcessInstance;
013:        import bexee.model.BPELElementVisitor;
014:        import bexee.model.InvalidValueException;
015:        import bexee.model.activity.Activity;
016:        import bexee.model.activity.CompensationHandler;
017:        import bexee.model.elements.CorrelationSets;
018:        import bexee.model.elements.EventHandlers;
019:        import bexee.model.elements.FaultHandlers;
020:        import bexee.model.elements.PartnerLinks;
021:        import bexee.model.elements.Partners;
022:        import bexee.model.elements.Variables;
023:        import bexee.model.process.Process;
024:        import bexee.util.BooleanUtils;
025:        import bexee.util.StringUtils;
026:
027:        /**
028:         * A default implementation of a <code>Process</code>.
029:         * 
030:         * @version $Revision: 1.12 $, $Date: 2004/12/09 12:34:44 $
031:         * @author Patric Fornasier
032:         * @author Pawel Kowalski
033:         */
034:        public class ProcessImpl implements  Process {
035:
036:            private String name;
037:
038:            private String targetNamespace;
039:
040:            private String queryLanguage;
041:
042:            private String expressionLanguage;
043:
044:            private boolean isSuppressJoinFailure;
045:
046:            private boolean isInstanceCompensable;
047:
048:            private boolean isAbstractProcess;
049:
050:            private PartnerLinks partnerLinks;
051:
052:            private Partners partners;
053:
054:            private Variables variables;
055:
056:            private CorrelationSets correlationSets;
057:
058:            private FaultHandlers faultHandlers;
059:
060:            private CompensationHandler compensationHandler;
061:
062:            private EventHandlers eventHandlers;
063:
064:            private Activity activity;
065:
066:            //**************************************************/
067:            // c'tors
068:            //**************************************************/
069:
070:            public ProcessImpl() {
071:                this (null, null, null, null, null, null);
072:            }
073:
074:            /**
075:             * @param name2
076:             * @param targetNamespace2
077:             * @param queryLanguage2
078:             * @param expressionLanguage2
079:             * @param suppressJoinFailure2
080:             * @param enableInstanceCompensation
081:             */
082:            public ProcessImpl(String name, String targetNamespace,
083:                    String queryLanguage, String expressionLanguage,
084:                    String suppressJoinFailure,
085:                    String enableInstanceCompensation) {
086:
087:                this .name = name;
088:                this .targetNamespace = targetNamespace;
089:                this .queryLanguage = getValidValueOrDefault(queryLanguage,
090:                        DEFAULT_QUERY_LANGUAGE);
091:                this .expressionLanguage = getValidValueOrDefault(
092:                        expressionLanguage, DEFAULT_EXPRESSION_LANGUAGE);
093:                this .isSuppressJoinFailure = getValidValueOrDefault(
094:                        suppressJoinFailure, DEFAULT_SUPPRESS_JOIN_FAILURE);
095:                this .isInstanceCompensable = getValidValueOrDefault(
096:                        enableInstanceCompensation,
097:                        DEFAULT_ENABLE_INSTANCE_COMPENSATION);
098:            }
099:
100:            //**************************************************/
101:            // bexee.model.process.Process
102:            //**************************************************/
103:
104:            public void setName(String name) {
105:                this .name = name;
106:            }
107:
108:            public String getName() {
109:                return name;
110:            }
111:
112:            public void setTargetNamespace(String targetNamespace) {
113:                this .targetNamespace = targetNamespace;
114:            }
115:
116:            public String getTargetNamespace() {
117:                return targetNamespace;
118:            }
119:
120:            public void setQueryLanguage(String queryLanguage) {
121:                this .queryLanguage = queryLanguage;
122:            }
123:
124:            public String getQueryLanguage() {
125:                return queryLanguage;
126:            }
127:
128:            public void setExpressionLanguage(String expressionLanguage) {
129:                this .expressionLanguage = expressionLanguage;
130:            }
131:
132:            public String getExpressionLanguage() {
133:                return expressionLanguage;
134:            }
135:
136:            public void setSuppressJoinFailure(boolean suppressJoinFailure) {
137:                this .isSuppressJoinFailure = suppressJoinFailure;
138:            }
139:
140:            public boolean isSuppressJoinFailure() {
141:                return isSuppressJoinFailure;
142:            }
143:
144:            public void setEnableInstanceCompensation(
145:                    boolean isInstanceCompensable) {
146:                this .isInstanceCompensable = isInstanceCompensable;
147:            }
148:
149:            public boolean isInstanceCompensable() {
150:                return isInstanceCompensable;
151:            }
152:
153:            public void setAbstractProcess(boolean isAbstractProcess) {
154:                this .isAbstractProcess = isAbstractProcess;
155:            }
156:
157:            public boolean isAbstractProcess() {
158:                return isAbstractProcess;
159:            }
160:
161:            public void setPartnerLinks(PartnerLinks partnerLinks) {
162:                this .partnerLinks = partnerLinks;
163:            }
164:
165:            public PartnerLinks getPartnerLinks() {
166:                return partnerLinks;
167:            }
168:
169:            public void setPartners(Partners partners) {
170:                this .partners = partners;
171:            }
172:
173:            public Partners getPartners() {
174:                return partners;
175:            }
176:
177:            public void setVariables(Variables variables) {
178:                this .variables = variables;
179:            }
180:
181:            public Variables getVariables() {
182:                return variables;
183:            }
184:
185:            public void setCorrelationSets(CorrelationSets correlationSets) {
186:                this .correlationSets = correlationSets;
187:            }
188:
189:            public CorrelationSets getCorrelationSets() {
190:                return correlationSets;
191:            }
192:
193:            public void setFaultHandlers(FaultHandlers faultHandlers) {
194:                this .faultHandlers = faultHandlers;
195:            }
196:
197:            public FaultHandlers getFaultHandlers() {
198:                return faultHandlers;
199:            }
200:
201:            public void setCompensationHandler(
202:                    CompensationHandler compensationHandler) {
203:                this .compensationHandler = compensationHandler;
204:            }
205:
206:            public CompensationHandler getCompensationHandler() {
207:                return compensationHandler;
208:            }
209:
210:            public void setEventHandlers(EventHandlers eventHandlers) {
211:                this .eventHandlers = eventHandlers;
212:            }
213:
214:            public EventHandlers getEventHandlers() {
215:                return eventHandlers;
216:            }
217:
218:            public void activity(Activity activity) {
219:                setActivity(activity);
220:            }
221:
222:            public void setActivity(Activity activity) {
223:                this .activity = activity;
224:            }
225:
226:            public Activity getActivity() {
227:                return activity;
228:            }
229:
230:            //**************************************************/
231:            // bexee.model.BPELElement
232:            //**************************************************/
233:
234:            public void accept(ProcessController controller,
235:                    ProcessInstance instance) throws Exception {
236:                controller.process(this , instance);
237:            }
238:
239:            public void accept(BPELElementVisitor elementVisitor) {
240:                elementVisitor.visit(this );
241:            }
242:
243:            //**************************************************/
244:            // helper methods
245:            //**************************************************/
246:
247:            private String getValidValueOrDefault(String value,
248:                    String defaultValue) {
249:                if (StringUtils.isNullOrEmpty(value)) {
250:                    return defaultValue;
251:                } else {
252:                    return value;
253:                }
254:            }
255:
256:            private boolean getValidValueOrDefault(String value,
257:                    boolean defaultValue) {
258:                try {
259:                    return BooleanUtils.strictYesNoToBoolean(value);
260:                } catch (InvalidValueException e) {
261:                    return defaultValue;
262:                }
263:            }
264:
265:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.