public class AnonymizePluginPointsStep extends Object implements AnonymizeOperationStep
Constructor and Description |
---|
AnonymizePluginPointsStep(UserAnonymizationService userAnonymizationService) |
Modifier and Type | Method and Description |
---|---|
ServiceOutcomeWithWarnings<Collection<AffectedEntity>> |
getAffectedEntities(AnonymizeUserService.AnonymizeProcessData anonymizationData)
Gets affected entities for this action.
|
AnonymizeUserService.AnonymizeOperation |
getAnonymizeOperation()
Type of operation this handler supports.
|
int |
getNumberOfTasks(AnonymizeUserService.AnonymizeValidationResult validationResult)
Returns number of tasks/stages to be executed as part of this anonymization step.
|
Optional<AnonymizeUserService.SingleOperationReport<Void>> |
performOperation(AnonymizeUserService.OperationsReport<Void> anonymizeReport,
AnonymizeUserService.AnonymizeValidationResult validationResult)
Performs operations only if all proper parameters are filled in passed parameters.
|
ServiceResult |
validate(AnonymizeUserService.AnonymizeProcessData anonymizationProcessData,
I18nHelper i18nHelper,
boolean preValidate)
Validate should ensure that request and anonymizationProcessData contain all data needed to
#performOperation(AnonymizeUserService.OperationsReport, AnonymizeValidationResult) . |
public AnonymizePluginPointsStep(UserAnonymizationService userAnonymizationService)
@Nonnull public Optional<AnonymizeUserService.SingleOperationReport<Void>> performOperation(@Nonnull AnonymizeUserService.OperationsReport<Void> anonymizeReport, @Nonnull AnonymizeUserService.AnonymizeValidationResult validationResult)
AnonymizeOperationStep
AnonymizeOperationStep.validate(AnonymizeUserService.AnonymizeProcessData, I18nHelper, boolean)
should be called prior this method to ensure that
all required parameters to perform operation are present.performOperation
in interface AnonymizeOperationStep
anonymizeReport
- Anonymization report, can be used to check if previous operations were executed/succeeded/failed.validationResult
- Validation result. See AnonymizeUserService.validateAnonymize(AnonymizeUserRequest)
@Nonnull public ServiceResult validate(@Nonnull AnonymizeUserService.AnonymizeProcessData anonymizationProcessData, I18nHelper i18nHelper, boolean preValidate)
AnonymizeOperationStep
#performOperation(AnonymizeUserService.OperationsReport, AnonymizeValidationResult)
.
Also validates if system allows specific operation eg. in order for user to be renamed it has to be editable in system.validate
in interface AnonymizeOperationStep
anonymizationProcessData
- Data to validate.i18nHelper
- I18n helperpreValidate
- True for pre-validation phase. See AnonymizeUserService.preValidateAnonymize(AnonymizeUserRequest)
@Nonnull public ServiceOutcomeWithWarnings<Collection<AffectedEntity>> getAffectedEntities(AnonymizeUserService.AnonymizeProcessData anonymizationData)
AnonymizeOperationStep
getAffectedEntities
in interface AnonymizeOperationStep
anonymizationData
- Anonymization data.@Nonnull public AnonymizeUserService.AnonymizeOperation getAnonymizeOperation()
AnonymizeOperationStep
getAnonymizeOperation
in interface AnonymizeOperationStep
public int getNumberOfTasks(@Nonnull AnonymizeUserService.AnonymizeValidationResult validationResult)
AnonymizeOperationStep
#performOperation(AnonymizeUserService.OperationsReport, AnonymizeValidationResult)
.getNumberOfTasks
in interface AnonymizeOperationStep
validationResult
- Validation resultCopyright © 2002-2019 Atlassian. All Rights Reserved.