Applies state of sourceEntity to current state of entity

Namespace: RiaServicesContrib.Extensions
Assembly: RiaServicesContrib.EntityTools (in RiaServicesContrib.EntityTools.dll) Version: 1.0.0.0 (1.0.0.0)

Syntax

C#
public static void ApplyState<T>(
	this T targetEntity,
	T sourceEntity
)
where T : Entity
Visual Basic
<ExtensionAttribute> _
Public Shared Sub ApplyState(Of T As Entity) ( _
	targetEntity As T, _
	sourceEntity As T _
)
Visual C++
[ExtensionAttribute]
public:
generic<typename T>
where T : Entity
static void ApplyState(
	T targetEntity, 
	T sourceEntity
)

Parameters

targetEntity
Type: T
Entity having state copied to
sourceEntity
Type: T
Entity being copied from

Type Parameters

T

[Missing <typeparam name="T"/> documentation for "M:RiaServicesContrib.Extensions.RiaServicesExtensions.ApplyState``1(``0,``0)"]

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type . When you use instance method syntax to call this method, omit the first parameter. For more information, see or .

Remarks

Original EntityStates are not checked.

See Also