jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clomb...@apache.org
Subject svn commit: r555085 - in /jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model: BeanDescriptor.java ChildNodeDefDescriptor.java CollectionDescriptor.java
Date Tue, 10 Jul 2007 21:32:46 GMT
Author: clombart
Date: Tue Jul 10 14:32:45 2007
New Revision: 555085

URL: http://svn.apache.org/viewvc?view=rev&rev=555085
Log:
patch for issue JCR-998 provided by Carlos Sanchez ( annotation support - still in progress)

Modified:
    jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/BeanDescriptor.java
    jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ChildNodeDefDescriptor.java
    jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/CollectionDescriptor.java

Modified: jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/BeanDescriptor.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/BeanDescriptor.java?view=diff&rev=555085&r1=555084&r2=555085
==============================================================================
--- jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/BeanDescriptor.java
(original)
+++ jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/BeanDescriptor.java
Tue Jul 10 14:32:45 2007
@@ -16,10 +16,7 @@
  */
 package org.apache.jackrabbit.ocm.mapper.model;
 
-
 import org.apache.jackrabbit.ocm.manager.beanconverter.BeanConverter;
-import org.apache.jackrabbit.ocm.manager.objectconverter.impl.ObjectConverterImpl;
-import org.apache.jackrabbit.ocm.reflection.ReflectionUtils;
 
 /**
  * BeanDescriptor is used by the mapper to read general information on a bean field
@@ -46,6 +43,7 @@
     private boolean jcrProtected;
     private boolean jcrSameNameSiblings;
     private boolean jcrMultiple;
+    private String defaultPrimaryType;
 
     /**
      * @return Returns the fieldName.
@@ -285,4 +283,12 @@
 		
 		return "Bean Descriptor : " +  this.fieldName;
 	}    
+
+    public String getDefaultPrimaryType() {
+        return defaultPrimaryType;
+    }
+
+    public void setDefaultPrimaryType(String defaultPrimaryType) {
+        this.defaultPrimaryType = defaultPrimaryType;
+    }
 }

Modified: jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ChildNodeDefDescriptor.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ChildNodeDefDescriptor.java?view=diff&rev=555085&r1=555084&r2=555085
==============================================================================
--- jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ChildNodeDefDescriptor.java
(original)
+++ jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/ChildNodeDefDescriptor.java
Tue Jul 10 14:32:45 2007
@@ -1,61 +1,67 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.jackrabbit.ocm.mapper.model;
-
-/**
- * ChildNodeDefDescriptor is used by the node type management tools based on
- * class descriptors to manage child node definitions
- *
- * @author <a href="mailto:fmeschbe[at]apache[dot]com">Felix Meschberger</a>
- */
-public interface ChildNodeDefDescriptor {
-
-    /**
-     * @return Returns the name of the property.
-     */
-    String getJcrName();
-
-    /**
-     * @return Returns the child node type name.
-     */
-    String getJcrNodeType();
-
-    /**
-     * @return Whether the child node is auto created.
-     */
-    boolean isJcrAutoCreated();
-
-    /**
-     * @return Whether the child node is mandatory.
-     */
-    boolean isJcrMandatory();
-
-    /**
-     * @return What to do on parent version creation.
-     */
-    String getJcrOnParentVersion();
-
-    /**
-     * @return Whether the child node is protected.
-     */
-    boolean isJcrProtected();
-
-    /**
-     * @return Whether the child node definition allows for same name sibblings.
-     */
-    boolean isJcrSameNameSiblings();
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.jackrabbit.ocm.mapper.model;
+
+/**
+ * ChildNodeDefDescriptor is used by the node type management tools based on
+ * class descriptors to manage child node definitions
+ *
+ * @author <a href="mailto:fmeschbe[at]apache[dot]com">Felix Meschberger</a>
+ */
+public interface ChildNodeDefDescriptor {
+
+    /**
+     * @return Returns the name of the property.
+     */
+    String getJcrName();
+
+    /**
+     * @return Returns the child node type name.
+     */
+    String getJcrNodeType();
+
+    /**
+     * @return Whether the child node is auto created.
+     */
+    boolean isJcrAutoCreated();
+
+    /**
+     * @return Whether the child node is mandatory.
+     */
+    boolean isJcrMandatory();
+
+    /**
+     * @return What to do on parent version creation.
+     */
+    String getJcrOnParentVersion();
+
+    /**
+     * @return Whether the child node is protected.
+     */
+    boolean isJcrProtected();
+
+    /**
+     * @return Whether the child node definition allows for same name sibblings.
+     */
+    boolean isJcrSameNameSiblings();
+
+    /**
+     * @return Whether the default not type to use when create new instances of this child
+     */
+    String getDefaultPrimaryType();
+
+}

Modified: jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/CollectionDescriptor.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/CollectionDescriptor.java?view=diff&rev=555085&r1=555084&r2=555085
==============================================================================
--- jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/CollectionDescriptor.java
(original)
+++ jackrabbit/trunk/contrib/jackrabbit-jcr-mapping/jcr-mapping/src/main/java/org/apache/jackrabbit/ocm/mapper/model/CollectionDescriptor.java
Tue Jul 10 14:32:45 2007
@@ -16,6 +16,7 @@
  */
 package org.apache.jackrabbit.ocm.mapper.model;
 
+
 /**
  * 
  * CollectionDescriptor is used by the mapper to read general information on a collection
field
@@ -43,7 +44,8 @@
      private boolean jcrProtected;
      private boolean jcrSameNameSiblings;     
      private boolean jcrMultiple;
-     
+     private String defaultPrimaryType;
+
      private ClassDescriptor classDescriptor;
     
     /**
@@ -330,4 +332,12 @@
 		
 		return "Collection Descriptor : " +  this.getFieldName();
 	}    
+
+    public String getDefaultPrimaryType() {
+        return defaultPrimaryType;
+    }
+
+    public void setDefaultPrimaryType(String defaultPrimaryType) {
+        this.defaultPrimaryType = defaultPrimaryType;
+    }
 }



Mime
View raw message