{"action":"created","comment":{"url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/comments/80355543","id":80355543,"diff_hunk":"@@ -0,0 +1,101 @@\n+---\n+permalink: /en-US/api/Microsoft_Toolkit_Uwp_UI_CacheBase.htm\n+title: Microsoft.Toolkit.Uwp.UI.CacheBase API \n+description: API page for Microsoft.Toolkit.Uwp.UI.CacheBase\n+keywords: windows, app, toolkit, UWP, API\n+layout: api\n+search.product: eADQiWindows 10XVcnh\n+---\n+\n+\n+# CacheBase<T> class\n+\n+Represents a strongly typed cache of objects that can be added to and removed as desired.\n+The cache also provides in-memory storage of strongly typed objects to reduce reading from disc. The size of this in-memory storage is controlled by setting the ***MaxMemoryCacheCount*** property.\n+The in-memory storage follows FIFO (first in first out) and the caller can pass optional parameter when calling ***PreCacheAsync*** to inform cache to use in-memory storage.\n+\n+## Members\n+\n+The **CacheBase<T>** class has the following types of members:\n+\n+### Methods\n+\n+#### InitializeAsync(Windows.Storage.StorageFolder folder, System.String folderName)\n+\n+this method is used supply a folder within which cache specific folder is created based on name provided.\n+\n+##### Parameters\n+######| Name | Description | Type |\n+\n+| folder | folder where cache specific folder is created | [StorageFolder](https://msdn.microsoft.com/en-us/library/windows/apps/windows.storage.storagefolder.aspx) |\n+\n+| folderName | the name given to cache specific folder | [String](https://msdn.microsoft.com/en-us/library/windows/apps/system.string.aspx) |\n+\n+| returns | [Task](https://msdn.microsoft.com/en-us/library/windows/apps/system.threading.tasks.task.aspx) |\n+\n+\n+#### ClearAsync()\n+\n+this method clears the entire cache and any items held within the in-memory storage.\n+\n+##### Parameters\n+######| Name | Description | Type |\n+\n+| returns | [Task](https://msdn.microsoft.com/en-us/library/windows/apps/system.threading.tasks.task.aspx) |\n+\n+\n+#### ClearAsync(System.TimeSpan duration)\n+\n+this method delete expired items from the cache and from within the in-memory cache.\n+\n+##### Parameters\n+###### | Name | Description | Type |\n+\n+| duration | this parameter is used to determine where item within cache has expired and should be delete or not. | [TimeSpan](https://msdn.microsoft.com/en-us/library/windows/apps/system.timespan.aspx) |\n+\n+| return | [Task](https://msdn.microsoft.com/en-us/library/windows/apps/system.threading.tasks.task.aspx) |\n+\n+\n+#### PreCacheAsync(System.Uri uri, System.String fileName, System.Boolean throwOnErro, System.Boolean storeToMemoryCache)\n+\n+This method downloads the file at uri supplied and saves it to the cache with the file name supplied. It also optionally loads the item into in-memory cache","path":"en-us/api/Microsoft_Toolkit_Uwp_UI_CacheBase.md","position":61,"original_position":61,"commit_id":"7f602724e9a8256b3727307e60e6d46a7006c7f3","original_commit_id":"7f602724e9a8256b3727307e60e6d46a7006c7f3","user":{"login":"ScottIsAFool","id":1658896,"avatar_url":"https://avatars.githubusercontent.com/u/1658896?v=3","gravatar_id":"","url":"https://api.github.com/users/ScottIsAFool","html_url":"https://github.com/ScottIsAFool","followers_url":"https://api.github.com/users/ScottIsAFool/followers","following_url":"https://api.github.com/users/ScottIsAFool/following{/other_user}","gists_url":"https://api.github.com/users/ScottIsAFool/gists{/gist_id}","starred_url":"https://api.github.com/users/ScottIsAFool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ScottIsAFool/subscriptions","organizations_url":"https://api.github.com/users/ScottIsAFool/orgs","repos_url":"https://api.github.com/users/ScottIsAFool/repos","events_url":"https://api.github.com/users/ScottIsAFool/events{/privacy}","received_events_url":"https://api.github.com/users/ScottIsAFool/received_events","type":"User","site_admin":false},"body":"\"at the uri supplied\"","created_at":"2016-09-24T08:20:37Z","updated_at":"2016-09-24T08:48:18Z","html_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35#discussion_r80355543","pull_request_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35","_links":{"self":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/comments/80355543"},"html":{"href":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35#discussion_r80355543"},"pull_request":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35"}}},"pull_request":{"url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35","id":85544657,"html_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35","diff_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35.diff","patch_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35.patch","issue_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/35","number":35,"state":"closed","locked":false,"title":"Documentation for Cache rework","user":{"login":"hermitdave","id":1896163,"avatar_url":"https://avatars.githubusercontent.com/u/1896163?v=3","gravatar_id":"","url":"https://api.github.com/users/hermitdave","html_url":"https://github.com/hermitdave","followers_url":"https://api.github.com/users/hermitdave/followers","following_url":"https://api.github.com/users/hermitdave/following{/other_user}","gists_url":"https://api.github.com/users/hermitdave/gists{/gist_id}","starred_url":"https://api.github.com/users/hermitdave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hermitdave/subscriptions","organizations_url":"https://api.github.com/users/hermitdave/orgs","repos_url":"https://api.github.com/users/hermitdave/repos","events_url":"https://api.github.com/users/hermitdave/events{/privacy}","received_events_url":"https://api.github.com/users/hermitdave/received_events","type":"User","site_admin":false},"body":"Updated docs for Cache rework","created_at":"2016-09-16T09:42:19Z","updated_at":"2016-09-24T08:48:18Z","closed_at":"2016-09-24T08:20:44Z","merged_at":null,"merge_commit_sha":"30c5c18e1a5495c36cdaa31944e766d0b5ad4026","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35/commits","review_comments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35/comments","review_comment_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/35/comments","statuses_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/statuses/7f602724e9a8256b3727307e60e6d46a7006c7f3","head":{"label":"Microsoft:hd-cache-docs","ref":"hd-cache-docs","sha":"7f602724e9a8256b3727307e60e6d46a7006c7f3","user":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"repo":{"id":61739536,"name":"UWPCommunityToolkit-docs","full_name":"Microsoft/UWPCommunityToolkit-docs","owner":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs","description":"Documentation content for UWP Community Toolkit","fork":false,"url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs","forks_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/forks","keys_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/teams","hooks_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/hooks","issue_events_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/events{/number}","events_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/events","assignees_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/assignees{/user}","branches_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/branches{/branch}","tags_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/tags","blobs_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/languages","stargazers_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/stargazers","contributors_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/contributors","subscribers_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/subscribers","subscription_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/subscription","commits_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/contents/{+path}","compare_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/merges","archive_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/downloads","issues_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues{/number}","pulls_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/labels{/name}","releases_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/releases{/id}","deployments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/deployments","created_at":"2016-06-22T17:48:33Z","updated_at":"2016-09-22T16:19:01Z","pushed_at":"2016-09-24T08:33:04Z","git_url":"git://github.com/Microsoft/UWPCommunityToolkit-docs.git","ssh_url":"git@github.com:Microsoft/UWPCommunityToolkit-docs.git","clone_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs.git","svn_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs","homepage":"","size":37650,"stargazers_count":19,"watchers_count":19,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":16,"mirror_url":null,"open_issues_count":2,"forks":16,"open_issues":2,"watchers":19,"default_branch":"master"}},"base":{"label":"Microsoft:master","ref":"master","sha":"ac5e17234b5425f77d7857f9e0c96fd362903757","user":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"repo":{"id":61739536,"name":"UWPCommunityToolkit-docs","full_name":"Microsoft/UWPCommunityToolkit-docs","owner":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs","description":"Documentation content for UWP Community Toolkit","fork":false,"url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs","forks_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/forks","keys_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/teams","hooks_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/hooks","issue_events_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/events{/number}","events_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/events","assignees_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/assignees{/user}","branches_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/branches{/branch}","tags_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/tags","blobs_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/languages","stargazers_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/stargazers","contributors_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/contributors","subscribers_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/subscribers","subscription_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/subscription","commits_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/contents/{+path}","compare_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/merges","archive_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/downloads","issues_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues{/number}","pulls_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/labels{/name}","releases_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/releases{/id}","deployments_url":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/deployments","created_at":"2016-06-22T17:48:33Z","updated_at":"2016-09-22T16:19:01Z","pushed_at":"2016-09-24T08:33:04Z","git_url":"git://github.com/Microsoft/UWPCommunityToolkit-docs.git","ssh_url":"git@github.com:Microsoft/UWPCommunityToolkit-docs.git","clone_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs.git","svn_url":"https://github.com/Microsoft/UWPCommunityToolkit-docs","homepage":"","size":37650,"stargazers_count":19,"watchers_count":19,"language":"CSS","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":16,"mirror_url":null,"open_issues_count":2,"forks":16,"open_issues":2,"watchers":19,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35"},"html":{"href":"https://github.com/Microsoft/UWPCommunityToolkit-docs/pull/35"},"issue":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/35"},"comments":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/issues/35/comments"},"review_comments":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35/comments"},"review_comment":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/pulls/35/commits"},"statuses":{"href":"https://api.github.com/repos/Microsoft/UWPCommunityToolkit-docs/statuses/7f602724e9a8256b3727307e60e6d46a7006c7f3"}}}}
{"actor":{"display_login":"ScottIsAFool"}}