|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.alfresco.bm.data.WorkflowDataService
public class WorkflowDataService
Service providing access to WorkflowData storage. All WorkflowData returned from and persisted
with this service will be testrun-specific. The testrun-identifier is set in the constructor.
| Constructor Summary | |
|---|---|
WorkflowDataService(org.springframework.data.mongodb.core.MongoTemplate mongo,
String collectionName,
String testRun)
|
|
| Method Summary | |
|---|---|
void |
checkIndexes()
Ensure that the MongoDB collection has the required indexes associated with the WorkflowData. |
long |
count()
Count the total number of workflows. |
long |
countFinishedWorkflows()
Count the total number of finished workflows. |
WorkflowData |
findById(String workflowId)
Find data by id. |
List<WorkflowData> |
findUnscheduledProcesses(int maxCount)
Find a number of unscheduled processes. |
void |
insert(WorkflowData data)
Insert the given WorkflowData object. |
void |
markWorkflowAsEnded(String id)
Mark a workflow as ended. |
void |
markWorkflowAsScheduled(String id,
String userName)
Mark a workflow as scheduled. |
void |
markWorkflowAsStarted(String id,
String workflowInstanceId)
Mark a workflow as started. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WorkflowDataService(org.springframework.data.mongodb.core.MongoTemplate mongo,
String collectionName,
String testRun)
| Method Detail |
|---|
public void checkIndexes()
WorkflowData.
mongo - connection to MongoDBcollectionName - name of DB collection containing datapublic WorkflowData findById(String workflowId)
workflowId - id of the workflow in mongo
public void markWorkflowAsStarted(String id,
String workflowInstanceId)
id - id of the workflow in mongoworkflowId - id of the workflow in alfresco
public void markWorkflowAsScheduled(String id,
String userName)
id - id of the workflow in mongouserName - name of the users that will run the workflowpublic void markWorkflowAsEnded(String id)
id - id of the workflow in mongopublic long count()
mongo - collectionName -
public long countFinishedWorkflows()
mongo - collectionName -
public void insert(WorkflowData data)
WorkflowData object. A new id will be assigned?
data - the data to insertpublic List<WorkflowData> findUnscheduledProcesses(int maxCount)
maxCount - maximum number of results that should be returned
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||