You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by ju...@apache.org on 2002/04/10 10:08:15 UTC
cvs commit: jakarta-slide/src/share/org/apache/slide/content ContentImpl.java
juergen 02/04/10 01:08:15
Modified: src/share/org/apache/slide/content ContentImpl.java
Log:
Change in 'special-deltav'-create() method in order to allow backup of properties in the VCR.
(ralf)
Revision Changes Path
1.32 +12 -12 jakarta-slide/src/share/org/apache/slide/content/ContentImpl.java
Index: ContentImpl.java
===================================================================
RCS file: /home/cvs/jakarta-slide/src/share/org/apache/slide/content/ContentImpl.java,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- ContentImpl.java 28 Mar 2002 06:23:14 -0000 1.31
+++ ContentImpl.java 10 Apr 2002 08:08:15 -0000 1.32
@@ -1,7 +1,7 @@
/*
- * $Header: /home/cvs/jakarta-slide/src/share/org/apache/slide/content/ContentImpl.java,v 1.31 2002/03/28 06:23:14 jericho Exp $
- * $Revision: 1.31 $
- * $Date: 2002/03/28 06:23:14 $
+ * $Header: /home/cvs/jakarta-slide/src/share/org/apache/slide/content/ContentImpl.java,v 1.32 2002/04/10 08:08:15 juergen Exp $
+ * $Revision: 1.32 $
+ * $Date: 2002/04/10 08:08:15 $
*
* ====================================================================
*
@@ -77,7 +77,7 @@
* Implementation of the content interface.
*
* @author <a href="mailto:remm@apache.org">Remy Maucherat</a>
- * @version $Revision: 1.31 $
+ * @version $Revision: 1.32 $
*/
public final class ContentImpl implements Content {
@@ -1175,7 +1175,8 @@
/**
* Create new branch-less revision descriptor.
* This is used only by DeltaV to store the VHR-specific descriptor at
- * revision 0.0
+ * revision 0.0, or to backup the properties of a VCR for checkout/uncheckout
+ * at revision 0.0.
*/
protected void create( SlideToken token, String strUri,
NodeRevisionDescriptor revisionDescriptor )
@@ -1210,17 +1211,16 @@
objectUri.getStore()
.retrieveRevisionDescriptors(objectUri);
- if (!revisionDescriptors.isVersioned()) {
- // Invalid function call : we try to create a revision, but the
- // descriptors won't allow it
- throw new NodeNotVersionedException(strUri);
- }
-
// Set the creation date
revisionDescriptor.setCreationDate(new Date());
// Initialize the branch name in the new descriptor
- revisionDescriptor.setBranchName( "version-history" );
+ String branchName = "backup";
+ NodeProperty rootVersionProperty = revisionDescriptor.getProperty("version-set");
+ if (rootVersionProperty != null) {
+ branchName = "version-history";
+ }
+ revisionDescriptor.setBranchName(branchName);
// Invoke interceptors
invokeInterceptors(token, revisionDescriptors, revisionDescriptor,
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>