Class PrefetchContext
Represents a prefetch context that groups related asset requests with a shared budget.
Manages the lifecycle and resource allocation for a specific usage scenario.
Inherited Members
Namespace: Serenity.AssetPrefetcher.Domain.Entities
Assembly: Serenity.AssetPrefetcher.Domain.dll
Syntax
public class PrefetchContext
Constructors
PrefetchContext(string, PrefetchBudget)
Initializes a new prefetch context with the specified identifier and budget.
Declaration
public PrefetchContext(string contextId, PrefetchBudget budget)
Parameters
| Type | Name | Description |
|---|---|---|
| string | contextId | Unique identifier for the context |
| PrefetchBudget | budget | Budget constraints for resource allocation |
Properties
ActiveRequests
Declaration
public List<PrefetchRequest> ActiveRequests { get; }
Property Value
| Type | Description |
|---|---|
| List<PrefetchRequest> | Collection of active prefetch requests associated with this context. |
Budget
Declaration
public PrefetchBudget Budget { get; }
Property Value
| Type | Description |
|---|---|
| PrefetchBudget | Budget constraints for this context's resource allocation. |
ContextId
Declaration
public string ContextId { get; }
Property Value
| Type | Description |
|---|---|
| string | Unique identifier for this prefetch context. |