From 908e6b30a7a4523d379835b10bd90f80f2610ae4 Mon Sep 17 00:00:00 2001 From: Ivan Posazhennikov Date: Mon, 28 Aug 2023 12:50:43 +0300 Subject: [PATCH 1/3] add getter and setter for clusterDistancePoints in the GMUNonHierarchicalDistanceBasedAlgorithm.m --- src/Clustering/Algo/GMUClusterAlgorithm.h | 5 +++++ .../Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/src/Clustering/Algo/GMUClusterAlgorithm.h b/src/Clustering/Algo/GMUClusterAlgorithm.h index e6637f52..594d597f 100644 --- a/src/Clustering/Algo/GMUClusterAlgorithm.h +++ b/src/Clustering/Algo/GMUClusterAlgorithm.h @@ -27,6 +27,11 @@ NS_ASSUME_NONNULL_BEGIN - (void)addItems:(NSArray> *)items; +/** + * setter. + */ +- (void) setClusterDistancePoints:(NSUInteger)newValue; + /** * Removes an item. */ diff --git a/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m b/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m index c227fea3..0fd5dbc3 100644 --- a/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m +++ b/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m @@ -97,6 +97,14 @@ - (instancetype)initWithClusterDistancePoints:(NSUInteger)clusterDistancePoints return self; } +- (NSUInteger)clusterDistancePoints { + return _clusterDistancePoints; +} + +- (void)setClusterDistancePoints:(NSUInteger)newValue { + _clusterDistancePoints = newValue; +} + - (void)addItems:(NSArray> *)items { [_items addObjectsFromArray:items]; for (id item in items) { From a389493cc45d36ba75493420504ca84a6f56ee86 Mon Sep 17 00:00:00 2001 From: Ivan Posazhennikov Date: Mon, 28 Aug 2023 15:13:23 +0300 Subject: [PATCH 2/3] remove getter --- .../Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m b/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m index 0fd5dbc3..32a61e15 100644 --- a/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m +++ b/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m @@ -97,10 +97,6 @@ - (instancetype)initWithClusterDistancePoints:(NSUInteger)clusterDistancePoints return self; } -- (NSUInteger)clusterDistancePoints { - return _clusterDistancePoints; -} - - (void)setClusterDistancePoints:(NSUInteger)newValue { _clusterDistancePoints = newValue; } From e681a0e9718c44c8e5f55a6992b5ecf4c6eafec8 Mon Sep 17 00:00:00 2001 From: Ivan Posazhennikov Date: Mon, 28 Aug 2023 15:40:35 +0300 Subject: [PATCH 3/3] add comment for setClusterDistancePoints() --- src/Clustering/Algo/GMUClusterAlgorithm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Clustering/Algo/GMUClusterAlgorithm.h b/src/Clustering/Algo/GMUClusterAlgorithm.h index 594d597f..445e3454 100644 --- a/src/Clustering/Algo/GMUClusterAlgorithm.h +++ b/src/Clustering/Algo/GMUClusterAlgorithm.h @@ -28,7 +28,7 @@ NS_ASSUME_NONNULL_BEGIN - (void)addItems:(NSArray> *)items; /** - * setter. + * Set the distance for marker clustering for the NonHierarchicalDistanceBasedAlgorithm. */ - (void) setClusterDistancePoints:(NSUInteger)newValue;