| Clean Architecture Toolkit for .NET | |||||
|
Clean Architecture Toolkit is a clean, modular architecture foundation for .NET applications. It embraces SOLID principles and focuses on maintainability, testability, and scalability through clear boundaries and pluggable design. |
|
||||
|
| HOME | MODULE OVERVIEW | DEMO | CAT.EXPRESSIONS | |
|||||
Code Reference
» Cat.Expressions.Abstractions Assembly » Cat.Expressions.Abstractions Namespace » ICatCompiledMemberExpressionCache<T> Interface
ICatCompiledMemberExpressionCache<T>.GetOrAdd<TProperty>(Expression<Func<T,TProperty>>, MemberInfo) Method
Compiles the given member expression into a delegate, or returns the delegate compiled for it on a previous call.
System.Func<T,TProperty> GetOrAdd<TProperty>(System.Linq.Expressions.Expression<System.Func<T,TProperty>> expression, System.Reflection.MemberInfo? memberInfo=null);
Type parameters
TProperty
The type of value the compiled delegate returns.
Parameters
expression System.Linq.Expressions.Expression<System.Func<T,TProperty>>
The member access expression to compile.
memberInfo System.Reflection.MemberInfo
The member the expression resolves to, if already known. Pass null to let the cache resolve it from the expression.
Returns
System.Func<T,TProperty>
A compiled delegate that evaluates the expression against an instance of T.