You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by br...@apache.org on 2013/07/02 18:58:47 UTC
svn commit: r1499016 - in /subversion/trunk/subversion/bindings/javahl:
native/ src/org/apache/subversion/javahl/
src/org/apache/subversion/javahl/remote/ tests/org/apache/subversion/javahl/
Author: brane
Date: Tue Jul 2 16:58:46 2013
New Revision: 1499016
URL: http://svn.apache.org/r1499016
Log:
Remove the Ev2 rotate interface from JavaHL until its fate has been decided.
[in subversion/bindings/javahl/native]
* CommitEditor.h, CommitEditor.cpp (CommitEditor::rotate): Put in comment.
* org_apache_subversion_javahl_remote_CommitEditor.cpp
(Java_org_apache_subversion_javahl_remote_CommitEditor_rotate): Likewise.
[in subversion/bindings/javahl/src/org/apache/subversion/javahl]
* ISVNEditor.java, remote/CommitEditor.java (ISVNEditor.rotate): And here.
[in subversion/bindings/javahl/tests/org/apache/subversion/javahl]
* SVNRemoteTests.java (SVNRemoteTests.testEditorNotImplemented):
Coment out the bits related to ISVNEditor.rotate.
Modified:
subversion/trunk/subversion/bindings/javahl/native/CommitEditor.cpp
subversion/trunk/subversion/bindings/javahl/native/CommitEditor.h
subversion/trunk/subversion/bindings/javahl/native/org_apache_subversion_javahl_remote_CommitEditor.cpp
subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNEditor.java
subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/remote/CommitEditor.java
subversion/trunk/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNRemoteTests.java
Modified: subversion/trunk/subversion/bindings/javahl/native/CommitEditor.cpp
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/native/CommitEditor.cpp?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/native/CommitEditor.cpp (original)
+++ subversion/trunk/subversion/bindings/javahl/native/CommitEditor.cpp Tue Jul 2 16:58:46 2013
@@ -511,8 +511,8 @@ void CommitEditor::move(jstring jsrc_rel
svn_revnum_t(jreplaces_revision)),);
}
-void CommitEditor::rotate(jobject jelements)
-{
+// void CommitEditor::rotate(jobject jelements)
+// {
// if (!m_valid)
// {
// throw_editor_inactive();
@@ -528,8 +528,7 @@ void CommitEditor::rotate(jobject jeleme
// return;
//
// SVN_JNI_ERR(svn_editor_rotate(m_editor, relpaths, revisions),);
- throw_not_implemented("rotate");
-}
+// }
void CommitEditor::complete()
{
Modified: subversion/trunk/subversion/bindings/javahl/native/CommitEditor.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/native/CommitEditor.h?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/native/CommitEditor.h (original)
+++ subversion/trunk/subversion/bindings/javahl/native/CommitEditor.h Tue Jul 2 16:58:46 2013
@@ -81,7 +81,7 @@ public:
jstring jdst_relpath, jlong jreplaces_revision);
void move(jstring jsrc_relpath, jlong jsrc_revision,
jstring jdst_relpath, jlong jreplaces_revision);
- void rotate(jobject jelements);
+ // void rotate(jobject jelements);
void complete();
void abort();
Modified: subversion/trunk/subversion/bindings/javahl/native/org_apache_subversion_javahl_remote_CommitEditor.cpp
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/native/org_apache_subversion_javahl_remote_CommitEditor.cpp?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/native/org_apache_subversion_javahl_remote_CommitEditor.cpp (original)
+++ subversion/trunk/subversion/bindings/javahl/native/org_apache_subversion_javahl_remote_CommitEditor.cpp Tue Jul 2 16:58:46 2013
@@ -182,15 +182,15 @@ Java_org_apache_subversion_javahl_remote
editor->move(jsrc_relpath, jsrc_revision, jdst_relpath, jreplaces_revision);
}
-JNIEXPORT void JNICALL
-Java_org_apache_subversion_javahl_remote_CommitEditor_rotate(
- JNIEnv* env, jobject jthis, jobject jelements)
-{
- JNIEntry(CommitEditor, rotate);
- CommitEditor *editor = CommitEditor::getCppObject(jthis);
- CPPADDR_NULL_PTR(editor,);
- editor->rotate(jelements);
-}
+//JNIEXPORT void JNICALL
+//Java_org_apache_subversion_javahl_remote_CommitEditor_rotate(
+// JNIEnv* env, jobject jthis, jobject jelements)
+//{
+// JNIEntry(CommitEditor, rotate);
+// CommitEditor *editor = CommitEditor::getCppObject(jthis);
+// CPPADDR_NULL_PTR(editor,);
+// editor->rotate(jelements);
+//}
JNIEXPORT void JNICALL
Java_org_apache_subversion_javahl_remote_CommitEditor_complete(
Modified: subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNEditor.java
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNEditor.java?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNEditor.java (original)
+++ subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ISVNEditor.java Tue Jul 2 16:58:46 2013
@@ -273,40 +273,42 @@ public interface ISVNEditor
String destinationRelativePath,
long replacesRevision)
throws ClientException;
- /**
- * Perform a rotation among multiple nodes in the target tree.
- * <p>
- * The <code>elements</code> list specifies the nodes in the tree
- * which are located at a path and expected to be at a specific
- * revision. These nodes are simultaneously moved in a rotation
- * pattern. For example, the node at index 0
- * <code>elements</code> will be moved to the relative path
- * specified at index 1 of <code>elements</code>. The node at
- * index 1 will be moved to the location at index 2. The node at
- * index N-1 will be moved to the relative path specified at index 0.
- * <p>
- * The simplest form of this operation is to swap nodes A and
- * B. One may think to move A to a temporary location T, then move
- * B to A, then move T to B. However, this last move violations
- * the Once Rule by moving T (which had already by edited by the
- * move from A). In order to keep the restrictions against
- * multiple moves of a single node, the rotation operation is
- * needed for certain types of tree edits.
- *
- * @throws ClientException
- */
- void rotate(Iterable<RotatePair> elements) throws ClientException;
- public static final class RotatePair
- {
- public RotatePair(String relativePath, long revision)
- {
- this.relativePath = relativePath;
- this.revision = revision;
- }
- public final String relativePath;
- public final long revision;
- }
+// Not implemented in the native API
+// /**
+// * Perform a rotation among multiple nodes in the target tree.
+// * <p>
+// * The <code>elements</code> list specifies the nodes in the tree
+// * which are located at a path and expected to be at a specific
+// * revision. These nodes are simultaneously moved in a rotation
+// * pattern. For example, the node at index 0
+// * <code>elements</code> will be moved to the relative path
+// * specified at index 1 of <code>elements</code>. The node at
+// * index 1 will be moved to the location at index 2. The node at
+// * index N-1 will be moved to the relative path specified at index 0.
+// * <p>
+// * The simplest form of this operation is to swap nodes A and
+// * B. One may think to move A to a temporary location T, then move
+// * B to A, then move T to B. However, this last move violations
+// * the Once Rule by moving T (which had already by edited by the
+// * move from A). In order to keep the restrictions against
+// * multiple moves of a single node, the rotation operation is
+// * needed for certain types of tree edits.
+// *
+// * @throws ClientException
+// */
+// void rotate(Iterable<RotatePair> elements) throws ClientException;
+//
+// public static final class RotatePair
+// {
+// public RotatePair(String relativePath, long revision)
+// {
+// this.relativePath = relativePath;
+// this.revision = revision;
+// }
+// public final String relativePath;
+// public final long revision;
+// }
/**
* Signal that the edit has been completed successfully.
Modified: subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/remote/CommitEditor.java
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/remote/CommitEditor.java?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/remote/CommitEditor.java (original)
+++ subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/remote/CommitEditor.java Tue Jul 2 16:58:46 2013
@@ -94,7 +94,7 @@ public class CommitEditor extends JNIObj
String target,
Map<String, byte[]> properties)
throws ClientException;
-
+
public native void delete(String relativePath,
long revision)
throws ClientException;
@@ -111,11 +111,8 @@ public class CommitEditor extends JNIObj
long replacesRevision)
throws ClientException;
- /**
- * <b>Note:</b> Not implemented.
- */
- public native void rotate(Iterable<RotatePair> elements)
- throws ClientException;
+// public native void rotate(Iterable<RotatePair> elements)
+// throws ClientException;
public native void complete() throws ClientException;
Modified: subversion/trunk/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNRemoteTests.java
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNRemoteTests.java?rev=1499016&r1=1499015&r2=1499016&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNRemoteTests.java (original)
+++ subversion/trunk/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNRemoteTests.java Tue Jul 2 16:58:46 2013
@@ -649,8 +649,8 @@ public class SVNRemoteTests extends SVNT
ISVNRemote session = getSession();
HashMap<String, byte[]> props = new HashMap<String, byte[]>();
- ArrayList<ISVNEditor.RotatePair> rotation =
- new ArrayList<ISVNEditor.RotatePair>();
+ // ArrayList<ISVNEditor.RotatePair> rotation =
+ // new ArrayList<ISVNEditor.RotatePair>();
CommitContext cc = new CommitContext(session, "not implemented");
try {
@@ -672,12 +672,12 @@ public class SVNRemoteTests extends SVNT
}
assertEquals("Not implemented: CommitEditor.alterSymlink", exmsg);
- try {
- exmsg = "";
- cc.editor.rotate(rotation);
- } catch (IllegalStateException ex) {
- exmsg = ex.getMessage();
- }
+ // try {
+ // exmsg = "";
+ // cc.editor.rotate(rotation);
+ // } catch (IllegalStateException ex) {
+ // exmsg = ex.getMessage();
+ // }
assertEquals("Not implemented: CommitEditor.rotate", exmsg);
} finally {
cc.editor.dispose();