Mercurial > pub > ImplabNet
comparison Implab.Playground/Program.cs @ 234:8dd666e6b6bf v2
Added implab nuget spec
author | cin |
---|---|
date | Thu, 05 Oct 2017 09:21:23 +0300 |
parents | d6fe09f5592c |
children | 302ca905c19e |
comparison
equal
deleted
inserted
replaced
233:d6fe09f5592c | 234:8dd666e6b6bf |
---|---|
47 break; | 47 break; |
48 } | 48 } |
49 return actual != 0; | 49 return actual != 0; |
50 } | 50 } |
51 | 51 |
52 /* | |
53 static void EnqueueRange<T>(AsyncQueue<T> q, T[] data, int offset, int len) { | 52 static void EnqueueRange<T>(AsyncQueue<T> q, T[] data, int offset, int len) { |
54 for (var i = offset; i < offset + len; i++) | 53 for (var i = offset; i < offset + len; i++) |
55 q.Enqueue(data[i]); | 54 q.Enqueue(data[i]); |
56 } | 55 } |
57 | 56 |
64 if (actual == len) | 63 if (actual == len) |
65 break; | 64 break; |
66 } | 65 } |
67 return actual != 0; | 66 return actual != 0; |
68 } | 67 } |
69 */ | |
70 | 68 |
71 static void EnqueueRange<T>(AsyncQueue<T> q, T[] data, int offset, int len) { | 69 |
70 /*static void EnqueueRange<T>(AsyncQueue<T> q, T[] data, int offset, int len) { | |
72 q.EnqueueRange(data, offset, len); | 71 q.EnqueueRange(data, offset, len); |
73 } | 72 } |
74 | 73 |
75 static bool TryDequeueRange<T>(AsyncQueue<T> q, T[] buffer, int offset, int len, out int actual) { | 74 static bool TryDequeueRange<T>(AsyncQueue<T> q, T[] buffer, int offset, int len, out int actual) { |
76 return q.TryDequeueRange(buffer, offset, len, out actual); | 75 return q.TryDequeueRange(buffer, offset, len, out actual); |
77 } | 76 }*/ |
78 | 77 |
79 | 78 |
80 static void Main(string[] args) { | 79 static void Main(string[] args) { |
81 | 80 |
82 //var queue = new ConcurrentQueue<int>(); | 81 //var queue = new ConcurrentQueue<int>(); |