jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r773024 - in /jackrabbit/trunk: jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/ jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/ jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commo...
Date Fri, 08 May 2009 15:03:46 GMT
Author: angela
Date: Fri May  8 15:03:45 2009
New Revision: 773024

URL: http://svn.apache.org/viewvc?rev=773024&view=rev
Log:
JCR-2105: JSR 283 NodeType Management (work in progress)
JCR-1591: JSR 283: NodeType Management
JCR-1483: Move common node type functionality to jackrabbit-spi-commons

- move jsr 283 nodetype management impl that can be shared between jackrabbit-core and jackrabbit-jcr2spi
to jackrabbit-spi-commons
- resolve FIXME comment in jackrabbit-core NodeTypeManagerImpl

Added:
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java
  (contents, props changed)
      - copied, changed from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/AbstractItemDefinitionTemplate.java
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractNodeTypeManager.java
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java
  (contents, props changed)
      - copied, changed from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeDefinitionTemplateImpl.java
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java
  (contents, props changed)
      - copied, changed from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeTemplateImpl.java
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java
  (contents, props changed)
      - copied, changed from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/PropertyDefinitionTemplateImpl.java
Removed:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/AbstractItemDefinitionTemplate.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeDefinitionTemplateImpl.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeTemplateImpl.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/PropertyDefinitionTemplateImpl.java
Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
    jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/NodeTypeManagerImpl.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java?rev=773024&r1=773023&r2=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeManagerImpl.java
Fri May  8 15:03:45 2009
@@ -26,15 +26,15 @@
 import org.apache.jackrabbit.core.data.DataStore;
 import org.apache.jackrabbit.core.nodetype.compact.CompactNodeTypeDefReader;
 import org.apache.jackrabbit.core.nodetype.compact.ParseException;
-import javax.jcr.nodetype.NodeDefinitionTemplate;
+
 import javax.jcr.nodetype.NodeTypeDefinition;
 import javax.jcr.nodetype.NodeTypeExistsException;
-import javax.jcr.nodetype.NodeTypeTemplate;
-import javax.jcr.nodetype.PropertyDefinitionTemplate;
+
 import org.apache.jackrabbit.core.nodetype.xml.NodeTypeReader;
 import org.apache.jackrabbit.core.util.Dumpable;
 import org.apache.jackrabbit.core.value.InternalValue;
 import org.apache.jackrabbit.spi.commons.namespace.NamespaceMapping;
+import org.apache.jackrabbit.spi.commons.nodetype.AbstractNodeTypeManager;
 import org.apache.jackrabbit.spi.Name;
 import org.xml.sax.InputSource;
 import org.xml.sax.SAXException;
@@ -70,7 +70,7 @@
  * A <code>NodeTypeManagerImpl</code> implements a session dependant
  * NodeTypeManager.
  */
