Adds the specified sample to the buffer. The sample.
(T sample)
| 71 | /// </summary> |
| 72 | /// <param name="sample">The sample.</param> |
| 73 | public void Add(T sample) |
| 74 | { |
| 75 | // Remove first sample if no space |
| 76 | if (_count == _data.Length) |
| 77 | { |
| 78 | for (int i = 1; i < _count; i++) |
| 79 | { |
| 80 | _data[i - 1] = _data[i]; |
| 81 | } |
| 82 | |
| 83 | _count--; |
| 84 | } |
| 85 | |
| 86 | _data[_count++] = sample; |
| 87 | } |
| 88 | |
| 89 | /// <summary> |
| 90 | /// Adds the specified sample to the buffer. |
no outgoing calls
no test coverage detected