/** * @return repository path * @deprecated use {@link #getRelativePath()} instead. */ public String getPath() { return getRelativePath(); }
/** * @return repository path * @deprecated use {@link #getRelativePath()} instead. */ public String getPath() { return getRelativePath(); }
/** * @return repository path * @deprecated use {@link #getRelativePath()} instead. */ public String getPath() { return getRelativePath(); }
/** * @deprecated use {@link #getRelativePath()} instead. */ public String getPath() { return getRelativePath(); }
public void handleDirEntry( SVNDirEntry svnDirEntry ) throws SVNException { if ( StringUtils.isNotEmpty( svnDirEntry.getRelativePath() ) ) { relativePaths.add( svnDirEntry.getRelativePath() ); } } }
@Override public void handleDirEntry(SVNDirEntry dirEntry) throws SVNException { String path = dirEntry.getRelativePath(); // first path is "", exclude it if (!path.isEmpty()) { files.add(path); } } };
public void handleDirEntry(SVNDirEntry dirEntry) { if (dirEntry.getRelativePath().length() != 0) { allEntries.add(JavaHLObjectFactory.createDirEntry(dirEntry)); } } });
public void handleDirEntry(SVNDirEntry dirEntry) { if (dirEntry.getRelativePath().length() != 0) { allEntries.add(JavaHLObjectFactory.createDirEntry(dirEntry)); } } });
@Override public void handleDirEntry(SVNDirEntry svnDirEntry) throws SVNException { // from the svn docs: The directory entry for url is reported using an empty path. // If SVNDepth.IMMEDIATES, lists its immediate file and directory entries // So identify the parent as the one with an empty relative path if (CharMatcher.WHITESPACE.matchesAllOf(Strings.nullToEmpty(svnDirEntry.getRelativePath()))) { this.parent = svnDirEntry; } else if (childFilter.apply(svnDirEntry)) { this.children.add(svnDirEntry); } }
@Override public void handleDirEntry(SVNDirEntry svnDirEntry) throws SVNException { // from the svn docs: The directory entry for url is reported using an empty path. // If SVNDepth.IMMEDIATES, lists its immediate file and directory entries // So identify the parent as the one with an empty relative path if (CharMatcher.WHITESPACE.matchesAllOf(Strings.nullToEmpty(svnDirEntry.getRelativePath()))) { this.parent = svnDirEntry; } else if (childFilter.apply(svnDirEntry)) { this.children.add(svnDirEntry); } }
public void handleDirEntry(SVNDirEntry dirEntry) { if (dirEntry.getRelativePath().length() != 0) { allEntries.add(JavaHLObjectFactory.createDirEntry(dirEntry)); } } });
@Override public void handleDirEntry(SVNDirEntry dirEntry) throws SVNException { dirents.put(dirEntry.getRelativePath(), SVNClientImpl.getDirEntry(dirEntry, reposRelativePath)); } });
protected static DirEntry getDirEntry(SVNDirEntry dirEntry, String reposRelativePath) { if (dirEntry == null) { return null; } return new DirEntry(dirEntry.getRelativePath(), SVNPathUtil.append(reposRelativePath, dirEntry.getRelativePath()), SVNClientImpl.getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), dirEntry.getDate().getTime(), dirEntry.getAuthor()); }
private void dumpRepositoryContents() throws SVNException { System.out.println("Repository contents:"); SVNURL repoURL = SVNURL.parseURIEncoded( "svn://localhost/"); SVNLogClient logClient = new SVNLogClient((ISVNAuthenticationManager)null, null); logClient.doList(repoURL, SVNRevision.HEAD, SVNRevision.HEAD, false, true, dirEntry -> System.out.println(dirEntry.getRelativePath())); }
public static DirEntry createDirEntry(SVNDirEntry dirEntry) { if(dirEntry == null){ return null; } return new DirEntry( dirEntry.getRelativePath(), getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), dirEntry.getDate() != null ? dirEntry.getDate().getTime()*1000 : 0, dirEntry.getAuthor() ); }
public static DirEntry createDirEntry(SVNDirEntry dirEntry) { if(dirEntry == null){ return null; } SVNURL url = dirEntry.getURL(); SVNURL repositoryRoot = dirEntry.getRepositoryRoot(); String relativeToRepositoryRoot = SVNPathUtil.getRelativePath(repositoryRoot.getPath(), url.getPath()); String relativeToTargetPath = dirEntry.getRelativePath(); String targetToRootPath = relativeToRepositoryRoot.substring(0, relativeToRepositoryRoot.length() - relativeToTargetPath.length()); return new DirEntry( relativeToTargetPath, SVNPathUtil.getAbsolutePath(targetToRootPath), getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), dirEntry.getDate() != null ? dirEntry.getDate().getTime()*1000 : 0, dirEntry.getAuthor() ); }
public static DirEntry createDirEntry(SVNDirEntry dirEntry) { if(dirEntry == null){ return null; } SVNURL url = dirEntry.getURL(); SVNURL repositoryRoot = dirEntry.getRepositoryRoot(); String relativeToRepositoryRoot = SVNPathUtil.getRelativePath(repositoryRoot.getPath(), url.getPath()); String relativeToTargetPath = dirEntry.getRelativePath(); String targetToRootPath = relativeToRepositoryRoot.substring(0, relativeToRepositoryRoot.length() - relativeToTargetPath.length()); return new DirEntry( relativeToTargetPath, SVNPathUtil.getAbsolutePath(targetToRootPath), getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), dirEntry.getDate() != null ? dirEntry.getDate().getTime()*1000 : 0, dirEntry.getAuthor() ); }
public static DirEntry createDirEntry(SVNDirEntry dirEntry) { if(dirEntry == null){ return null; } SVNURL url = dirEntry.getURL(); SVNURL repositoryRoot = dirEntry.getRepositoryRoot(); String relativeToRepositoryRoot = SVNPathUtil.getRelativePath(repositoryRoot.getPath(), url.getPath()); String relativeToTargetPath = dirEntry.getRelativePath(); String targetToRootPath = relativeToRepositoryRoot.substring(0, relativeToRepositoryRoot.length() - relativeToTargetPath.length()); return new DirEntry( relativeToTargetPath, SVNPathUtil.getAbsolutePath(targetToRootPath), getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), dirEntry.getDate() != null ? dirEntry.getDate().getTime()*1000 : 0, dirEntry.getAuthor() ); }
private DirEntry getDirEntry(SVNDirEntry dirEntry) { if (dirEntry == null) { return null; } String repositoryRootString = getUrlString(dirEntry.getRepositoryRoot()); String urlString = getUrlString(dirEntry.getURL()); String absolutePath = SVNPathUtil.getRelativePath(repositoryRootString, urlString); return new DirEntry(dirEntry.getRelativePath(), absolutePath, getNodeKind(dirEntry.getKind()), dirEntry.getSize(), dirEntry.hasProperties(), dirEntry.getRevision(), getLongDate(dirEntry.getDate()), dirEntry.getAuthor()); }
public void process( @NotNull CmdLine cmdLine ) throws IOException, SVNException { cmdLine.out( SubversionMessageHandler.get( "module.list.repository.entries" ) ); String repositoryUrl = cmdLine.read( SubversionMessageHandler.get( "wich.repository.shall.be.used" ), subversionSupport.getRepositoryUrls(), null ); subversionSupport.addRepositoryUrl( repositoryUrl ); cmdLine.warning( SubversionMessageHandler.get( "listing.repository.entries" ) ); cmdLine.out( SubversionMessageHandler.get( "repository" ) ); cmdLine.success( '\t' + repositoryUrl ); SVNURL svnurl = SVNURL.parseURIDecoded( repositoryUrl ); SVNRepository repository = SVNRepositoryFactory.create( svnurl ); repository.setAuthenticationManager( subversionSupport.getAuthenticationManager() ); Collection<SVNDirEntry> dirEntry = repository.getDir( ".", repository.getLatestRevision(), null, ( Collection<?> ) null ); for ( SVNDirEntry entry : dirEntry ) { cmdLine.out( entry.getRelativePath() + "\t\t(" + entry.getKind() + ")" ); } } }