Update Connected Component Labeling - java