Codestellation.Ether.Misc.FolderChangedTrigger.Attach C# (CSharp) Method

Attach() public method

public Attach ( ITriggerHander handler ) : void
handler ITriggerHander
return void
        public void Attach(ITriggerHander handler)
        {
            _handlers.Add(handler);
        }

Usage Example

        public void Setup()
        {
            _folderPath = Path.Combine(Path.GetTempPath(), Guid.NewGuid().ToString("N"));
            _filePath = Path.Combine(_folderPath, "test.txt");
            Directory.CreateDirectory(_folderPath);

            _trigger = new FolderChangedTrigger(_folderPath, "*.*");
            _trigger.Attach(this);
        }
All Usage Examples Of Codestellation.Ether.Misc.FolderChangedTrigger::Attach