microsoft / mixed-reality-extension-unity
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 1,357 units with 17,297 lines of code in units (74.7% of code).
    • 16 very long units (2,139 lines of code)
    • 36 long units (2,416 lines of code)
    • 142 medium size units (4,383 lines of code)
    • 237 small units (3,418 lines of code)
    • 926 very small units (4,941 lines of code)
12% | 13% | 25% | 19% | 28%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
cs12% | 13% | 25% | 19% | 28%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
MREUnityRuntimeLib/ProceduralToolkit15% | 14% | 25% | 11% | 33%
MREUnityRuntimeLib/Core15% | 16% | 25% | 18% | 22%
MREUnityRuntimeLib/Assets22% | 20% | 30% | 14% | 12%
MREUnityRuntimeLib/Animation13% | 27% | 23% | 18% | 16%
MREUnityRuntimeLib/IPC38% | 0% | 23% | 16% | 20%
MREUnityRuntimeLib/App0% | 25% | 37% | 22% | 14%
MREUnityRuntimeLib/Factories0% | 35% | 15% | 34% | 14%
MREUnityRuntimeLib/Patching0% | 0% | 34% | 34% | 31%
MREUnityRuntimeLib/Messaging0% | 0% | 19% | 36% | 43%
MREUnityRuntimeLib/Util0% | 0% | 9% | 35% | 54%
MREUnityRuntimeLib/Behaviors0% | 0% | 11% | 43% | 44%
MREUnityRuntimeLib/API0% | 0% | 60% | 21% | 18%
MREUnityRuntimeLib/RPC0% | 0% | 0% | 66% | 33%
tools/PostBuildTool0% | 0% | 0% | 100% | 0%
MREUnityRuntimeLib0% | 0% | 0% | 100% | 0%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
public static void SegmentSegment()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Closest2D.cs
210 37 6
internal void Interpolate()
in MREUnityRuntimeLib/Core/Components/AnimationComponent.cs
184 36 5
public static float SegmentSegment()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Distance2D.cs
181 40 4
public void PredictAllRemoteBodiesWithOwnedBodies()
in MREUnityRuntimeLib/Core/Physics/PredictionInterpolation.cs
147 18 2
public static void RaySegment()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Closest2D.cs
147 29 6
internal async void OnCreateAsset()
in MREUnityRuntimeLib/Assets/AssetLoader.cs
128 24 2
public static void RayRay()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Closest2D.cs
125 19 6
public static void SegmentCircle()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Closest2D.cs
122 24 6
public static void SegmentSphere()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Closest3D.cs
122 24 6
internal ActorPatch GeneratePatch()
in MREUnityRuntimeLib/Core/Actor.cs
118 50 2
public static float RaySegment()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Distance2D.cs
118 24 4
internal override void Update()
in MREUnityRuntimeLib/Animation/Animation.cs
111 19 1
internal void CreateAnimation()
in MREUnityRuntimeLib/Core/Components/AnimationComponent.cs
110 16 8
public void FixedUpdate()
in MREUnityRuntimeLib/Core/PhysicsBridge.cs
110 12 1
private async Task ReadTask()
in MREUnityRuntimeLib/IPC/Connections/WebSocket.cs
105 21 0
private Asset GenerateAssetPatch()
in MREUnityRuntimeLib/Assets/AssetLoader.cs
101 8 2
public static async Task LoadTask()
in MREUnityRuntimeLib/Assets/AssetFetcher.cs
100 20 2
public static MeshDraft Capsule()
in MREUnityRuntimeLib/ProceduralToolkit/MeshDraftPrimitives.cs
99 6 4
public static bool SegmentSegment()
in MREUnityRuntimeLib/ProceduralToolkit/Geometry/Intersect2D.cs
91 16 5
private void ProcessCreatedActors()
in MREUnityRuntimeLib/App/MixedRealityExtensionApp.cs
90 19 4