private boolean bucketsEmpty ( ) { for ( int i = 0 ; i < numberOfBuckets ; i ++ ) { if ( bucketContainer . getBucket ( i ) . elementsInBucket > 0 ) { return false ; } } return true ; }
checks if the buckets are empty . Returns true only if all buckets are empty .