aws-amplify / amplify-ios-maplibre
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 4% duplication:
    • 1,567 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 71 duplicated lines
  • 10 duplicates
system4% (71 lines)
Duplication per Extension
swift4% (71 lines)
Duplication per Component (primary)
Sources/AmplifyMapLibreUI/AMLMapCompositeView21% (33 lines)
HostApp/HostApp/Views9% (14 lines)
Sources/AmplifyMapLibreUI/MGLMapViewWrapper6% (12 lines)
Sources/AmplifyMapLibreUI/AMLMapView4% (12 lines)
HostApp/HostApp0% (0 lines)
HostApp/HostAppUITests0% (0 lines)
HostApp/HostAppTests0% (0 lines)
Sources/AmplifyMapLibreAdapter/Extensions0% (0 lines)
Sources/AmplifyMapLibreAdapter0% (0 lines)
Sources/AmplifyMapLibreUI/SupportingViews0% (0 lines)
Sources/AmplifyMapLibreUI/Extensions0% (0 lines)
Sources/AmplifyMapLibreUI/SupportingTypes0% (0 lines)
ROOT0% (0 lines)
Longest Duplicates
The list of 10 longest duplicates.
See data for all 10 duplicates...
Size#FoldersFilesLinesCode
7 x 2 Sources/AmplifyMapLibreUI/AMLMapCompositeView
Sources/AmplifyMapLibreUI/AMLMapCompositeView
AMLMapCompositeView+iPad.swift
AMLMapCompositeView+iPhone.swift
45:52 (20%)
39:46 (21%)
view
7 x 2 HostApp/HostApp/Views
Sources/AmplifyMapLibreUI/AMLMapCompositeView
AMLMapView_View.swift
AMLMapCompositeView+iPad.swift
66:73 (10%)
45:52 (20%)
view
7 x 2 HostApp/HostApp/Views
Sources/AmplifyMapLibreUI/AMLMapCompositeView
AMLMapView_ViewModel.swift
AMLMapCompositeViewModel.swift
26:33 (33%)
40:47 (31%)
view
7 x 2 HostApp/HostApp/Views
Sources/AmplifyMapLibreUI/AMLMapCompositeView
AMLMapView_View.swift
AMLMapCompositeView+iPhone.swift
66:73 (10%)
39:46 (21%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapCompositeView
Sources/AmplifyMapLibreUI/MGLMapViewWrapper
AMLMapCompositiveView+ViewModifiers.s...
_MGLMapViewWrapper+ViewModifiers.swift
121:136 (10%)
108:123 (18%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapCompositeView
Sources/AmplifyMapLibreUI/AMLMapView
AMLMapCompositiveView+ViewModifiers.s...
AMLMapView+ViewModifiers.swift
121:136 (10%)
121:136 (10%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapView
Sources/AmplifyMapLibreUI/MGLMapViewWrapper
AMLMapView+ViewModifiers.swift
_MGLMapViewWrapper+ViewModifiers.swift
121:136 (10%)
108:123 (18%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapCompositeView
Sources/AmplifyMapLibreUI/MGLMapViewWrapper
AMLMapCompositiveView+ViewModifiers.s...
_MGLMapViewWrapper+ViewModifiers.swift
103:118 (10%)
90:105 (18%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapCompositeView
Sources/AmplifyMapLibreUI/AMLMapView
AMLMapCompositiveView+ViewModifiers.s...
AMLMapView+ViewModifiers.swift
103:118 (10%)
103:118 (10%)
view
6 x 2 Sources/AmplifyMapLibreUI/AMLMapView
Sources/AmplifyMapLibreUI/MGLMapViewWrapper
AMLMapView+ViewModifiers.swift
_MGLMapViewWrapper+ViewModifiers.swift
103:118 (10%)
90:105 (18%)
view