Package org.exist.util.io

Examples of org.exist.util.io.Resource


        }
        return false;
    }

    private String getStoredServerCertificate(String realm) {
    File file = new Resource(myAuthDirectory, SVNFileUtil.computeChecksum(realm));
    if (!file.isFile()) {
      return null;
    }
    SVNWCProperties props = new SVNWCProperties(file, "");
    try {
      String storedRealm = props.getPropertyValue("svn:realmstring");
View Full Code Here


  }

  private void storeServerCertificate(String realm, String data, int failures) throws SVNException {
    myAuthDirectory.mkdirs();

    File file = new Resource(myAuthDirectory, SVNFileUtil.computeChecksum(realm));
    SVNHashMap map = new SVNHashMap();
        map.put("ascii_cert", data);
        map.put("svn:realmstring", realm);
        map.put("failures", Integer.toString(failures));
       
View Full Code Here

    protected class SVNDirectoryInfo {

        public SVNDirectoryInfo(SVNDirectoryInfo parent, String path, boolean added) {
            myParent = parent;
            myRepositoryPath = path;
            myWCFile = myTarget != null ? new Resource(myTarget, path) : null;
            myIsAdded = added;
            myPropertyDiff = new SVNProperties();
        }
View Full Code Here

    protected class SVNFileInfo {

        public SVNFileInfo(String path, boolean added) {
            myRepositoryPath = path;
            myIsAdded = added;
            myWCFile = myTarget != null ? new Resource(myTarget, path) : null;
            myPropertyDiff = new SVNProperties();
        }
View Full Code Here

    public abstract SVNStatusType[] directoryClosed(String path, boolean[] isTreeConflicted) throws SVNException;

    protected String getDisplayPath(String path) {
        if (myAdminArea == null) {
            if (myBasePath != null) {
                return new Resource(myBasePath, path).getAbsolutePath().replace(Resource.separatorChar, '/');
            }
            return path.replace(Resource.separatorChar, '/');
        }
        return myAdminArea.getFile(path).getAbsolutePath().replace(Resource.separatorChar, '/');
    }
View Full Code Here

            super(path);
        }

        public SVNAdminArea getAdminArea() throws SVNException {
            String path = getPath();
            File file = new Resource(myAdminInfo.getAnchor().getRoot(), path);
            SVNAdminArea area = myAdminInfo.getWCAccess().retrieve(file);
            if (myIsLockOnDemand && area != null && !area.isLocked()) {
                area.lock(false);
                area = myAdminInfo.getWCAccess().upgrade(file);
            }
View Full Code Here

    }

    protected void addDeletedPath(String path, SVNNodeKind nodeKind, SVNStatusType type, SVNEventAction action, SVNEventAction expectedAction,
            boolean isTreeConflicted) {
        if (myEventHandler != null) {
            File deletedFile = new Resource(myTarget, path);
            KindActionState kas = new KindActionState();
            kas.myAction = action;
            kas.myKind = nodeKind;
            kas.myStatus = type;
            kas.myExpectedAction = expectedAction;
View Full Code Here

    public void abortEdit() throws SVNException {
    }

    public void absentDir(String path) throws SVNException {
        if (myCurrentDirectory.myWCFile != null) {
            File dir = new Resource(myCurrentDirectory.myWCFile, SVNPathUtil.tail(path));
            SVNEvent event = SVNEventFactory.createSVNEvent(dir, SVNNodeKind.DIR,
                    null, SVNRepository.INVALID_REVISION, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNEventAction.SKIP, SVNEventAction.SKIP,
                    null, null);
            myEventHandler.handleEvent(event, ISVNEventHandler.UNKNOWN);
        }
View Full Code Here

        }
    }

    public void absentFile(String path) throws SVNException {
        if (myCurrentDirectory.myWCFile != null) {
            File file = new Resource(myCurrentDirectory.myWCFile, SVNPathUtil.tail(path));
            SVNEvent event = SVNEventFactory.createSVNEvent(file, SVNNodeKind.FILE,
                    null, SVNRepository.INVALID_REVISION, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNStatusType.MISSING, SVNEventAction.SKIP, SVNEventAction.SKIP,
                    null, null);
            myEventHandler.handleEvent(event, ISVNEventHandler.UNKNOWN);
        }
View Full Code Here

    public Sequence eval(Sequence[] args, Sequence contextSequence) throws XPathException {
    WorkingCopy wc = new WorkingCopy("", "");
       
        String uri = args[0].getStringValue();
      
        Resource wcDir = new Resource(uri);
       
        try {
      wc.unlock(wcDir, false);
    } catch (SVNException e) {
            throw new XPathException(this, e.getMessage(), e);
View Full Code Here

TOP

Related Classes of org.exist.util.io.Resource

Copyright © 2018 www.massapicom. 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.