Path: redb/redb.Core/Schema/ISchemeFieldResolver.cs
Snapshot: redb, development snapshot 2026-12-06. This is the development state of the public mirrors; it may differ from the published packages.
License: Apache-2.0. Repository: https://github.com/redbase-app/redb
Page: https://redbase.app/src/dev-2026-12-06/redb/redb.Core/Schema/ISchemeFieldResolver.cs
----
using redb.Core.Query.Models;
namespace redb.Core.Schema;
///
/// Resolves field paths to FieldInfo with structure_id and db_type.
/// Supports: simple (Name), nested (Address.City), dictionary (PhoneBook[home]),
/// nested dictionary (AddressBook[work].City), ListItem properties (Status.Value).
///
public interface ISchemeFieldResolver
{
///
/// Resolve single field path to FieldInfo.
///
/// ID of the scheme
///
/// Field path. Examples:
/// - "Name" - simple field
/// - "Address.City" - nested field
/// - "PhoneBook[home]" - dictionary access
/// - "AddressBook[work].City" - nested dictionary field
/// - "Status.Value" - ListItem property
/// - "Roles[].Value" - array of ListItem property
///
/// FieldInfo or null if field not found
Task ResolveAsync(long schemeId, string fieldPath);
///
/// Batch resolve multiple field paths. Uses internal caching.
/// More efficient than multiple ResolveAsync calls.
///
/// ID of the scheme
/// Collection of field paths to resolve
/// Dictionary mapping field path to FieldInfo (only resolved fields included)
Task> ResolveManyAsync(long schemeId, IEnumerable fieldPaths);
///
/// Clear internal cache. Useful for testing or after schema changes.
///
void ClearCache();
}