Examples of openRoot()


Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        // created or if new subversion repo created
        if (dbCreated || repoCreated) {
            Map<String, String> props = new HashMap<String, String>();
            props.put(Params.Svn.DBURLPROP, dbUrl);
            ISVNEditor editor = getEditor("Setting " + Params.Svn.DBURLPROP + " to " + dbUrl);
            editor.openRoot(-1);
            SvnUtils.modifyFileProps(editor, "/", props);
            editor.closeDir();
            SVNCommitInfo info = editor.closeEdit();
            if (Log.isDebugEnabled(Geonet.SVN_MANAGER))
                Log.debug(Geonet.SVN_MANAGER, "Committed " + dbUrl + " as property " + Params.Svn.DBURLPROP + ":" + info);
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        ISVNEditor editor = null;

        if (task != null) {
            try {
                editor = getEditor(task.sessionLogMessage + " (committing transaction " + status + ")");
                editor.openRoot(-1); // open the root directory.
                for (Iterator<String> it = task.ids.iterator(); it.hasNext(); ) {
                    String id = it.next();
                    commitMetadata(id, editor);
                    it.remove();
                }
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        ISVNEditor editor = getEditor(logMessage);

        try {
            // Create an id/ directory item in the repository
            editor.openRoot(-1);
            SvnUtils.addDir(editor, id);
            if (Log.isDebugEnabled(Geonet.SVN_MANAGER))
                Log.debug(Geonet.SVN_MANAGER, "Directory for metadata " + id + " was added");
            editor.closeDir();
            editor.closeEdit();
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        // Add the id/metadata.xml item plus properties to the repository
        try {
            logMessage = sessionToLogMessage(context) + " adding initial version of metadata " + id;
            editor = getEditor(logMessage);
            editor.openRoot(-1);
            final ISVNEditor finalEditor = editor;

            commitMetadata(id, finalEditor);

            if (Log.isDebugEnabled(Geonet.SVN_MANAGER))
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        }
        checkCancelled();
        boolean changed = false;
        SVNCommitInfo info = null;
        try {
            commitEditor.openRoot(-1);
            String newDirPath = null;
            for (int i = newPaths.size() - 1; i >= 0; i--) {
                newDirPath = newDirPath == null ? (String) newPaths.get(i) : SVNPathUtil.append(newDirPath, (String) newPaths.get(i));
                commitEditor.addDir(newDirPath, null, -1);
            }
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

    }

    public SVNCommitInfo closeEdit() throws SVNException {
        ISVNEditor wrappedEditor = getWrappedEditor();
        if (!myIsRootOpened) {
            wrappedEditor.openRoot(myBaseRevision);
        }
        myCommitInfo = wrappedEditor.closeEdit();
        if (myHandler != null) {
            SVNLogEntry logEntry = new SVNLogEntry(null, myCommitInfo.getNewRevision(), myCommitInfo.getAuthor(), myCommitInfo.getDate(), null);
            myHandler.handleLogEntry(logEntry);
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

              + fullPath + ". It's file..");
        }
      }

      editor = repo.getCommitEditor(fileEntry.getDescription(), null, true, null);
      editor.openRoot(-1);
      fullPath = "";
      for (String each : getPathFragment(fileEntry.getPath())) {
        fullPath = fullPath + "/" + each;
        try {
          editor.addDir(fullPath, null, -1);
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

    try {
      svnClientManager = getSVNClientManager();
      SVNRepository repo = svnClientManager.createRepository(SVNURL.fromFile(getUserRepoDirectory(user)), true);

      editor = repo.getCommitEditor("delete", null, true, null);
      editor.openRoot(-1);
      for (String each : paths) {
        editor.deleteEntry(each, -1);
      }
    } catch (Exception e) {
      abortSVNEditorQuietly(editor);
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

        }
        checkCancelled();
        boolean changed = false;
        SVNCommitInfo info = null;
        try {
            commitEditor.openRoot(-1);
            String newDirPath = null;
            for (int i = newPaths.size() - 1; i >= 0; i--) {
                newDirPath = newDirPath == null ? (String) newPaths.get(i) : SVNPathUtil.append(newDirPath, (String) newPaths.get(i));
                commitEditor.addDir(newDirPath, null, -1);
            }
View Full Code Here

Examples of org.tmatesoft.svn.core.io.ISVNEditor.openRoot()

            return SVNCommitInfo.NULL;
        }
        commitMessage = SVNCommitClient.validateCommitMessage(commitMessage);
        ISVNEditor commitEditor = repos.getCommitEditor(commitMessage, null, true, revisionProperties, null);
        try {
            commitEditor.openRoot(revNumber);
            if (kind == SVNNodeKind.FILE) {
                commitEditor.openFile("", revNumber);
                commitEditor.changeFileProperty("", propName, propValue);
                commitEditor.closeFile("", null);
            } else {
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.