microsoft / Microsoft.IO.RecyclableMemoryStream
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 110 units with 1,246 lines of code in units (71.8% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (54 lines of code)
    • 20 medium size units (625 lines of code)
    • 14 small units (197 lines of code)
    • 75 very small units (370 lines of code)
0% | 4% | 50% | 15% | 29%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
cs0% | 4% | 50% | 15% | 29%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src0% | 4% | 50% | 15% | 29%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
public override Task CopyToAsync()
in src/RecyclableMemoryStream.cs
54 7 3
public override void Write()
in src/RecyclableMemoryStream.cs
48 7 3
protected override void Dispose()
in src/RecyclableMemoryStream.cs
47 9 1
public RecyclableMemoryStreamManager()
in src/RecyclableMemoryStreamManager.cs
47 9 6
public void WriteTo()
in src/RecyclableMemoryStream.cs
42 6 4
internal void ReturnLargeBuffer()
in src/RecyclableMemoryStreamManager.cs
34 6 3
public void WriteTo()
in src/RecyclableMemoryStream.cs
33 5 3
public void Advance()
in src/RecyclableMemoryStream.cs
31 6 1
public void Write()
in src/RecyclableMemoryStream.cs
31 3 1
private void EnsureCapacity()
in src/RecyclableMemoryStream.cs
31 7 1
internal void ReturnBlocks()
in src/RecyclableMemoryStreamManager.cs
31 8 3
private ArraySegment GetWritableBuffer()
in src/RecyclableMemoryStream.cs
29 6 1
private int InternalRead()
in src/RecyclableMemoryStream.cs
29 4 4
private int InternalRead()
in src/RecyclableMemoryStream.cs
29 4 2
public override void WriteByte()
in src/RecyclableMemoryStream.cs
28 5 1
public override long Seek()
in src/RecyclableMemoryStream.cs
25 5 2
internal void ReturnBlock()
in src/RecyclableMemoryStreamManager.cs
24 5 3
public int SafeRead()
in src/RecyclableMemoryStream.cs
23 5 4
internal RecyclableMemoryStream()
in src/RecyclableMemoryStream.cs
21 3 5
public ReadOnlySequence GetReadOnlySequence()
in src/RecyclableMemoryStream.cs
21 4 0