From e8cebe1d825cccf1dcdb0e6cb5f83d6c4e742169 Mon Sep 17 00:00:00 2001 From: tpietzsch Date: Wed, 19 Jul 2023 11:47:34 +0200 Subject: [PATCH] replace use left(), right() getters instead of public fields --- .../algorithm/kdtree/VolumetricSearch.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/main/java/net/imglib2/algorithm/kdtree/VolumetricSearch.java b/src/main/java/net/imglib2/algorithm/kdtree/VolumetricSearch.java index e818d1334..df2f5ab96 100644 --- a/src/main/java/net/imglib2/algorithm/kdtree/VolumetricSearch.java +++ b/src/main/java/net/imglib2/algorithm/kdtree/VolumetricSearch.java @@ -185,10 +185,10 @@ public List< I > find( final RealLocalizable pt ) // which still could be lower. // Otherwise (coordinate is smaller/equal position, take the // right branch as well - if ( node.left != null ) - toDo.push( node.left ); - if ( node.right != null && node.getSplitCoordinate() <= position[ k ] ) - toDo.push( node.right ); + if ( node.left() != null ) + toDo.push( node.left() ); + if ( node.right() != null && node.getSplitCoordinate() <= position[ k ] ) + toDo.push( node.right() ); } else { @@ -198,10 +198,10 @@ public List< I > find( final RealLocalizable pt ) // which still could be higher. // Otherwise (coordinate is larger/equal position, take the left // branch as well - if ( node.right != null ) - toDo.push( node.right ); - if ( node.left != null && node.getSplitCoordinate() >= position[ k - numDimensions ] ) - toDo.push( node.left ); + if ( node.right() != null ) + toDo.push( node.right() ); + if ( node.left() != null && node.getSplitCoordinate() >= position[ k - numDimensions ] ) + toDo.push( node.left() ); } }