Click or drag to resize

IFileSystemFilterFilterAsync Method

IT Hit User File System
Allows filtering file system items.

Namespace:  ITHit.FileSystem
Assembly:  ITHit.FileSystem (in ITHit.FileSystem.dll) Version: 8.1.26901.0
Task<bool> FilterAsync(
	SyncDirection direction,
	OperationType operationType,
	string path,
	FileSystemItemType itemType,
	string newPath,
	IOperationContext operationContext


Type: ITHit.FileSystemSyncDirection
Indicates synchronization direction.
Type: ITHit.FileSystemOperationType
File system operation type: OperationType.
Type: SystemString
File system item path. In case of move and rename operation this is the source path.
Type: ITHit.FileSystemFileSystemItemType
Item type - file or folder.
Type: SystemString
Target file path. This parameter is provided only in case of Move and MoveCompletion operation. It is null for all other operations.
Type: ITHit.FileSystemIOperationContext
Provides additonal information if available, depending on the environment.

Return Value

Type: TaskBoolean
True if the item must NOT be synced to the remote storage. False - otherwise.

This method is called before calling GetFileSystemItemAsync(Byte, FileSystemItemType, IContext, ILogger) as well as each IFile, IFolder and ILock interface methods. If this method returns true, the method is NOT called.

You can use this method to exclude items from synchronization with the remote storage. For example you can exclude temporary files, hidden files, Microsoft Office lock files, backup files, etc.

The default Engine implementation returns false for all items.

See Also