Exemple #1
0
        // permit subclassing

        /// <summary>Create a new FSDirectory for the named location (ctor for subclasses).</summary>
        /// <param name="path">the path of the directory
        /// </param>
        /// <param name="lockFactory">the lock factory to use, or null for the default
        /// ({@link NativeFSLockFactory});
        /// </param>
        /// <throws>  IOException </throws>
        protected internal FSDirectory(System.IO.DirectoryInfo path, LockFactory lockFactory)
        {
            // new ctors use always NativeFSLockFactory as default:
            if (lockFactory == null)
            {
                lockFactory = new NativeFSLockFactory();
            }
            Init(path, lockFactory);
            refCount = 1;
        }
Exemple #2
0
		 // permit subclassing
		
		/// <summary>Create a new FSDirectory for the named location (ctor for subclasses).</summary>
		/// <param name="path">the path of the directory
		/// </param>
		/// <param name="lockFactory">the lock factory to use, or null for the default
		/// ({@link NativeFSLockFactory});
		/// </param>
		/// <throws>  IOException </throws>
		protected internal FSDirectory(System.IO.DirectoryInfo path, LockFactory lockFactory)
		{
			// new ctors use always NativeFSLockFactory as default:
			if (lockFactory == null)
			{
				lockFactory = new NativeFSLockFactory();
			}
			Init(path, lockFactory);
			refCount = 1;
		}