示例#1
0
 /// <nodoc />
 private ReadOnlyFixedBytes(ref FixedBytes fixedBytes)
 {
     fixed(byte *d = &_bytes.FixedElementField)
     {
         for (int i = 0; i < MaxLength; i++)
         {
             d[i] = fixedBytes[i];
         }
     }
 }
示例#2
0
 /// <summary>
 ///     Creates a new instance of the <see cref="ReadOnlyFixedBytes"/> from the <paramref name="fixedBytes"/>.
 /// </summary>
 public static ReadOnlyFixedBytes FromFixedBytes(ref FixedBytes fixedBytes)
 {
     return(new ReadOnlyFixedBytes(ref fixedBytes));
 }
示例#3
0
 /// <nodoc />
 public ShortHash(FixedBytes bytes) => Value = ReadOnlyFixedBytes.FromFixedBytes(ref bytes);