/// <summary> /// Creates a new, empty file in the directory with the given name. /// Returns a stream writing this file. /// </summary> public override IndexOutput CreateOutput(string name) { //write to both indexes if (Enabled) { return(new MultiIndexOutput( _tempStorageDir.CreateOutput(name), _realDirectory.CreateOutput(name))); } return(_realDirectory.CreateOutput(name)); }
private void WriteIndexVersion(FSDirectory directory) { using (var indexOutput = directory.CreateOutput(indexVersionFilename)) { indexOutput.WriteString(IndexVersion); indexOutput.Flush(); } }