org.squashtest.tm.service.internal.campaign
Interface CampaignNodeDeletionHandler

All Superinterfaces:
NodeDeletionHandler<org.squashtest.tm.domain.campaign.CampaignLibraryNode,org.squashtest.tm.domain.campaign.CampaignFolder>
All Known Implementing Classes:
CampaignDeletionHandlerImpl

public interface CampaignNodeDeletionHandler
extends NodeDeletionHandler<org.squashtest.tm.domain.campaign.CampaignLibraryNode,org.squashtest.tm.domain.campaign.CampaignFolder>

The following specialization for NodeDeletionHandler, meant for the campaigns, will also handle the deletion of campaign related entities like Iterations and Executions. Thus the contract of the interface NodeDeletionHandler is extended for those entities. First, some definitions :

In the context of a targeted deletion, Iterations and Executions may require a preview of the deletion operation just like the other library nodes, so they both a simulateIterationDeletion and simulateExecutionDeletion methods, which both obey to the same specifications than NodeDeletionHandler.simulateDeletion(List). However, while Iterations are candidates to mass-deletion, Executions are always deleted one at a time. That's why deleteExecution(Execution) have a different contract to enforce this. On the other hand, in the context of a cascade deletion both Iterations and Executions will be removed en masse. Further remarks : The disassociation an IterationTestPlanItem from an Iteration is already handled by IterationTestPlanManager. However the implementation of this interface should also take care of these entities in the context of a cascade removal. Same remark goes for CampaignTestPlanItem.

Author:
bsiri

Method Summary
 void deleteExecution(org.squashtest.tm.domain.execution.Execution execution)
          That method should delete the execution.
 void deleteExecutions(List<org.squashtest.tm.domain.execution.Execution> executions)
          uses deleteExecution(Execution)
 OperationReport deleteIterations(List<Long> targetIds)
          That method should delete the iterations.
 void deleteIterationTestPlanItem(org.squashtest.tm.domain.campaign.IterationTestPlanItem item)
          That method should delete the test plan item.
 OperationReport deleteSuites(List<Long> suiteIds)
          That method should delete test suites, and remove its references in iteration and iteration test plan item
 List<SuppressionPreviewReport> simulateExecutionDeletion(Long execId)
          That method should investigate the consequences of the deletion of the given executions, and return a report about what will happen.
 List<SuppressionPreviewReport> simulateIterationDeletion(List<Long> targetIds)
          That method should investigate the consequences of the deletion of the given iterations, and return a report about what will happen.
 List<SuppressionPreviewReport> simulateSuiteDeletion(List<Long> targetIds)
          That method should investigate the consequences of the deletion of the given test suites, and return a report about what will happen.
 
Methods inherited from interface org.squashtest.tm.service.internal.library.NodeDeletionHandler
deleteNodes, simulateDeletion
 

Method Detail

simulateIterationDeletion

List<SuppressionPreviewReport> simulateIterationDeletion(List<Long> targetIds)
That method should investigate the consequences of the deletion of the given iterations, and return a report about what will happen.

Parameters:
targetIds -
Returns:

deleteIterations

OperationReport deleteIterations(List<Long> targetIds)
That method should delete the iterations. It still takes care of non deletable iterations so the implementation should filter out the ids that can't be deleted.

Parameters:
targetIds -
Returns:

deleteIterationTestPlanItem

void deleteIterationTestPlanItem(org.squashtest.tm.domain.campaign.IterationTestPlanItem item)
That method should delete the test plan item. It will remove the executions along with the test plan item.

Parameters:
item - : the IterationTestPlanItem to delete

simulateExecutionDeletion

List<SuppressionPreviewReport> simulateExecutionDeletion(Long execId)
That method should investigate the consequences of the deletion of the given executions, and return a report about what will happen.

Parameters:
targetIds -
Returns:

deleteExecution

void deleteExecution(org.squashtest.tm.domain.execution.Execution execution)
That method should delete the execution. It still takes care of non deletable executions so the implementation should abort if the execution can't be deleted.

Parameters:
targetIds -
Throws:
RuntimeException - if the execution should not be deleted.

deleteExecutions

void deleteExecutions(List<org.squashtest.tm.domain.execution.Execution> executions)
uses deleteExecution(Execution)

Parameters:
executions -

simulateSuiteDeletion

List<SuppressionPreviewReport> simulateSuiteDeletion(List<Long> targetIds)
That method should investigate the consequences of the deletion of the given test suites, and return a report about what will happen.

Parameters:
targetIds -
Returns:

deleteSuites

OperationReport deleteSuites(List<Long> suiteIds)
That method should delete test suites, and remove its references in iteration and iteration test plan item

Parameters:
testSuites -
Returns:


Copyright © 2010-2013 Henix, henix.fr. All Rights Reserved.