コード例 #1
0
 public bool TryAdd(IdentifierNumberPair *values, int length, out int start)
 {
     do
     {
         start = This.Length;
         if (start + length > This.Capacity)
         {
             return(false);
         }
     } while (start != Interlocked.CompareExchange(ref This.Length, start + length, start));
     UnsafeUtility.MemCpy(This.Values + start, values, sizeof(IdentifierNumberPair) * length);
     return(true);
 }
コード例 #2
0
 public void AddRange(IdentifierNumberPair *copySource, int length, out IdentifierNumberPairList *page, out int start, Allocator allocator) => List.AddRange(copySource, length, out page, out start, allocator);