source: java/SVNAccess/src/net/oni2/svnaccess/DirEntryHandler.java@ 864

Last change on this file since 864 was 732, checked in by alloc, 12 years ago

SVN access library

File size: 836 bytes
Line 
1package net.oni2.svnaccess;
2
3import java.util.Vector;
4
5import org.tmatesoft.svn.core.ISVNDirEntryHandler;
6import org.tmatesoft.svn.core.SVNDirEntry;
7import org.tmatesoft.svn.core.SVNException;
8import org.tmatesoft.svn.core.SVNNodeKind;
9
10
11/**
12 * Used to get the files in a SVN repository
13 *
14 * @author Christian Illy
15 */
16public class DirEntryHandler implements ISVNDirEntryHandler {
17
18 Vector<String> target;
19
20
21 /**
22 * Create a new DirEntryHandler with a list to store the found files in.
23 *
24 * @param targetList
25 * Vector used to store the file names
26 */
27 public DirEntryHandler(Vector<String> targetList) {
28 this.target = targetList;
29 }
30
31 @Override
32 public void handleDirEntry(SVNDirEntry dirEntry) throws SVNException {
33 if (dirEntry.getKind() == SVNNodeKind.FILE)
34 target.add(dirEntry.getURL().getPath());
35 }
36
37}
Note: See TracBrowser for help on using the repository browser.