Exemple #1
0
        internal static List <RetentionPolicyTag> FindRetentionPolicyTag(IConfigurationSession session, Guid tagGuid)
        {
            OrFilter filter = new OrFilter(new QueryFilter[]
            {
                new ComparisonFilter(ComparisonOperator.Equal, RetentionPolicyTagSchema.RetentionId, tagGuid),
                new ComparisonFilter(ComparisonOperator.Equal, ADObjectSchema.Guid, tagGuid)
            });

            return(ELCTaskHelper.FindElcObject <RetentionPolicyTag>(session, null, filter));
        }
Exemple #2
0
        internal static List <ELCFolder> FindELCFolder(IConfigurationSession session, ADObjectId rootId, object valueToSearch, FindByType findByType)
        {
            QueryFilter filter;

            switch (findByType)
            {
            case FindByType.Name:
                filter = new ComparisonFilter(ComparisonOperator.Equal, ADObjectSchema.Name, (string)valueToSearch);
                goto IL_D4;

            case FindByType.FolderName:
                filter = new OrFilter(new QueryFilter[]
                {
                    new ComparisonFilter(ComparisonOperator.Equal, ELCFolderSchema.FolderName, (string)valueToSearch),
                    new TextFilter(ELCFolderSchema.LocalizedFolderName, (string)valueToSearch, MatchOptions.SubString, MatchFlags.IgnoreCase)
                });
                goto IL_D4;

            case FindByType.FolderType:
                filter = new ComparisonFilter(ComparisonOperator.Equal, ELCFolderSchema.FolderType, (ElcFolderType)valueToSearch);
                goto IL_D4;

            case FindByType.FolderAdObjectId:
                filter = new ComparisonFilter(ComparisonOperator.Equal, ADObjectSchema.Id, valueToSearch as ADObjectId);
                goto IL_D4;

            case FindByType.FolderDefaultType:
                filter = new ComparisonFilter(ComparisonOperator.NotEqual, ELCFolderSchema.FolderType, ElcFolderType.ManagedCustomFolder);
                goto IL_D4;

            case FindByType.FolderOrganizationalType:
                filter = new ComparisonFilter(ComparisonOperator.Equal, ELCFolderSchema.FolderType, ElcFolderType.ManagedCustomFolder);
                goto IL_D4;
            }
            filter = null;
IL_D4:
            return(ELCTaskHelper.FindElcObject <ELCFolder>(session, rootId, filter));
        }
Exemple #3
0
        internal static List <ElcContentSettings> FindELCContentSettings(IConfigurationSession session, string name)
        {
            QueryFilter filter = new ComparisonFilter(ComparisonOperator.Equal, ADObjectSchema.Name, name);

            return(ELCTaskHelper.FindElcObject <ElcContentSettings>(session, null, filter));
        }