aboutsummaryrefslogtreecommitdiffstats
path: root/src/slskd/Shares/SharedFileCache.cs
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2022-09-27 09:36:29 -0500
committerJP Dillingham <jp@dillingham.me>2022-09-27 09:36:29 -0500
commit5cdb5cc91786c5f49bfa1f136c1c71fc52367110 (patch)
treef4d8ef5ee04921e10f90e0491483bc82f48d13dd /src/slskd/Shares/SharedFileCache.cs
parentf29414b34b05ab74ecbfa97c03917fb886dc886e (diff)
downloadslskd-5cdb5cc91786c5f49bfa1f136c1c71fc52367110.tar.gz
refactor counting functions
Diffstat (limited to 'src/slskd/Shares/SharedFileCache.cs')
-rw-r--r--src/slskd/Shares/SharedFileCache.cs36
1 files changed, 0 insertions, 36 deletions
diff --git a/src/slskd/Shares/SharedFileCache.cs b/src/slskd/Shares/SharedFileCache.cs
index 3ff3d10f..190679a8 100644
--- a/src/slskd/Shares/SharedFileCache.cs
+++ b/src/slskd/Shares/SharedFileCache.cs
@@ -43,20 +43,6 @@ namespace slskd.Shares
IStateMonitor<SharedFileCacheState> StateMonitor { get; }
/// <summary>
- /// Returns the number of directories in the specified <paramref name="share"/>.
- /// </summary>
- /// <param name="share">The share for which the directories are to be counted.</param>
- /// <returns>The number of directories.</returns>
- int CountDirectories(Share share);
-
- /// <summary>
- /// Returns the number of files in the specified <paramref name="share"/>.
- /// </summary>
- /// <param name="share">The share for which the files are to be counted.</param>
- /// <returns>The number of files.</returns>
- int CountFiles(Share share);
-
- /// <summary>
/// Scans the configured shares and fills the cache.
/// </summary>
/// <param name="shares">The list of shares from which to fill the cache.</param>
@@ -134,28 +120,6 @@ namespace slskd.Shares
private IShareRepository Repository { get; }
/// <summary>
- /// Returns the number of directories in the specified <paramref name="share"/>.
- /// </summary>
- /// <param name="share">The share for which the directories are to be counted.</param>
- /// <returns>The number of directories.</returns>
- public int CountDirectories(Share share)
- {
- var path = share.RemotePath + Path.DirectorySeparatorChar;
- return Repository.CountDirectories(path);
- }
-
- /// <summary>
- /// Returns the number of files in the specified <paramref name="share"/>.
- /// </summary>
- /// <param name="share">The share for which the files are to be counted.</param>
- /// <returns>The number of files.</returns>
- public int CountFiles(Share share)
- {
- var path = share.RemotePath + Path.DirectorySeparatorChar;
- return Repository.CountFiles(path);
- }
-
- /// <summary>
/// Scans the configured shares and fills the cache.
/// </summary>
/// <param name="shares">The list of shares from which to fill the cache.</param>