src/Orleans.Serialization/Codecs/ByteArrayCodec.cs
/// <summary>
/// Creates a deep copy of the provided input.
/// </summary>
/// <param name="input">The input.</param>
/// <param name="context">The context.</param>
/// <returns>A copy of <paramref name="input" />.</returns>
Creates a deep copy of the provided input.
Creates a deep copy of the provided input .
public static byte[] DeepCopy(byte[] input, CopyContext context)
        {
            if (context.TryGetCopy<byte[]>(input, out var result))
            {
                return result;
            }
            result = new byte[input.Length];
            context.RecordCopy(input, result);
            input.CopyTo(result.AsSpan());
            return result;
        }
public static byte [ ] DeepCopy ( byte [ ] input , CopyContext context ) { if ( context . TryGetCopy < byte [ ] > ( input , out var result ) ) { return result ; } result = new byte [ input . Length ] ; context . RecordCopy ( input , result ) ; input . CopyTo ( result . AsSpan ( ) ) ; return result ; }
Creates a deep copy of the provided input.
Creates a deep copy of the provided input .
A copy of .
A copy of .
input
byte[]
None
context
CopyContext
None