001: /*
002: * This file is part of the WfMOpen project.
003: * Copyright (C) 2001-2003 Danet GmbH (www.danet.de), GS-AN.
004: * All rights reserved.
005: *
006: * This program is free software; you can redistribute it and/or modify
007: * it under the terms of the GNU General Public License as published by
008: * the Free Software Foundation; either version 2 of the License, or
009: * (at your option) any later version.
010: *
011: * This program is distributed in the hope that it will be useful,
012: * but WITHOUT ANY WARRANTY; without even the implied warranty of
013: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
014: * GNU General Public License for more details.
015: *
016: * You should have received a copy of the GNU General Public License
017: * along with this program; if not, write to the Free Software
018: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
019: *
020: * $Id: WfProcessMgr.java,v 1.3 2007/03/27 21:59:44 mlipp Exp $
021: *
022: * $Log: WfProcessMgr.java,v $
023: * Revision 1.3 2007/03/27 21:59:44 mlipp
024: * Fixed lots of checkstyle warnings.
025: *
026: * Revision 1.2 2006/09/29 12:32:09 drmlipp
027: * Consistently using WfMOpen as projct name now.
028: *
029: * Revision 1.1.1.1 2003/06/30 20:05:16 drmlipp
030: * Initial import
031: *
032: * Revision 1.13 2003/06/27 08:51:45 lipp
033: * Fixed copyright/license information.
034: *
035: * Revision 1.12 2003/04/26 16:11:14 lipp
036: * Moved some classes to reduce package dependencies.
037: *
038: * Revision 1.11 2002/11/26 11:23:29 lipp
039: * Modified RemoteException comment.
040: *
041: * Revision 1.10 2002/07/24 08:04:42 huaiyang
042: * doccheck.
043: *
044: * Revision 1.9 2002/07/23 11:53:42 huaiyang
045: * Add javadocs.
046: *
047: * Revision 1.8 2002/04/03 12:53:05 lipp
048: * JavaDoc fixes.
049: *
050: * Revision 1.7 2002/02/04 14:22:14 lipp
051: * Fixed setProcessMgrState method signature.
052: *
053: * Revision 1.6 2001/10/06 11:40:29 lipp
054: * Some javadoc fixes.
055: *
056: * Revision 1.5 2001/08/24 12:58:30 lipp
057: * CR/NL fixes
058: *
059: * Revision 1.4 2001/07/30 08:15:30 montag
060: * Enums added.
061: *
062: * Revision 1.3 2001/07/26 21:00:08 lipp
063: * Added Exceptions
064: *
065: * Revision 1.2 2001/07/26 15:57:40 lipp
066: * Methods returning Collections renamed.
067: *
068: * Revision 1.1 2001/07/06 08:51:49 lipp
069: * Moved from domain to omgcore
070: *
071: * Revision 1.2 2001/07/05 14:15:10 lipp
072: * Rather complete version.
073: *
074: * Revision 1.1 2001/07/04 16:08:05 lipp
075: * Compilable version
076: *
077: */
078: package de.danet.an.workflow.omgcore;
079:
080: import java.rmi.RemoteException;
081: import java.util.Collection;
082:
083: /**
084: * A <code>WfProcessMgr</code> represents a template for a specific
085: * workflow process; it is used to create instances of a workflow
086: * process. Logically it is the factory and locator for
087: * {@link de.danet.an.workflow.omgcore.WfProcess <code>WfProcess</code>}
088: * instances.
089: **/
090: public interface WfProcessMgr extends WfObject {
091: /** Indicates that creation of workflow processes is disabled.*/
092: public static final int DISABLED = 0;
093: /** Indicates that creation of workflow processes is enabled. */
094: public static final int ENABLED = 1;
095:
096: /**
097: * Returns a collection with <code>WfProcess</code> objects from this
098: * process manager.
099: * @return a Collection object of <code>WfProcess</code>.
100: * @throws RemoteException if a system-level error occurs.
101: */
102: public Collection processes() throws RemoteException;
103:
104: /**
105: * Returns the state of the <code>WfProcessMgr</code>.
106: * @return WfProcessMgr.ENABLED if creation of workflow processes is
107: * enabled, otherwise WfProcessMgr.DISABLED.
108: * @throws RemoteException if a system-level error occurs.
109: */
110: public int processMgrState() throws RemoteException;
111:
112: /**
113: * Set the new state of this process manager.
114: * @param newState the new state.
115: * @throws RemoteException if a system-level error occurs.
116: * @throws TransitionNotAllowedException if the transition is not allowed
117: */
118: public void setProcessMgrState(int newState)
119: throws RemoteException, TransitionNotAllowedException;
120:
121: /**
122: * Returns the name of the process manager.
123: * @return the name.
124: * @throws RemoteException if a system-level error occurs.
125: */
126: public String name() throws RemoteException;
127:
128: /**
129: * Returns the description of the process manager.
130: * @return the description.
131: * @throws RemoteException if a system-level error occurs.
132: */
133: public String description() throws RemoteException;
134:
135: /**
136: * Return the category of a process manager used for classification of
137: * process types. It is set when the process manager is initialized and
138: * cannot be modified.
139: * @return the string of category.
140: * @throws RemoteException if a system-level error occurs.
141: */
142: public String category() throws RemoteException;
143:
144: /**
145: * Return the version attribute of a process manager used to distinguish
146: * between different versions of a process model.
147: * @return the version.
148: * @throws RemoteException if a system-level error occurs.
149: */
150: public String version() throws RemoteException;
151:
152: /**
153: * Returns the meta information that defines how to set the context of an
154: * instance.
155: * @return the process meta information.
156: * @throws RemoteException if a system-level error occurs.
157: */
158: public ProcessDataInfo contextSignature() throws RemoteException;
159:
160: /**
161: * Returns the meta information that specifies how instances will return
162: * results.
163: * @return the process meta information.
164: * @throws RemoteException if a system-level error occurs.
165: */
166: public ProcessDataInfo resultSignature() throws RemoteException;
167:
168: /**
169: * Create instances of a process and link its requester.
170: * @param requester the requester to create process.
171: * @return the created process.
172: * @throws RemoteException if a system-level error occurs.
173: * @throws NotEnabledException when the process manager is disabled.
174: * @throws InvalidRequesterException when the process definition requires
175: * a <code>WfRequester</code> and an invalid <code>WfRequester</code> is
176: * supplied in the parameter.
177: * @throws RequesterRequiredException when a <code>WfRequester</code> is
178: * being identified that cannot be a parent of instances of the process.
179: */
180: public WfProcess createProcess(WfRequester requester)
181: throws RemoteException, NotEnabledException,
182: InvalidRequesterException, RequesterRequiredException;
183:
184: /**
185: * @link aggregation
186: * @clientCardinality 1
187: * @supplierCardinality 0..*
188: */
189: /*#WfProcess lnkWfProcess;*/
190:
191: /**
192: * @clientCardinality 1
193: * @supplierCardinality 1
194: * @supplierQualifier result data signature
195: */
196: /*#ProcessDataInfo lnkProcessDataInfo;*/
197:
198: /**
199: * @supplierCardinality 1
200: * @clientCardinality 1
201: * @supplierQualifier context data signature
202: */
203: /*#ProcessDataInfo lnkProcessDataInfo1;*/
204: }
|