Class Anonymize
Object
org.anchoranalysis.bean.AnchorBean<CopyFilesNaming<T>>
org.anchoranalysis.plugin.io.bean.file.copy.naming.CopyFilesNaming<AnonymizeSharedState>
org.anchoranalysis.plugin.io.bean.file.copy.naming.Anonymize
public class Anonymize extends CopyFilesNaming<AnonymizeSharedState>
Copies files to a number
001, 002 etc. in the same order they are inputted.
No shuffling occurs.
- Author:
- Owen Feehan
-
Constructor Summary
Constructors Constructor Description Anonymize() -
Method Summary
Modifier and Type Method Description AnonymizeSharedStatebeforeCopying(Path destinationDirectory, List<org.anchoranalysis.io.input.file.FileWithDirectoryInput> inputs)To be called once before any calls toCopyFilesNaming.destinationPath(File, DirectoryWithPrefix, int, CopyContext).Optional<Path>destinationPathRelative(File file, org.anchoranalysis.io.output.path.prefixer.DirectoryWithPrefix outputTarget, int iter, CopyContext<AnonymizeSharedState> context)Calculates the relative-output path (to be appended to destDir)Methods inherited from class org.anchoranalysis.plugin.io.bean.file.copy.naming.CopyFilesNaming
destinationPath
-
Constructor Details
-
Anonymize
public Anonymize()
-
-
Method Details
-
beforeCopying
public AnonymizeSharedState beforeCopying(Path destinationDirectory, List<org.anchoranalysis.io.input.file.FileWithDirectoryInput> inputs)Description copied from class:CopyFilesNamingTo be called once before any calls toCopyFilesNaming.destinationPath(File, DirectoryWithPrefix, int, CopyContext).- Specified by:
beforeCopyingin classCopyFilesNaming<AnonymizeSharedState>- Parameters:
destinationDirectory- the directory to which files are copied.inputs- the total number of files to copy.
-
destinationPathRelative
public Optional<Path> destinationPathRelative(File file, org.anchoranalysis.io.output.path.prefixer.DirectoryWithPrefix outputTarget, int iter, CopyContext<AnonymizeSharedState> context) throws org.anchoranalysis.io.output.error.OutputWriteFailedExceptionDescription copied from class:CopyFilesNamingCalculates the relative-output path (to be appended to destDir)- Specified by:
destinationPathRelativein classCopyFilesNaming<AnonymizeSharedState>- Parameters:
file- file to be copiedoutputTarget- the directory and prefix associated with the file for outputtingiter- an increasing sequence of numbers for each file beginning at 0context- the context for the copying- Returns:
- the relative-path. if empty, the file should be skipped.
- Throws:
org.anchoranalysis.io.output.error.OutputWriteFailedException
-