lastChild = newDigestFileComponent;
lastChild = digestFileName;
    public static void setLock(File reposRootDir, SVNLock lock)throws SVNException{        if(lock == null){            SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.UNKNOWN, "FATAL error: attempt to set a null lock");            SVNErrorManager.error(err);        }        String lastChild = "";        String thisPath = lock.getPath();        while(true){                        String digestPath = FSRepositoryUtil.getDigestPathFromPath(reposRootDir, thisPath);            /*for Win*/            String[] splitDigestPath = digestPath.split("\\\\");            String newDigestFileComponent = splitDigestPath[splitDigestPath.length-1];            //String[] strArr = SVNPathUtil.extractParentAndChild(digestPath);                        //String digestFileComponent = strArr[1];            Collection children = new ArrayList();            SVNLock thisLock = FSReader.fetchLockFromDigestFile(new File(digestPath), thisPath, children, reposRootDir);            if(lock != null){                thisLock = lock;                lock = null;                lastChild = /*digestFileComponent*/newDigestFileComponent;            }else{                /* If we already have an entry for this path, we're done. */                if(children.contains(lastChild)){                    return;                }                /*otherwise add path into collection*/                children.add(lastChild);                            }                       FSWriter.writeDigestLockFile(thisLock, children, thisPath, reposRootDir);            if(thisPath.length() == 1 && thisPath.equals("/")){                return;            }                        String[] splitThisPath = thisPath.split("/");            StringBuffer newThisPath = new StringBuffer();            int count = 0;            do{                               newThisPath.append(splitThisPath[count]);                                newThisPath.append("/");                count++;            }while(count < splitThisPath.length-1);            if(count != 1){                newThisPath.deleteCharAt(newThisPath.length()-1);            }            thisPath = new String(newThisPath);            //thisPath = SVNPathUtil.svnPathDirName(thisPath);        }    }