Show / Hide Table of Contents

Class SerializableObjectCloneExtension

Reference Article http://www.codeproject.com/KB/tips/SerializedObjectCloner.aspx Provides a method for performing a deep copy of an object. Binary Serialization is used to perform the copy.

Inheritance
object
SerializableObjectCloneExtension
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Sartorius.SAF.Extensions
Assembly: Sartorius.SAF.dll
Syntax
public static class SerializableObjectCloneExtension

Methods

View Source

CloneArray<T>(T[])

Clones the array.

Declaration
public static T[] CloneArray<T>(this T[] source)
Parameters
Type Name Description
T[] source

The source.

Returns
Type Description
T[]
Type Parameters
Name Description
T
View Source

Clone<T>(T)

Perform a deep Copy of the object.

Declaration
public static T Clone<T>(this T source)
Parameters
Type Name Description
T source

The object instance to copy.

Returns
Type Description
T

The copied object or null.

Type Parameters
Name Description
T

The type of object being copied.

Exceptions
Type Condition
ArgumentException

Throw a exception if the given reference is not serializable.

  • View Source
Back to top Generated by DocFX