---
title: ExpressionExtensions
summary: API reference for ExpressionExtensions.
status: draft
owner: saif-docgen
last_reviewed: 2026-09-15
library: SAIF.Framework.Common
reference_type: package
---

# ExpressionExtensions

Strongly-typed property access via expression trees: resolving a `PropertyInfo` from a lambda and setting a property's value without reflecting by string name. ([BR-061](../../business-rules.md#br-061-a-property-selector-lambda-must-select-a-member%2C-not-invoke-a-method)) through [BR-064](../../business-rules.md#br-064-a-property-may-be-set-only-when-it-has-a-setter%2C-but-that-setter-may-be-non-public---reflective-assignment-deliberately-bypasses-accessibility)

## Purpose
- Strongly-typed property access via expression trees: resolving a `PropertyInfo` from a lambda and setting a property's value without reflecting by string name. ([BR-061](../../business-rules.md#br-061-a-property-selector-lambda-must-select-a-member%2C-not-invoke-a-method)) through [BR-064](../../business-rules.md#br-064-a-property-may-be-set-only-when-it-has-a-setter%2C-but-that-setter-may-be-non-public---reflective-assignment-deliberately-bypasses-accessibility)

## Context
- Namespace: `SAIF.Common.Extensions`
- Assembly/package: `SAIF.Framework.Common`

## Public members
| Member | Signature | Purpose |
| --- | --- | --- |
| GetPropertyInfo<TTarget,TProperty>(this Expression<Func<TTarget,TProperty>> expression) | `public static PropertyInfo GetPropertyInfo<TTarget,TProperty>(this Expression<Func<TTarget,TProperty>> expression)` | Extracts the `PropertyInfo` referenced by a `x => x.Property` lambda. ([BR-061](../../business-rules.md#br-061-a-property-selector-lambda-must-select-a-member%2C-not-invoke-a-method), [BR-062](../../business-rules.md#br-062-a-property-selector-lambda-must-select-a-property%2C-not-a-field), [BR-063](../../business-rules.md#br-063-the-selected-property-must-be-declared-on-the-target-type-or-one-of-its-base-types)) |
| SetPropertyValue<TTarget,TProperty>(this TTarget target, PropertyInfo property, TProperty value) | `public static void SetPropertyValue<TTarget,TProperty>(this TTarget target, PropertyInfo property, TProperty value)` | Sets a property on `target` given a resolved `PropertyInfo`. ([BR-064](../../business-rules.md#br-064-a-property-may-be-set-only-when-it-has-a-setter%2C-but-that-setter-may-be-non-public---reflective-assignment-deliberately-bypasses-accessibility)) |
| SetPropertyValue<TTarget,TProperty>(this TTarget target, Expression<Func<TTarget,TProperty>> expression, TProperty value) | `public static void SetPropertyValue<TTarget,TProperty>(this TTarget target, Expression<Func<TTarget,TProperty>> expression, TProperty value)` | Resolves the property from a lambda expression and sets its value in one call. ([BR-061](../../business-rules.md#br-061-a-property-selector-lambda-must-select-a-member%2C-not-invoke-a-method), [BR-062](../../business-rules.md#br-062-a-property-selector-lambda-must-select-a-property%2C-not-a-field), [BR-063](../../business-rules.md#br-063-the-selected-property-must-be-declared-on-the-target-type-or-one-of-its-base-types), [BR-064](../../business-rules.md#br-064-a-property-may-be-set-only-when-it-has-a-setter%2C-but-that-setter-may-be-non-public---reflective-assignment-deliberately-bypasses-accessibility)) |


## Sources
- `Common/SAIF.Common/Extensions/ExpressionExtensions.cs`
