public VirtualFile getChild ( String path ) { if ( path == null ) { throw VFSMessages . MESSAGES . nullArgument ( "path" ) ; } final List < String > pathParts = PathTokenizer . getTokens ( path ) ; VirtualFile current = this ; for ( String part : pathParts ) { if ( PathTokenizer . isReverseToken ( part ) ) { final VirtualFile parent = current . parent ; current = parent == null ? current : parent ; } else if ( PathTokenizer . isCurrentToken ( part ) == false ) { current = new VirtualFile ( part , current ) ; } } return current ; }
Get a child virtual file . The child may or may not exist in the virtual filesystem .