Class ObjectMapper
Last update: 09.03.2026Namespace: OpenTD.Utility
Assembly: OpenTD.dll
Can be used to perform a shallow copy of an object.
public static class ObjectMapper
Inheritance
Inherited Members
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Methods
CopyProperties(object, object)
Copies the matching properties from one object to another.
public static void CopyProperties(object source, object target)
Parameters
source object
The source.
target object
The target.
GetMatchingProperties(Type, Type)
public static IList<PropertyMap> GetMatchingProperties(Type sourceType, Type targetType)
Parameters
sourceType Type
targetType Type