[Zope3-checkins] SVN: Zope3/trunk/src/zope/wfmc/ Fixed a few more typos and removed some trailing whitespace.

Marius Gedminas marius at pov.lt
Fri Dec 2 15:35:45 EST 2005


Log message for revision 40506:
  Fixed a few more typos and removed some trailing whitespace.
  
  

Changed:
  U   Zope3/trunk/src/zope/wfmc/adapter/integration.txt
  U   Zope3/trunk/src/zope/wfmc/interfaces.py
  U   Zope3/trunk/src/zope/wfmc/process.py

-=-
Modified: Zope3/trunk/src/zope/wfmc/adapter/integration.txt
===================================================================
--- Zope3/trunk/src/zope/wfmc/adapter/integration.txt	2005-12-02 19:35:04 UTC (rev 40505)
+++ Zope3/trunk/src/zope/wfmc/adapter/integration.txt	2005-12-02 20:35:44 UTC (rev 40506)
@@ -70,9 +70,9 @@
 application id.  Workflow items provide a `start` method, which is
 used to start the work and pass input arguments.  It is the
 responsibility of the work item, at some later time, to call the
-`workitemFinished` method on the activity, to notify the activity that
+`workItemFinished` method on the activity, to notify the activity that
 the work item was completed. Output parameters are passed to the
-`workitemFinished` method.
+`workItemFinished` method.
 
 Let's implement participants for our process. We'll start with a
 generic participant:

Modified: Zope3/trunk/src/zope/wfmc/interfaces.py
===================================================================
--- Zope3/trunk/src/zope/wfmc/interfaces.py	2005-12-02 19:35:04 UTC (rev 40505)
+++ Zope3/trunk/src/zope/wfmc/interfaces.py	2005-12-02 20:35:44 UTC (rev 40506)
@@ -23,14 +23,14 @@
     """Integration of a workflow definition with an application environment
 
     ``IIntegration`` objects provide methods for integrating workflow
-    process definition with an application environment. 
+    process definition with an application environment.
     """
 
-    
+
     def createParticipant(activity, process_definition_identifier, performer):
         """Create a participant for an activity
 
-        The process id and especially the perfomer (id) are used to
+        The process id and especially the performer (id) are used to
         select an appropriate participant type.
         """
 
@@ -92,7 +92,7 @@
         Activity definitions are supplied as keyword arguments.  The
         keywords provide activity identifiers.  The values are
         IActivityDefinition objects.
-        
+
         """
 
     def defineTransitions(*transitions):
@@ -122,10 +122,10 @@
     def defineParameters(*parameters):
         """Declate process parameters
 
-        Input parameters are set as workflow-relevent data.  Output
+        Input parameters are set as workflow-relevant data.  Output
         parameters are passed from workflow-relevant data to the
         processFinished method of process-instances process contexts.
-        
+
         """
 
 class IActivityDefinition(interface.Interface):
@@ -138,7 +138,7 @@
         """Declare that the activity uses the identified activity
 
         The application identifier must match an application declared
-        for the process.  
+        for the process.
 
         Parameter definitions can be given as positional arguments.
         The parameter definition directions must match those given in
@@ -187,16 +187,16 @@
 
         Object with attributes containing data used to pass data as
         shared data for applications
-        
+
         """
         )
 
 class IProcessContext(interface.Interface):
-    """Object that can recieve process results.
+    """Object that can receive process results.
     """
 
     def processFinished(process, *results):
-        """Recieve notification of process completion, with results
+        """Receive notification of process completion, with results
         """
 
 class IActivity(interface.Interface):
@@ -259,7 +259,7 @@
         This identifier is set by the activity instance
 
         """)
- 
+
     def start(*arguments):
         """Start the work
         """

Modified: Zope3/trunk/src/zope/wfmc/process.py
===================================================================
--- Zope3/trunk/src/zope/wfmc/process.py	2005-12-02 19:35:04 UTC (rev 40505)
+++ Zope3/trunk/src/zope/wfmc/process.py	2005-12-02 20:35:44 UTC (rev 40506)
@@ -76,11 +76,11 @@
 
     def _start(self):
         # Return an initial transition
