Examples of ISVNStatusHandler


Examples of org.exist.versioning.svn.wc.ISVNStatusHandler

        final boolean[] isModified = { false };
        final boolean[] isSparseCheckOut = { false };
        final SVNURL[] wcURL = { null };
       
        SVNStatusEditor editor = new SVNStatusEditor(null, wcAccess, anchor, false, true,
                    SVNDepth.INFINITY, new ISVNStatusHandler() {
                public void handleStatus(SVNStatus status) throws SVNException {
                    SVNEntry entry = status.getEntry();
                    if (entry == null) {
                        return;
                    }
View Full Code Here

Examples of org.exist.versioning.svn.wc.ISVNStatusHandler

    public void absentFile(String path) throws SVNException {
    }
   
    private void handleStatusHash(SVNEntry dirEntry, Map hash, boolean deleted, SVNDepth depth) throws SVNException {
        ISVNStatusHandler handler = deleted ? this : getDefaultHandler();
        for(Iterator paths = hash.keySet().iterator(); paths.hasNext();) {
            File path = (File) paths.next();
            SVNStatus status = (SVNStatus) hash.get(path);
           
            if (status.getContentsStatus() != SVNStatusType.STATUS_OBSTRUCTED &&
                status.getContentsStatus() != SVNStatusType.STATUS_MISSING &&
                status.getEntry() != null && status.getKind() == SVNNodeKind.DIR &&
                (depth == SVNDepth.UNKNOWN || depth == SVNDepth.IMMEDIATES ||
                 depth == SVNDepth.INFINITY)) {
                SVNAdminArea dir = getWCAccess().retrieve(path);
                SVNDepth depthMinusOne = depth;
                if (depthMinusOne == SVNDepth.IMMEDIATES) {
                    depthMinusOne = SVNDepth.EMPTY;
                }
                getDirStatus(dirEntry, dir, null, depthMinusOne, isReportAll(), isNoIgnore(), null, true, handler);
            }
            if (deleted) {
                status.setRemoteStatus(SVNStatusType.STATUS_DELETED, null, null, null);
            }
            if (isSendableStatus(status)) {
                handler.handleStatus(status);
            }
        }
    }
View Full Code Here

Examples of org.exist.versioning.svn.wc.ISVNStatusHandler

                public void handleEvent(SVNEvent event, double progress) throws SVNException {
                }
            });
        }
        statusClient.doStatus(path, SVNRevision.UNDEFINED, SVNDepth.INFINITY, false, false, false, false, new ISVNStatusHandler() {
            public void handleStatus(SVNStatus status) throws SVNException {
                if (status.getContentsStatus() == SVNStatusType.STATUS_OBSTRUCTED) {
                    SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.NODE_UNEXPECTED_KIND, "''{0}'' is in the way of the resource actually under version control", status.getFile());
                    SVNErrorManager.error(err, SVNLogType.WC);
                } else if (status.getEntry() == null) {
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

        final boolean[] isModified = { false };
        final boolean[] isSparseCheckOut = { false };
        final SVNURL[] wcURL = { null };
       
        SVNStatusEditor editor = new SVNStatusEditor(null, wcAccess, anchor, false, true,
                    SVNDepth.INFINITY, new ISVNStatusHandler() {
                public void handleStatus(SVNStatus status) throws SVNException {
                    SVNEntry entry = status.getEntry();
                    if (entry == null) {
                        return;
                    }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

                public void handleEvent(SVNEvent event, double progress) throws SVNException {
                }
            });
        }
        statusClient.doStatus(path, SVNRevision.UNDEFINED, SVNDepth.INFINITY, false, false, false, false, new ISVNStatusHandler() {
            public void handleStatus(SVNStatus status) throws SVNException {
                if (status.getContentsStatus() == SVNStatusType.STATUS_OBSTRUCTED) {
                    SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.NODE_UNEXPECTED_KIND, "''{0}'' is in the way of the resource actually under version control", status.getFile());
                    SVNErrorManager.error(err, SVNLogType.WC);
                } else if (status.getEntry() == null) {
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

    public void absentFile(String path) throws SVNException {
    }
   
    private void handleStatusHash(SVNEntry dirEntry, Map hash, boolean deleted, SVNDepth depth) throws SVNException {
        ISVNStatusHandler handler = deleted ? this : getDefaultHandler();
        for(Iterator paths = hash.keySet().iterator(); paths.hasNext();) {
            File path = (File) paths.next();
            SVNStatus status = (SVNStatus) hash.get(path);
           
            if (status.getContentsStatus() != SVNStatusType.STATUS_OBSTRUCTED &&
                status.getContentsStatus() != SVNStatusType.STATUS_MISSING &&
                status.getEntry() != null && status.getKind() == SVNNodeKind.DIR &&
                (depth == SVNDepth.UNKNOWN || depth == SVNDepth.IMMEDIATES ||
                 depth == SVNDepth.INFINITY)) {
                SVNAdminArea dir = getWCAccess().retrieve(path);
                SVNDepth depthMinusOne = depth;
                if (depthMinusOne == SVNDepth.IMMEDIATES) {
                    depthMinusOne = SVNDepth.EMPTY;
                }
                getDirStatus(dirEntry, dir, null, depthMinusOne, isReportAll(), isNoIgnore(), null, true, handler);
            }
            if (deleted) {
                status.setRemoteStatus(SVNStatusType.STATUS_DELETED, null, null, null);
            }
            if (isSendableStatus(status)) {
                handler.handleStatus(status);
            }
        }
    }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

            //checkout the entire repository tree
            SamplesUtility.checkOutWorkingCopy(reposURL, wcRoot);

            SVNClientManager clientManager = SVNClientManager.newInstance();
            SVNStatusClient statusClient = clientManager.getStatusClient();
            ISVNStatusHandler handler = new StatusHandler();

            statusClient.doStatus(wcRoot, SVNRevision.WORKING, SVNDepth.INFINITY, true, true, false, false,
                    handler, null);
           
            SVNWCClient wcClient = clientManager.getWCClient();
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

        if (path == null) {
            return null;
        }
        final Collection statuses = new ArrayList();
        status(path, JavaHLObjectFactory.unknownOrImmediates(descend), onServer, getAll, noIgnore,
                ignoreExternals, null, new ISVNStatusHandler() {
            public void handleStatus(SVNStatus status) {
                statuses.add(JavaHLObjectFactory.createStatus(status.getFile().getPath(), status));
            }
        });
        return (Status[]) statuses.toArray(new Status[statuses.size()]);
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

    }

    public void status(String path, int depth, boolean onServer, boolean getAll, boolean noIgnore,
            boolean ignoreExternals, String[] changelists, StatusCallback callback) throws ClientException {
        final StatusCallback statusCallback = callback;
        status(path, depth, onServer, getAll, noIgnore, ignoreExternals, changelists, new ISVNStatusHandler() {
            public void handleStatus(SVNStatus status) {
                if (statusCallback != null) {
                    statusCallback.doStatus(JavaHLObjectFactory.createStatus(status.getFile().getPath(), status));
                }
            }
View Full Code Here

Examples of org.tmatesoft.svn.core.wc.ISVNStatusHandler

        final Collection statuses = new ArrayList();
        SVNStatusClient stClient = getSVNStatusClient();
        boolean oldIgnoreExternals = stClient.isIgnoreExternals();
        stClient.setIgnoreExternals(ignoreExternals);
        try {
            stClient.doStatus(new File(path).getAbsoluteFile(), descend, onServer, getAll, noIgnore, !ignoreExternals, new ISVNStatusHandler(){
                public void handleStatus(SVNStatus status) {
                    statuses.add(JavaHLObjectFactory.createStatus(status.getFile().getPath(), status));
                }
            });
        } catch (SVNException e) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.