Game Development Reference
In-Depth Information
Table 17.3 Method Definitions (continued)
Method
Description
Cancel
This method is fairly self-explanatory; it cancels all remaining operations that
have not yet been started, and it sets the Cancelled property so that the
worker function knows that it should either stop what it is doing or finish up.
Notify
This method is called by the worker function to fire the OnNotify event. As long
as the tool has set this delegate to a function, it will fire when a notification is sent.
The following code composes the file access interface that powers the logic behind
each batch processing tool. This interface is implemented and customized for each
tool.
using System;
using System.IO;
namespace BatchFileFramework
{
public delegate void FileAccessProcess(IFileAccessLogic logic, FileInfo fileInfo);
public delegate void FileAccessNotify(string message);
public interface IFileAccessLogic
{
bool Recursive
{
get;
set;
}
bool SkipReadOnly
{
get;
set;
}
bool ForceWriteable
{
get;
set;
}
Search Nedrilad ::




Custom Search