-        
+
         activities = self.activities
 
         # Find the start, making sure that there is one and that there
-        # aren't any activities w no transitions:
+        # aren't any activities with no transitions:
         start = ()
         for aid, activity in activities.items():
             if not activity.incoming:
@@ -98,9 +98,9 @@
             else:
                 raise interfaces.InvalidProcessDefinition(
                     "No start activities")
-                
+
         return TransitionDefinition(None, start[0][0])
-        
+
     _start = zope.cachedescriptors.property.Lazy(_start)
 
     def __call__(self, context=None):
@@ -139,7 +139,7 @@
             raise TypeError("Wrong number of parameters => "
                             "Actual=%s, Formal=%s for Application %s with id=%s"
                             %(actual, formal, app, app.id))
-        self.applications += ((application, formal, tuple(actual)), ) 
+        self.applications += ((application, formal, tuple(actual)), )
 
     def definePerformer(self, performer):
         self.performer = performer
@@ -159,14 +159,14 @@
             for tid in self.explicit_outgoing:
                 transition = transitions.get(tid)
                 if transition is not None:
-                    self.outgoing += (transition,)                    
+                    self.outgoing += (transition,)
         else:
             self.outgoing = self.transition_outgoing
 
     def __repr__(self):
         return "<ActivityDefinition %r>" %self.__name__
 
-        
+
 def always_true(data):
     return True
 
@@ -183,7 +183,7 @@
     def __repr__(self):
         return "TransitionDefinition(from=%r, to=%r)" %(self.from_, self.to)
 
-        
+
 class Process(persistent.Persistent):
 
     interface.implements(interfaces.IProcess)
@@ -229,20 +229,20 @@
                 outputs.append(
                     getattr(self.workflowRelevantData,
                             parameter.__name__))
-        
+
         return outputs
 
     def _finish(self):
         if self.context is not None:
             self.context.processFinished(self, *self.outputs())
-            
+
         zope.event.notify(ProcessFinished(self))
-        
-        
+
+
     def transition(self, activity, transitions):
         if transitions:
             definition = self.definition
-            
+
             for transition in transitions:
                 activity_definition = definition.activities[transition.to]
                 next = None
@@ -294,8 +294,8 @@
 
     def __repr__(self):
         return "ProcessFinished(%r)" % self.process
-        
 
+
 class Activity(persistent.Persistent):
 
     interface.implements(interfaces.IActivity)
@@ -310,22 +310,22 @@
         if definition.applications:
 
             participant = integration.createParticipant(
-                self, 
+                self,
                 process.process_definition_identifier,
                 definition.performer,
                 )
-                
+
             i = 0
             for application, formal, actual in definition.applications:
                 workitem = integration.createWorkItem(
-                    participant, 
+                    participant,
                     process.process_definition_identifier,
                     application,
                     )
                 i += 1
                 workitem.id = i
                 workitems[i] = workitem, application, formal, actual
-        
+
         self.workitems = workitems
 
     def definition(self):
@@ -351,7 +351,7 @@
                 return # not enough incoming yet
 
         zope.event.notify(ActivityStarted(self))
-        
+
         if self.workitems:
             for workitem, app, formal, actual in self.workitems.values():
                 args = []
@@ -379,7 +379,7 @@
 
         zope.event.notify(WorkItemFinished(
             work_item, app, actual, results))
-        
+
         if not self.workitems:
             self.finish()
 
@@ -463,7 +463,7 @@
 class Application:
 
     interface.implements(interfaces.IApplicationDefinition)
-    
+
     def __init__(self, *parameters):
         self.parameters = parameters
 
@@ -474,10 +474,10 @@
         input = u', '.join([param.__name__ for param in self.parameters
                            if param.input == True])
         output = u', '.join([param.__name__ for param in self.parameters
-                           if param.output == True])        
+                           if param.output == True])
         return "<Application %r: (%s) --> (%s)>" %(self.__name__, input, output)
-        
 
+
 class Participant:
 
     interface.implements(interfaces.IParticipantDefinition)



More information about the Zope3-Checkins mailing list