コード例 #1
0
ファイル: SyncDirectory.cs プロジェクト: jclementson/Examine
 /// <summary>
 /// Create a SyncDirectory
 /// </summary>
 /// <param name="masterDirectory"></param>
 /// <param name="cacheDirectory">local Directory object to use for local cache</param>
 public SyncDirectory(
     Lucene.Net.Store.Directory masterDirectory,
     Lucene.Net.Store.Directory cacheDirectory)
 {
     if (masterDirectory == null) throw new ArgumentNullException(nameof(masterDirectory));
     if (cacheDirectory == null) throw new ArgumentNullException(nameof(cacheDirectory));
     _masterDirectory = masterDirectory;
     _cacheDirectory = cacheDirectory;
     _lockFactory = new MultiIndexLockFactory(_masterDirectory, _cacheDirectory);
 }
コード例 #2
0
 /// <summary>
 /// Create a SyncDirectory
 /// </summary>
 /// <param name="masterDirectory"></param>
 /// <param name="cacheDirectory">local Directory object to use for local cache</param>
 public SyncDirectory(
     Lucene.Net.Store.Directory masterDirectory,
     Lucene.Net.Store.Directory cacheDirectory)
 {
     if (masterDirectory == null)
     {
         throw new ArgumentNullException(nameof(masterDirectory));
     }
     if (cacheDirectory == null)
     {
         throw new ArgumentNullException(nameof(cacheDirectory));
     }
     _masterDirectory = masterDirectory;
     _cacheDirectory  = cacheDirectory;
     _lockFactory     = new MultiIndexLockFactory(_masterDirectory, _cacheDirectory);
 }