@@ -75,7 +75,7 @@ public bool TryAcquire(string filePath, out FileStream? fileStream, FileMode fil
75
75
return fileStream ;
76
76
}
77
77
78
- private bool waitUntilAcquired ( string filePath , out FileStream ? fileStream , FileMode fileMode ,
78
+ private bool WaitUntilAcquired ( string filePath , out FileStream ? fileStream , FileMode fileMode ,
79
79
FileAccess fileAccess , FileShare fileShare , int timeoutInMilliseconds , bool throwOnTimeout )
80
80
{
81
81
FileStream ? spinningFileStream = null ;
@@ -98,10 +98,10 @@ private bool waitUntilAcquired(string filePath, out FileStream? fileStream, File
98
98
return false ;
99
99
}
100
100
101
- private FileStream ? waitUntilAcquired ( string filePath , FileMode fileMode ,
101
+ private FileStream ? WaitUntilAcquired ( string filePath , FileMode fileMode ,
102
102
FileAccess fileAccess , FileShare fileShare , int timeoutInMilliseconds , bool noThrowOnTimeout )
103
103
{
104
- waitUntilAcquired ( filePath , out var fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , ! noThrowOnTimeout ) ;
104
+ WaitUntilAcquired ( filePath , out var fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , ! noThrowOnTimeout ) ;
105
105
return fileStream ;
106
106
}
107
107
@@ -119,7 +119,7 @@ public bool WaitUntilAcquired(string filePath, out FileStream? fileStream, FileM
119
119
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool throwOnTimeout = false )
120
120
{
121
121
var timeoutInMilliseconds = DefaultTimeoutInMilliseconds ;
122
- return waitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
122
+ return WaitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
123
123
}
124
124
125
125
/// <summary>
@@ -135,7 +135,7 @@ public bool WaitUntilAcquired(string filePath, out FileStream? fileStream, FileM
135
135
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool noThrowOnTimeout = false )
136
136
{
137
137
var timeoutInMilliseconds = DefaultTimeoutInMilliseconds ;
138
- return waitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
138
+ return WaitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
139
139
}
140
140
141
141
/// <summary>
@@ -151,7 +151,7 @@ public bool WaitUntilAcquired(string filePath, out FileStream? fileStream, FileM
151
151
/// <returns>If true the lock acquirement was successful.</returns>
152
152
public bool WaitUntilAcquired ( string filePath , int timeoutInMilliseconds , out FileStream ? fileStream , FileMode fileMode = DefaultFileMode ,
153
153
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool throwOnTimeout = false ) =>
154
- waitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
154
+ WaitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
155
155
156
156
/// <summary>
157
157
/// Wait until file gets acquired lock but only as long the file stream is opened.
@@ -165,7 +165,7 @@ public bool WaitUntilAcquired(string filePath, int timeoutInMilliseconds, out Fi
165
165
/// <returns>If not null the lock acquirement was successful.</returns>
166
166
public FileStream ? WaitUntilAcquired ( string filePath , int timeoutInMilliseconds , FileMode fileMode = DefaultFileMode ,
167
167
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool noThrowOnTimeout = false ) =>
168
- waitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
168
+ WaitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
169
169
170
170
/// <summary>
171
171
/// Wait until file gets acquired lock but only as long the file stream is opened.
@@ -182,7 +182,7 @@ public bool WaitUntilAcquired(string filePath, TimeSpan timeout, out FileStream?
182
182
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool throwOnTimeout = false )
183
183
{
184
184
var timeoutInMilliseconds = Convert . ToInt32 ( timeout . TotalMilliseconds ) ;
185
- return waitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
185
+ return WaitUntilAcquired ( filePath , out fileStream , fileMode , fileAccess , fileShare , timeoutInMilliseconds , throwOnTimeout ) ;
186
186
}
187
187
188
188
/// <summary>
@@ -199,7 +199,7 @@ public bool WaitUntilAcquired(string filePath, TimeSpan timeout, out FileStream?
199
199
FileAccess fileAccess = DefaultFileAccess , FileShare fileShare = DefaultFileShare , bool noThrowOnTimeout = false )
200
200
{
201
201
var timeoutInMilliseconds = Convert . ToInt32 ( timeout . TotalMilliseconds ) ;
202
- return waitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
202
+ return WaitUntilAcquired ( filePath , fileMode , fileAccess , fileShare , timeoutInMilliseconds , noThrowOnTimeout ) ;
203
203
}
204
204
}
205
205
}
0 commit comments