Search Results for

    Show / Hide Table of Contents
    View Source

    Class AppCacheExtensions

    Extensions for strongly typed access

    Inheritance
    object
    Namespace: Umbraco.Extensions
    Assembly: Umbraco.Core.dll
    Syntax
    public static class AppCacheExtensions

    Methods

    View Source

    GetCacheItemAsync<T>(IAppPolicyCache, string, Func<Task<T?>>, TimeSpan?, bool)

    Declaration
    public static Task<T?> GetCacheItemAsync<T>(this IAppPolicyCache provider, string cacheKey, Func<Task<T?>> getCacheItemAsync, TimeSpan? timeout, bool isSliding = false)
    Parameters
    Type Name Description
    IAppPolicyCache provider
    string cacheKey
    Func<Task<T>> getCacheItemAsync
    TimeSpan? timeout
    bool isSliding
    Returns
    Type Description
    Task<T>
    Type Parameters
    Name Description
    T
    View Source

    GetCacheItem<T>(IAppCache, string)

    Declaration
    public static T? GetCacheItem<T>(this IAppCache provider, string cacheKey)
    Parameters
    Type Name Description
    IAppCache provider
    string cacheKey
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    View Source

    GetCacheItem<T>(IAppCache, string, Func<T>)

    Declaration
    public static T? GetCacheItem<T>(this IAppCache provider, string cacheKey, Func<T> getCacheItem)
    Parameters
    Type Name Description
    IAppCache provider
    string cacheKey
    Func<T> getCacheItem
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    View Source

    GetCacheItem<T>(IAppPolicyCache, string, Func<T?>, TimeSpan?, bool)

    Declaration
    public static T? GetCacheItem<T>(this IAppPolicyCache provider, string cacheKey, Func<T?> getCacheItem, TimeSpan? timeout, bool isSliding = false)
    Parameters
    Type Name Description
    IAppPolicyCache provider
    string cacheKey
    Func<T> getCacheItem
    TimeSpan? timeout
    bool isSliding
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    View Source

    GetCacheItemsByKeyExpression<T>(IAppCache, string)

    Declaration
    public static IEnumerable<T?> GetCacheItemsByKeyExpression<T>(this IAppCache provider, string regexString)
    Parameters
    Type Name Description
    IAppCache provider
    string regexString
    Returns
    Type Description
    IEnumerable<T>
    Type Parameters
    Name Description
    T
    View Source

    GetCacheItemsByKeySearch<T>(IAppCache, string)

    Declaration
    public static IEnumerable<T?> GetCacheItemsByKeySearch<T>(this IAppCache provider, string keyStartsWith)
    Parameters
    Type Name Description
    IAppCache provider
    string keyStartsWith
    Returns
    Type Description
    IEnumerable<T>
    Type Parameters
    Name Description
    T
    View Source

    InsertCacheItemAsync<T>(IAppPolicyCache, string, Func<Task<T>>, TimeSpan?, bool)

    Declaration
    public static Task InsertCacheItemAsync<T>(this IAppPolicyCache provider, string cacheKey, Func<Task<T>> getCacheItemAsync, TimeSpan? timeout = null, bool isSliding = false)
    Parameters
    Type Name Description
    IAppPolicyCache provider
    string cacheKey
    Func<Task<T>> getCacheItemAsync
    TimeSpan? timeout
    bool isSliding
    Returns
    Type Description
    Task
    Type Parameters
    Name Description
    T
    View Source

    InsertCacheItem<T>(IAppPolicyCache, string, Func<T>, TimeSpan?, bool)

    Declaration
    public static void InsertCacheItem<T>(this IAppPolicyCache provider, string cacheKey, Func<T> getCacheItem, TimeSpan? timeout = null, bool isSliding = false)
    Parameters
    Type Name Description
    IAppPolicyCache provider
    string cacheKey
    Func<T> getCacheItem
    TimeSpan? timeout
    bool isSliding
    Type Parameters
    Name Description
    T
    • Edit this page
    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX