CmisSync.Lib.RepoInfo.addIgnorePath C# (CSharp) Method

addIgnorePath() public method

Adds a new path to the list of paths, which should be ignored. It has to be a absolute path from the repoID on with a leading slash. Path separator must also be a slash.
public addIgnorePath ( string path ) : void
path string
return void
        public void addIgnorePath(string path)
        {
            if(!this.ignoredPaths.Contains(path))
                this.ignoredPaths.Add(path);
        }

Usage Example

Esempio n. 1
0
        /// <summary>
        /// Get all the configured info about a synchronized folder.
        /// </summary>
        public RepoInfo GetRepoInfo(string folderName)
        {
            RepoInfo repoInfo = new RepoInfo(folderName, ConfigPath);

            repoInfo.User            = GetFolderAttribute(folderName, "user");
            repoInfo.Password        = GetFolderAttribute(folderName, "password");
            repoInfo.Address         = GetUrlForFolder(folderName);
            repoInfo.RepoID          = GetFolderAttribute(folderName, "repository");
            repoInfo.RemotePath      = GetFolderAttribute(folderName, "remoteFolder");
            repoInfo.TargetDirectory = GetFolderAttribute(folderName, "path");

            double pollinterval = 0;

            double.TryParse(GetFolderAttribute(folderName, "pollinterval"), out pollinterval);
            if (pollinterval < 1)
            {
                pollinterval = 5000;
            }
            repoInfo.PollInterval = pollinterval;

            if (String.IsNullOrEmpty(repoInfo.TargetDirectory))
            {
                repoInfo.TargetDirectory = Path.Combine(FoldersPath, folderName);
            }
            LinkedList <string> ignoredFolders = getIgnoredFolders(folderName);

            foreach (string ignoredFolder in ignoredFolders)
            {
                repoInfo.addIgnorePath(ignoredFolder);
            }
            return(repoInfo);
        }
All Usage Examples Of CmisSync.Lib.RepoInfo::addIgnorePath