summaryrefslogtreecommitdiff
path: root/src/SMAPI.Web/Framework/Caching/Wiki
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2019-07-24 18:31:43 -0400
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2019-09-14 18:58:49 -0400
commit03a082297a750dace586dc2d15d17c840d96d95f (patch)
tree2c18c9e428b8e841b75b130dd272989991124668 /src/SMAPI.Web/Framework/Caching/Wiki
parentf6b336def7b05c3ef202f6c6b5e77dcaa0c498fa (diff)
downloadSMAPI-03a082297a750dace586dc2d15d17c840d96d95f.tar.gz
SMAPI-03a082297a750dace586dc2d15d17c840d96d95f.tar.bz2
SMAPI-03a082297a750dace586dc2d15d17c840d96d95f.zip
add generic cache repository interface (#651)
Diffstat (limited to 'src/SMAPI.Web/Framework/Caching/Wiki')
-rw-r--r--src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMetadata.cs2
-rw-r--r--src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMod.cs2
-rw-r--r--src/SMAPI.Web/Framework/Caching/Wiki/IWikiCacheRepository.cs9
3 files changed, 4 insertions, 9 deletions
diff --git a/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMetadata.cs b/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMetadata.cs
index 4d6b4b10..6a560eb4 100644
--- a/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMetadata.cs
+++ b/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMetadata.cs
@@ -5,7 +5,7 @@ using MongoDB.Bson;
namespace StardewModdingAPI.Web.Framework.Caching.Wiki
{
/// <summary>The model for cached wiki metadata.</summary>
- public class CachedWikiMetadata
+ internal class CachedWikiMetadata
{
/*********
** Accessors
diff --git a/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMod.cs b/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMod.cs
index bf1e2be2..37f55db1 100644
--- a/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMod.cs
+++ b/src/SMAPI.Web/Framework/Caching/Wiki/CachedWikiMod.cs
@@ -7,7 +7,7 @@ using StardewModdingAPI.Toolkit.Framework.Clients.Wiki;
namespace StardewModdingAPI.Web.Framework.Caching.Wiki
{
/// <summary>The model for cached wiki mods.</summary>
- public class CachedWikiMod
+ internal class CachedWikiMod
{
/*********
** Accessors
diff --git a/src/SMAPI.Web/Framework/Caching/Wiki/IWikiCacheRepository.cs b/src/SMAPI.Web/Framework/Caching/Wiki/IWikiCacheRepository.cs
index 6031123d..b54c8a2f 100644
--- a/src/SMAPI.Web/Framework/Caching/Wiki/IWikiCacheRepository.cs
+++ b/src/SMAPI.Web/Framework/Caching/Wiki/IWikiCacheRepository.cs
@@ -5,8 +5,8 @@ using StardewModdingAPI.Toolkit.Framework.Clients.Wiki;
namespace StardewModdingAPI.Web.Framework.Caching.Wiki
{
- /// <summary>Encapsulates logic for accessing the mod data cache.</summary>
- internal interface IWikiCacheRepository
+ /// <summary>Encapsulates logic for accessing the wiki data cache.</summary>
+ internal interface IWikiCacheRepository : ICacheRepository
{
/*********
** Methods
@@ -15,11 +15,6 @@ namespace StardewModdingAPI.Web.Framework.Caching.Wiki
/// <param name="metadata">The fetched metadata.</param>
bool TryGetWikiMetadata(out CachedWikiMetadata metadata);
- /// <summary>Whether cached data is stale.</summary>
- /// <param name="lastUpdated">The date when the data was updated.</param>
- /// <param name="staleMinutes">The age in minutes before data is considered stale.</param>
- bool IsStale(DateTimeOffset lastUpdated, int staleMinutes);
-
/// <summary>Get the cached wiki mods.</summary>
/// <param name="filter">A filter to apply, if any.</param>
IEnumerable<CachedWikiMod> GetWikiMods(Expression<Func<CachedWikiMod, bool>> filter = null);