collectionType.setParentID(projectId);
collectionType.setLEADresource(workflowCollResourceType);
OperationResponseDocument outputMsg = createStub(userID).createCollections(createColl);
OperationResponseType outputType = outputMsg.getOperationResponse();
StatusEnumType.Enum statusType = outputType.getStatus();
if (statusType.equals(StatusEnumType.SUCCESS)) {
String[] resourceIDs = outputType.getResourceIDArray();
for (String collectionId : resourceIDs) {
logger.finest("Workflow Collection Id is " + collectionId);
collectionResourceId = collectionId;
}
if (outputType.isSetMessage()) {
logger.finest("Add collection message is = " + outputType.getMessage());
}
} else {
if (outputType.isSetMessage()) {
logger.severe("An error occurred when trying to create the "
+ "workflow templates collection for the Sample: " + outputType.getMessage());
}
if (outputType.isSetOperationSummary()) {
logger.severe("An error occurred when trying to create the "
+ "workflow templates collection for the Sample: " + outputType.getOperationSummary());
}
if (outputType.isSetOperationSummaryStreamUrl()) {
logger.severe("An error occurred when trying to create the "
+ "workflow templates collection for the Sample: " + outputType.getOperationSummaryStreamUrl());
}
}
} catch (Exception e) {
logger.caught(e);
throw new MyLeadException(e);