Class ReflectionHelper
Encapsulates common functionality related with reflection-based operations such as Cloning, Field Copying, etc.
Inheritance
Inherited Members
Namespace: Telerik.WinControls
Assembly: Telerik.WinControls.dll
Syntax
public static class ReflectionHelper
Methods
Clone<T>(T)
Creates a new instance of type T and copies its fields from the provided source instance. Reference type fields will be copied by reference rather than cloned.
Declaration
public static T Clone<T>(T source)
where T : class, new()
Parameters
T
source
|
Returns
T
|
Type Parameters
T
|
CopyFields<T>(T, T)
Copies all the fields, which are not marked by the [NonSerialized] attribute and are not Delegate instances, from the source object to the target one. Reference type fields will be copied by reference rather than cloned.
Declaration
public static void CopyFields<T>(T target, T source)
where T : class
Parameters
T
target
|
T
source
|
Type Parameters
T
|