private void watchParents ( Path p , String until ) throws IOException { if ( p . getParent ( ) != null && ! until . equals ( p . getParent ( ) . toString ( ) ) ) { watchDir ( p . getParent ( ) . toFile ( ) ) ; watchParents ( p . getParent ( ) , until ) ; } }
Watch parent folders of this file until the root listener path has been reached .