-public class NodeTypeManagerImpl implements JackrabbitNodeTypeManager,
+public class NodeTypeManagerImpl extends AbstractNodeTypeManager implements JackrabbitNodeTypeManager,
         Dumpable, NodeTypeRegistryListener {
 
     /**
@@ -509,82 +509,6 @@
 
     //--------------------------------------------------< new JSR 283 methods >
     /**
-     * Returns an empty <code>NodeTypeTemplate</code> which can then be used
to
-     * define a node type and passed to
-     * <code>NodeTypeManager.registerNodeType</code>.
-     * <p/>
-     * Throws an <code>UnsupportedRepositoryOperationException</code> if this
-     * implementation does not support node type registration.
-     * @return A <code>NodeTypeTemplate</code>.
-     * @throws UnsupportedRepositoryOperationException if this implementation
-     *  does not support node type registration.
-     * @throws RepositoryException if another error occurs.
-     * @since JCR 2.0
-     */
-    public NodeTypeTemplate createNodeTypeTemplate()
-            throws UnsupportedRepositoryOperationException, RepositoryException {
-        return new NodeTypeTemplateImpl();
-    }
-
-    /**
-     * Returns a <code>NodeTypeTemplate</code> holding the specified node type
-     * definition. This template can then be altered and passed to
-     * <code>NodeTypeManager.registerNodeType</code>.
-     * <p/>
-     * Throws an <code>UnsupportedRepositoryOperationException</code> if this
-     * implementation does not support node type registration.
-     *
-     * @param ntd a <code>NodeTypeDefinition</code>.
-     * @return A <code>NodeTypeTemplate</code>.
-     * @throws UnsupportedRepositoryOperationException if this implementation
-     *  does not support node type registration.
-     * @throws RepositoryException if another error occurs.
-     * @since JCR 2.0
-     */
-    public NodeTypeTemplate createNodeTypeTemplate(NodeTypeDefinition ntd)
-            throws UnsupportedRepositoryOperationException, RepositoryException {
-        return new NodeTypeTemplateImpl(ntd);
-    }
-
-    /**
-     * Returns an empty <code>NodeDefinitionTemplate</code> which can then be
-     * used to create a child node definition and attached to a
-     * <code>NodeTypeTemplate</code>.
-     * <p/>
-     * Throws an <code>UnsupportedRepositoryOperationException</code> if this
-     * implementation does not support node type registration.
-     *
-     * @return A <code>NodeDefinitionTemplate</code>.
-     * @throws UnsupportedRepositoryOperationException if this implementation
-     *  does not support node type registration.
-     * @throws RepositoryException if another error occurs.
-     * @since JCR 2.0
-     */
-    public NodeDefinitionTemplate createNodeDefinitionTemplate()
-            throws UnsupportedRepositoryOperationException, RepositoryException {
-        return new NodeDefinitionTemplateImpl(this);
-    }
-
-    /**
-     * Returns an empty <code>PropertyDefinitionTemplate</code> which can then
-     * be used to create a property definition and attached to a
-     * <code>NodeTypeTemplate</code>.
-     * <p/>
-     * Throws an <code>UnsupportedRepositoryOperationException</code> if this
-     * implementation does not support node type registration.
-     *
-     * @return A <code>PropertyDefinitionTemplate</code>.
-     * @throws UnsupportedRepositoryOperationException if this implementation
-     *  does not support node type registration.
-     * @throws RepositoryException if another error occurs.
-     * @since JCR 2.0
-     */
-    public PropertyDefinitionTemplate createPropertyDefinitionTemplate()
-            throws UnsupportedRepositoryOperationException, RepositoryException {
-        return new PropertyDefinitionTemplateImpl();
-    }
-
-    /**
      * Registers a new node type or updates an existing node type using the
      * specified definition and returns the resulting <code>NodeType</code>
      * object.
@@ -836,9 +760,7 @@
                     }
                 }
                 // default primary type
-                //name = ndefs[i].getDefaultPrimaryTypeName();
-                // FIXME when JCR 2.0 API has been finalized
-                name = ((NodeDefinitionTemplateImpl) ndefs[i]).getDefaultPrimaryTypeName();
+                name = ndefs[i].getDefaultPrimaryTypeName();
                 if (name != null) {
                     try {
                         qndef.setDefaultPrimaryType(session.getQName(name));
@@ -849,9 +771,7 @@
                     }
                 }
                 // required primary types
-                //names = ndefs[i].getRequiredPrimaryTypeNames();
-                // FIXME when JCR 2.0 API has been finalized
-                names = ((NodeDefinitionTemplateImpl) ndefs[i]).getRequiredPrimaryTypeNames();
+                names = ndefs[i].getRequiredPrimaryTypeNames();
                 qnames = new Name[names.length];
                 for (int j = 0; j < names.length; j++) {
                     try {

Modified: jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/NodeTypeManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/NodeTypeManagerImpl.java?rev=773024&r1=773023&r2=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/NodeTypeManagerImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/nodetype/NodeTypeManagerImpl.java
Fri May  8 15:03:45 2009
@@ -21,6 +21,7 @@
 import org.apache.jackrabbit.commons.iterator.NodeTypeIteratorAdapter;
 import org.apache.jackrabbit.spi.commons.conversion.NameException;
 import org.apache.jackrabbit.spi.commons.conversion.NamePathResolver;
+import org.apache.jackrabbit.spi.commons.nodetype.AbstractNodeTypeManager;
 import org.apache.jackrabbit.spi.Name;
 import org.apache.jackrabbit.jcr2spi.util.Dumpable;
 import org.apache.jackrabbit.jcr2spi.ManagerProvider;
@@ -38,15 +39,12 @@
 import javax.jcr.NamespaceException;
 import javax.jcr.version.OnParentVersionAction;
 import javax.jcr.nodetype.NoSuchNodeTypeException;
-import javax.jcr.nodetype.NodeDefinitionTemplate;
 import javax.jcr.nodetype.NodeType;
 import javax.jcr.nodetype.NodeTypeDefinition;
 import javax.jcr.nodetype.NodeTypeIterator;
 import javax.jcr.nodetype.NodeTypeManager;
-import javax.jcr.nodetype.NodeTypeTemplate;
 import javax.jcr.nodetype.PropertyDefinition;
 import javax.jcr.nodetype.NodeDefinition;
-import javax.jcr.nodetype.PropertyDefinitionTemplate;
 
 import java.util.ArrayList;
 import java.util.Iterator;
@@ -57,7 +55,7 @@
  * A <code>NodeTypeManagerImpl</code> implements a session dependant
  * NodeTypeManager.
  */
-public class NodeTypeManagerImpl implements NodeTypeManager, NodeTypeRegistryListener, Dumpable
{
+public class NodeTypeManagerImpl extends AbstractNodeTypeManager implements NodeTypeRegistryListener,
Dumpable {
 
     /**
      * Logger instance for this class
@@ -358,38 +356,6 @@
             return false;
         }
     }
-    
-    /**
-     * @see javax.jcr.nodetype.NodeTypeManager#createNodeTypeTemplate()
-     */
-    public NodeTypeTemplate createNodeTypeTemplate()
-            throws RepositoryException {
-        throw new UnsupportedRepositoryOperationException("JCR-1591");
-    }
-
-    /**
-     * @see NodeTypeManager#createNodeTypeTemplate(javax.jcr.nodetype.NodeTypeDefinition)
-     */
-    public NodeTypeTemplate createNodeTypeTemplate(NodeTypeDefinition ntd)
-            throws RepositoryException {
-        throw new UnsupportedRepositoryOperationException("JCR-1591");
-    }
-
-    /**
-     * @see javax.jcr.nodetype.NodeTypeManager#createNodeDefinitionTemplate()
-     */
-    public NodeDefinitionTemplate createNodeDefinitionTemplate()
-            throws RepositoryException {
-        throw new UnsupportedRepositoryOperationException("JCR-1591");
-    }
-
-    /**
-     * @see javax.jcr.nodetype.NodeTypeManager#createPropertyDefinitionTemplate()
-     */
-    public PropertyDefinitionTemplate createPropertyDefinitionTemplate()
-            throws RepositoryException {
-        throw new UnsupportedRepositoryOperationException("JCR-1591");
-    }
 
     /**
      * @see NodeTypeManager#registerNodeType(javax.jcr.nodetype.NodeTypeDefinition, boolean)

Copied: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java
(from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/AbstractItemDefinitionTemplate.java)
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java?p2=jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java&p1=jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/AbstractItemDefinitionTemplate.java&r1=772858&r2=773024&rev=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/AbstractItemDefinitionTemplate.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java
Fri May  8 15:03:45 2009
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.jackrabbit.core.nodetype;
+package org.apache.jackrabbit.spi.commons.nodetype;
 
 import javax.jcr.nodetype.ItemDefinition;
 import javax.jcr.nodetype.NodeType;

Propchange: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractItemDefinitionTemplate.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractNodeTypeManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractNodeTypeManager.java?rev=773024&view=auto
==============================================================================
--- jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractNodeTypeManager.java
(added)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/AbstractNodeTypeManager.java
Fri May  8 15:03:45 2009
@@ -0,0 +1,74 @@
+/*
+ * 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.spi.commons.nodetype;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.jcr.nodetype.NodeTypeManager;
+import javax.jcr.nodetype.NodeTypeTemplate;
+import javax.jcr.nodetype.NodeTypeDefinition;
+import javax.jcr.nodetype.NodeDefinitionTemplate;
+import javax.jcr.nodetype.PropertyDefinitionTemplate;
+import javax.jcr.nodetype.NodeType;
+import javax.jcr.UnsupportedRepositoryOperationException;
+import javax.jcr.RepositoryException;
+
+/**
+ * <code>AbstractNodeTypeManager</code> covers creation of node type templates
+ * and definition templates.
+ */
+public abstract class AbstractNodeTypeManager implements NodeTypeManager {
+
+    /**
+     * logger instance
+     */
+    private static final Logger log = LoggerFactory.getLogger(AbstractNodeTypeManager.class);
+
+    //----------------------------------------------------< NodeTypeManager >---
+    /**
+     * @see javax.jcr.nodetype.NodeTypeManager#createNodeTypeTemplate()
+     */
+    public NodeTypeTemplate createNodeTypeTemplate()
+            throws UnsupportedRepositoryOperationException, RepositoryException {
+        return new NodeTypeTemplateImpl();
+    }
+
+    /**
+     * @see javax.jcr.nodetype.NodeTypeManager#createNodeTypeTemplate(NodeTypeDefinition)
+     */
+    public NodeTypeTemplate createNodeTypeTemplate(NodeTypeDefinition ntd)
+            throws UnsupportedRepositoryOperationException, RepositoryException {
+        return new NodeTypeTemplateImpl(ntd);
+    }
+
+    /**
+     * @see javax.jcr.nodetype.NodeTypeManager#createNodeDefinitionTemplate()
+     */
+    public NodeDefinitionTemplate createNodeDefinitionTemplate()
+            throws UnsupportedRepositoryOperationException, RepositoryException {
+        return new NodeDefinitionTemplateImpl(getNodeType(NodeType.NT_BASE));
+    }
+
+    /**
+     * @see javax.jcr.nodetype.NodeTypeManager#createPropertyDefinitionTemplate()
+     */
+    public PropertyDefinitionTemplate createPropertyDefinitionTemplate()
+            throws UnsupportedRepositoryOperationException, RepositoryException {
+        return new PropertyDefinitionTemplateImpl();
+    }
+}
\ No newline at end of file

Copied: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java
(from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeDefinitionTemplateImpl.java)
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java?p2=jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java&p1=jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeDefinitionTemplateImpl.java&r1=772858&r2=773024&rev=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeDefinitionTemplateImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java
Fri May  8 15:03:45 2009
@@ -14,10 +14,9 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.jackrabbit.core.nodetype;
+package org.apache.jackrabbit.spi.commons.nodetype;
 
 import javax.jcr.nodetype.NodeDefinitionTemplate;
-import org.apache.jackrabbit.spi.commons.name.NameConstants;
 
 import javax.jcr.RepositoryException;
 import javax.jcr.nodetype.NodeDefinition;
@@ -38,11 +37,11 @@
     /**
      * Package private constructor
      *
-     * @param ntMgr
+     * @param ntBase
      * @throws RepositoryException
      */
-    NodeDefinitionTemplateImpl(NodeTypeManagerImpl ntMgr) throws RepositoryException {
-        requiredPrimaryTypes = new NodeType[] {ntMgr.getNodeType(NameConstants.NT_BASE)};
+    NodeDefinitionTemplateImpl(NodeType ntBase) throws RepositoryException {
+        requiredPrimaryTypes = new NodeType[] {ntBase};
         requiredPrimaryTypeNames = new String[] {requiredPrimaryTypes[0].getName()};
     }
 

Propchange: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeDefinitionTemplateImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java
(from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeTemplateImpl.java)
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java?p2=jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java&p1=jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeTemplateImpl.java&r1=772858&r2=773024&rev=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/NodeTypeTemplateImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java
Fri May  8 15:03:45 2009
@@ -14,9 +14,10 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.jackrabbit.core.nodetype;
+package org.apache.jackrabbit.spi.commons.nodetype;
 
 import org.apache.commons.collections.list.TypedList;
+
 import javax.jcr.nodetype.NodeTypeTemplate;
 import javax.jcr.nodetype.NodeTypeDefinition;
 import javax.jcr.nodetype.NodeDefinitionTemplate;
@@ -140,8 +141,12 @@
         return nodeDefinitionTemplates;
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public void setQueryable(boolean queryable) {
-        // ignored, TODO JCR-2091
+        // TODO
+        throw new RuntimeException("Not implemented yet, see JCR-1591");
     }
 
     //---------------------------------------------------< NodeTypeDefinition >

Propchange: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/NodeTypeTemplateImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java
(from r772858, jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/PropertyDefinitionTemplateImpl.java)
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java?p2=jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java&p1=jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/PropertyDefinitionTemplateImpl.java&r1=772858&r2=773024&rev=773024&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/PropertyDefinitionTemplateImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java
Fri May  8 15:03:45 2009
@@ -14,15 +14,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.jackrabbit.core.nodetype;
+package org.apache.jackrabbit.spi.commons.nodetype;
 
 import javax.jcr.PropertyType;
 import javax.jcr.Value;
 import javax.jcr.nodetype.PropertyDefinition;
 import javax.jcr.nodetype.PropertyDefinitionTemplate;
 
-import org.apache.jackrabbit.spi.commons.query.qom.Operator;
-
 /**
  * A <code>PropertyDefinitionTemplateImpl</code> ...
  */
@@ -84,16 +82,28 @@
         this.multiple = multiple;
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public void setAvailablrQueryOperators(String[] operators) {
-        // ignored, TODO JCR-2091
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public void setFullTextSearchable(boolean searchable) {
-        // ignored, TODO JCR-2091
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public void setQueryOrderable(boolean orderable) {
-        // ignored, TODO JCR-2091
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 
     //---------------------------------------------------< PropertyDefinition >
@@ -125,16 +135,27 @@
         return multiple;
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public String[] getAvailableQueryOperators() {
-        // TODO: JCR-2091
-        return Operator.getAllQueryOperators();
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public boolean isFullTextSearchable() {
-        return true; // TODO: JCR-2091
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 
+    /**
+     * {@inheritDoc}
+     */
     public boolean isQueryOrderable() {
-        return true; // TODO: JCR-2091
+        // TODO
+        throw new UnsupportedOperationException("Not implemented yet, see JCR-1591");
     }
 }

Propchange: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/nodetype/PropertyDefinitionTemplateImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message