• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lucaslorentz / auto-compute / 20055595719

09 Dec 2025 07:34AM UTC coverage: 82.723%. Remained the same
20055595719

push

github

lucaslorentz
Complete some renames from ChangeCalculation to ChangeCalculator

28 of 29 new or added lines in 13 files covered. (96.55%)

4 existing lines in 1 file now uncovered.

1762 of 2130 relevant lines covered (82.72%)

859.29 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/LLL.AutoCompute/IComputedChangesProvider.cs
1
using System.Linq.Expressions;
2
using LLL.AutoCompute.ChangesProviders;
3
using LLL.AutoCompute.EntityContexts;
4

5
namespace LLL.AutoCompute;
6

7
/// <summary>
8
/// Non-generic interface for computed changes providers.
9
/// </summary>
10
public interface IComputedChangesProvider
11
{
12
    /// <summary>The expression used to compute values.</summary>
13
    LambdaExpression Expression { get; }
14

15
    /// <summary>The entity context that tracks affected entities and their navigations.</summary>
16
    EntityContext EntityContext { get; }
17

18
    /// <summary>The calculator used to determine changes between original and current values.</summary>
19
    IChangeCalculator ChangeCalculator { get; }
20
}
21

22
/// <summary>
23
/// Provides change detection for entities based on a computed expression.
24
/// </summary>
25
/// <typeparam name="TEntity">The entity type being observed.</typeparam>
26
/// <typeparam name="TChange">The change representation type.</typeparam>
27
public interface IComputedChangesProvider<TEntity, TChange>
28
    : IComputedChangesProvider
29
    where TEntity : class
30
{
31
    /// <inheritdoc/>
NEW
32
    IChangeCalculator IComputedChangesProvider.ChangeCalculator => ChangeCalculator;
×
33

34
    /// <summary>The typed calculator used to determine changes.</summary>
35
    new IChangeCalculator<TChange> ChangeCalculator { get; }
36

37
    /// <summary>
38
    /// Computes changes for all affected entities based on the current input state.
39
    /// </summary>
40
    /// <param name="input">The computed input containing the current state and context.</param>
41
    /// <param name="changeMemory">
42
    /// Optional memory for delta tracking. When provided, returns the difference between the 
43
    /// previously computed change and the current change, enabling incremental updates across 
44
    /// multiple calls. Only use when the observer calculates changes from a constant original 
45
    /// point (e.g., database-loaded values). Pass <c>null</c> for absolute changes.
46
    /// </param>
47
    /// <returns>A dictionary mapping affected entities to their computed changes.</returns>
48
    Task<IReadOnlyDictionary<TEntity, TChange>> GetChangesAsync(ComputedInput input, ChangeMemory<TEntity, TChange>? changeMemory);
49
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc