private Set < Resource < T > > listStackDirectory ( Path path ) { HashSet < Resource < T >> merge = new HashSet < Resource < T > > ( ) ; if ( treeHandlerList . size ( ) > 0 ) { for ( SelectiveTree < T > treeHandler : treeHandlerList ) { if ( PathUtil . hasRoot ( treeHandler . getSubPath ( ) , path ) && ! PathUtil . equals ( treeHandler . getSubPath ( ) , path ) ) { String relativePath = PathUtil . removePrefix ( path . getPath ( ) , treeHandler . getSubPath ( ) . getPath ( ) ) ; String [ ] components = PathUtil . componentsFromPathString ( relativePath ) ; Path subpath = PathUtil . appendPath ( path , components [ 0 ] ) ; merge . add ( new ResourceBase < T > ( subpath , null , true ) ) ; } } } return merge ; }
List all treeHandlers as directories which have the given path as a parent