public OutlookContactRepository(IOutlookSession session, string folderId, string folderStoreId, IDaslFilterProvider daslFilterProvider, IQueryOutlookContactItemFolderStrategy queryFolderStrategy, IComWrapperFactory comWrapperFactory, bool useDefaultFolderItemType)
        {
            if (session == null)
            {
                throw new ArgumentNullException(nameof(session));
            }
            if (daslFilterProvider == null)
            {
                throw new ArgumentNullException(nameof(daslFilterProvider));
            }
            if (queryFolderStrategy == null)
            {
                throw new ArgumentNullException(nameof(queryFolderStrategy));
            }
            if (comWrapperFactory == null)
            {
                throw new ArgumentNullException(nameof(comWrapperFactory));
            }

            _session                  = session;
            _folderId                 = folderId;
            _folderStoreId            = folderStoreId;
            _daslFilterProvider       = daslFilterProvider;
            _queryFolderStrategy      = queryFolderStrategy;
            _comWrapperFactory        = comWrapperFactory;
            _useDefaultFolderItemType = useDefaultFolderItemType;
        }
Ejemplo n.º 2
0
        public OutlookContactRepository(NameSpace mapiNameSpace, string folderId, string folderStoreId, IDaslFilterProvider daslFilterProvider, IQueryOutlookContactItemFolderStrategy queryFolderStrategy)
        {
            if (mapiNameSpace == null)
            {
                throw new ArgumentNullException(nameof(mapiNameSpace));
            }
            if (daslFilterProvider == null)
            {
                throw new ArgumentNullException(nameof(daslFilterProvider));
            }
            if (queryFolderStrategy == null)
            {
                throw new ArgumentNullException(nameof(queryFolderStrategy));
            }

            _mapiNameSpace       = mapiNameSpace;
            _folderId            = folderId;
            _folderStoreId       = folderStoreId;
            _daslFilterProvider  = daslFilterProvider;
            _queryFolderStrategy = queryFolderStrategy;
        }