IChunkTreeCache.GetOrAdd(String, Func<IFileInfo,ChunkTree>) Método

Definición

Obtener un existente ChunkTree , o crear y agregar uno nuevo si no está disponible en la memoria caché o ha expirado.

public:
 Microsoft::AspNetCore::Razor::Chunks::ChunkTree ^ GetOrAdd(System::String ^ pagePath, Func<Microsoft::Extensions::FileProviders::IFileInfo ^, Microsoft::AspNetCore::Razor::Chunks::ChunkTree ^> ^ getChunkTree);
public Microsoft.AspNetCore.Razor.Chunks.ChunkTree GetOrAdd (string pagePath, Func<Microsoft.Extensions.FileProviders.IFileInfo,Microsoft.AspNetCore.Razor.Chunks.ChunkTree> getChunkTree);
abstract member GetOrAdd : string * Func<Microsoft.Extensions.FileProviders.IFileInfo, Microsoft.AspNetCore.Razor.Chunks.ChunkTree> -> Microsoft.AspNetCore.Razor.Chunks.ChunkTree
Public Function GetOrAdd (pagePath As String, getChunkTree As Func(Of IFileInfo, ChunkTree)) As ChunkTree

Parámetros

pagePath
String

La ruta de acceso relativa de la aplicación de la página de Razor.

getChunkTree
Func<IFileInfo,ChunkTree>

Delegado que crea un nuevo ChunkTree .

Devoluciones

ChunkTree

ChunkTreeSi existe un archivo en pagePath , null en caso contrario.

Comentarios

El resultado no ChunkTree contiene fragmentos heredados de _ViewStart o fragmentos heredados predeterminados.

Se aplica a