You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@chemistry.apache.org by fg...@apache.org on 2009/08/02 23:00:53 UTC
svn commit: r800147 - in /incubator/chemistry/trunk/chemistry:
chemistry-api/src/main/java/org/apache/chemistry/
chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/
chemistry-atompub-client/src/test/resources/ chemistry-atompub-...
Author: fguillaume
Date: Sun Aug 2 21:00:52 2009
New Revision: 800147
URL: http://svn.apache.org/viewvc?rev=800147&view=rev
Log:
CMIS-44: added Type#isControllablePolicy, Type#isControllableACL, Type#isFulltextIndexed
Modified:
incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/SPI.java
incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/Type.java
incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPType.java
incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/TypeEntryReader.java
incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/test/resources/feed-types.xml
incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/main/java/org/apache/chemistry/atompub/server/CMISTypesCollection.java
incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/test/java/org/apache/chemistry/atompub/server/AtomPubServerTestCase.java
incubator/chemistry/trunk/chemistry/chemistry-atompub/src/main/java/org/apache/chemistry/atompub/CMIS.java
incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/base/BaseRepository.java
incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/simple/SimpleType.java
incubator/chemistry/trunk/chemistry/chemistry-commons/src/test/java/org/apache/chemistry/impl/simple/TestSimpleRepository.java
incubator/chemistry/trunk/chemistry/chemistry-jcr/src/main/java/org/apache/chemistry/jcr/JcrType.java
incubator/chemistry/trunk/chemistry/chemistry-tests/src/main/java/org/apache/chemistry/test/BasicHelper.java
Modified: incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/SPI.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/SPI.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/SPI.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/SPI.java Sun Aug 2 21:00:52 2009
@@ -485,7 +485,7 @@
* repositories that do not support version-specific filing, if a document
* is to be deleted, all versions are deleted.
* <p>
- * This method is not transactional. However, if
+ * This method is not atomic. However, if
* {@link Unfiling#DELETE_SINGLE_FILED DELETE_SINGLE_FILED} and some objects
* fail to delete, then single-filed objects are either deleted or kept,
* never just unfiled. This is so that user can call this method again to
Modified: incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/Type.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/Type.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/Type.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-api/src/main/java/org/apache/chemistry/Type.java Sun Aug 2 21:00:52 2009
@@ -127,16 +127,36 @@
boolean isQueryable();
/**
- * Is the type controllable.
+ * Are objects of this type controllable via policies.
* <p>
- * This indicates whether or not objects of this type are controllable.
- * Policy objects can only be applied to controllable objects.
+ * This indicates whether or not objects of this type are controllable via
+ * policies. Policy objects can only be applied to controllableACL objects.
* <p>
* All types may be controllable.
*
- * @return {@code true} if the type is controllable.
+ * @return {@code true} if the type is controllable via policies
*/
- boolean isControllable();
+ boolean isControllablePolicy();
+
+ /**
+ * Are objects of this type controllable via ACLs.
+ *
+ * This indicates whether or not objects of this type are controllable by
+ * ACLs. Only objects that are controllableACL can have an ACL.
+ *
+ * @return {@code true} if the type is controllable via ACLs
+ */
+ boolean isControllableACL();
+
+ /**
+ * Is the type fulltext-indexed.
+ * <p>
+ * This indicates whether objects of this type are fulltext indexed for
+ * querying via the {@code CONTAINS()} query predicate.
+ *
+ * @return {@code true} if the type is fulltext-indexed
+ */
+ boolean isFulltextIndexed();
/**
* Is the type included in a query of a super-type.
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPType.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPType.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPType.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/APPType.java Sun Aug 2 21:00:52 2009
@@ -128,8 +128,16 @@
return map.get(CMIS.QUERY_NAME.getLocalPart());
}
- public boolean isControllable() {
- return "true".equals(map.get(CMIS.CONTROLLABLE.getLocalPart()));
+ public boolean isControllablePolicy() {
+ return "true".equals(map.get(CMIS.CONTROLLABLE_POLICY.getLocalPart()));
+ }
+
+ public boolean isControllableACL() {
+ return "true".equals(map.get(CMIS.CONTROLLABLE_ACL.getLocalPart()));
+ }
+
+ public boolean isFulltextIndexed() {
+ return "true".equals(map.get(CMIS.FULLTEXT_INDEXED.getLocalPart()));
}
public boolean isCreatable() {
@@ -177,4 +185,5 @@
public String toString() {
return this.getClass().getSimpleName() + '(' + getId() + ')';
}
+
}
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/TypeEntryReader.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/TypeEntryReader.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/TypeEntryReader.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/main/java/org/apache/chemistry/atompub/client/TypeEntryReader.java Sun Aug 2 21:00:52 2009
@@ -120,7 +120,9 @@
CMIS.CREATABLE, //
CMIS.FILEABLE, //
CMIS.QUERYABLE, //
- CMIS.CONTROLLABLE, //
+ CMIS.CONTROLLABLE_POLICY, //
+ CMIS.CONTROLLABLE_ACL, //
+ CMIS.FULLTEXT_INDEXED, //
CMIS.INCLUDED_IN_SUPERTYPE_QUERY //
)) {
if (!map.containsKey(qname.getLocalPart())) {
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/test/resources/feed-types.xml
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/test/resources/feed-types.xml?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/test/resources/feed-types.xml (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-client/src/test/resources/feed-types.xml Sun Aug 2 21:00:52 2009
@@ -25,8 +25,10 @@
<cmis:creatable>true</cmis:creatable>
<cmis:fileable>true</cmis:fileable>
<cmis:queryable>true</cmis:queryable>
- <cmis:controllable>true</cmis:controllable>
<cmis:versionable>true</cmis:versionable>
+ <cmis:controllablePolicy>true</cmis:controllablePolicy>
+ <cmis:controllableACL>true</cmis:controllableACL>
+ <cmis:fulltextindexed>true</cmis:fulltextindexed>
<cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery>
</cmis:documentType>
</entry>
@@ -49,8 +51,10 @@
<cmis:creatable>true</cmis:creatable>
<cmis:fileable>true</cmis:fileable>
<cmis:queryable>true</cmis:queryable>
- <cmis:controllable>false</cmis:controllable>
<cmis:versionable>false</cmis:versionable>
+ <cmis:controllablePolicy>true</cmis:controllablePolicy>
+ <cmis:controllableACL>true</cmis:controllableACL>
+ <cmis:fulltextindexed>true</cmis:fulltextindexed>
<cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery>
</cmis:folderType>
</entry>
@@ -73,8 +77,10 @@
<cmis:creatable>true</cmis:creatable>
<cmis:fileable>false</cmis:fileable>
<cmis:queryable>true</cmis:queryable>
- <cmis:controllable>false</cmis:controllable>
<cmis:versionable>false</cmis:versionable>
+ <cmis:controllablePolicy>false</cmis:controllablePolicy>
+ <cmis:controllableACL>false</cmis:controllableACL>
+ <cmis:fulltextindexed>false</cmis:fulltextindexed>
<cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery>
</cmis:relationshipType>
</entry>
@@ -97,8 +103,10 @@
<cmis:creatable>true</cmis:creatable>
<cmis:fileable>false</cmis:fileable>
<cmis:queryable>true</cmis:queryable>
- <cmis:controllable>false</cmis:controllable>
<cmis:versionable>false</cmis:versionable>
+ <cmis:controllablePolicy>false</cmis:controllablePolicy>
+ <cmis:controllableACL>false</cmis:controllableACL>
+ <cmis:fulltextindexed>false</cmis:fulltextindexed>
<cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery>
</cmis:policyType>
</entry>
@@ -121,8 +129,10 @@
<cmis:creatable>false</cmis:creatable>
<cmis:fileable>false</cmis:fileable>
<cmis:queryable>false</cmis:queryable>
- <cmis:controllable>false</cmis:controllable>
<cmis:versionable>false</cmis:versionable>
+ <cmis:controllablePolicy>false</cmis:controllablePolicy>
+ <cmis:controllableACL>false</cmis:controllableACL>
+ <cmis:fulltextindexed>false</cmis:fulltextindexed>
<cmis:includedInSupertypeQuery>false</cmis:includedInSupertypeQuery>
</cmis:folderType>
</entry>
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/main/java/org/apache/chemistry/atompub/server/CMISTypesCollection.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/main/java/org/apache/chemistry/atompub/server/CMISTypesCollection.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/main/java/org/apache/chemistry/atompub/server/CMISTypesCollection.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/main/java/org/apache/chemistry/atompub/server/CMISTypesCollection.java Sun Aug 2 21:00:52 2009
@@ -153,8 +153,12 @@
el.setText(bool(type.isFileable()));
el = factory.newElement(CMIS.QUERYABLE, dt);
el.setText(bool(type.isQueryable()));
- el = factory.newElement(CMIS.CONTROLLABLE, dt);
- el.setText(bool(type.isControllable()));
+ el = factory.newElement(CMIS.CONTROLLABLE_POLICY, dt);
+ el.setText(bool(type.isControllablePolicy()));
+ el = factory.newElement(CMIS.CONTROLLABLE_ACL, dt);
+ el.setText(bool(type.isControllableACL()));
+ el = factory.newElement(CMIS.FULLTEXT_INDEXED, dt);
+ el.setText(bool(type.isFulltextIndexed()));
el = factory.newElement(CMIS.INCLUDED_IN_SUPERTYPE_QUERY, dt);
el.setText(bool(type.isIncludedInSuperTypeQuery()));
el = factory.newElement(CMIS.VERSIONABLE, dt); // docs only
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/test/java/org/apache/chemistry/atompub/server/AtomPubServerTestCase.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/test/java/org/apache/chemistry/atompub/server/AtomPubServerTestCase.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/test/java/org/apache/chemistry/atompub/server/AtomPubServerTestCase.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub-server/src/test/java/org/apache/chemistry/atompub/server/AtomPubServerTestCase.java Sun Aug 2 21:00:52 2009
@@ -106,11 +106,12 @@
Updatability.READ_WRITE, true, true, 0, null, null, -1, null);
SimpleType dt = new SimpleType("doc", BaseType.DOCUMENT.getId(), "doc",
null, "Doc", "My Doc Type", BaseType.DOCUMENT, "", true, true,
- true, true, true, true, ContentStreamPresence.ALLOWED, null,
- null, Arrays.asList(p1, p2, p3));
+ true, true, true, true, true, true,
+ ContentStreamPresence.ALLOWED, null, null, Arrays.asList(p1,
+ p2, p3));
SimpleType ft = new SimpleType("fold", BaseType.FOLDER.getId(), "doc",
null, "Fold", "My Folder Type", BaseType.FOLDER, "", true,
- true, true, true, false, false,
+ true, true, true, true, true, false, false,
ContentStreamPresence.NOT_ALLOWED, null, null, Arrays.asList(
p1, p2));
SimpleRepository repo = new SimpleRepository("test", Arrays.asList(dt,
Modified: incubator/chemistry/trunk/chemistry/chemistry-atompub/src/main/java/org/apache/chemistry/atompub/CMIS.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-atompub/src/main/java/org/apache/chemistry/atompub/CMIS.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-atompub/src/main/java/org/apache/chemistry/atompub/CMIS.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-atompub/src/main/java/org/apache/chemistry/atompub/CMIS.java Sun Aug 2 21:00:52 2009
@@ -129,7 +129,11 @@
public static final QName QUERYABLE = CMISName("queryable");
- public static final QName CONTROLLABLE = CMISName("controllable");
+ public static final QName CONTROLLABLE_POLICY = CMISName("controllablePolicy");
+
+ public static final QName CONTROLLABLE_ACL = CMISName("controllableACL");
+
+ public static final QName FULLTEXT_INDEXED = CMISName("fulltextindexed");
public static final QName VERSIONABLE = CMISName("versionable");
Modified: incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/base/BaseRepository.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/base/BaseRepository.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/base/BaseRepository.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/base/BaseRepository.java Sun Aug 2 21:00:52 2009
@@ -48,32 +48,36 @@
public static final SimpleType ROOT_TYPE = new SimpleType(ROOT_TYPE_ID,
BaseType.FOLDER.getId(), ROOT_TYPE_ID, null, ROOT_TYPE_ID,
"Root Folder Type", BaseType.FOLDER, "", false, false, false,
- false, false, false, ContentStreamPresence.NOT_ALLOWED, null, null,
+ false, false, false, false, false,
+ ContentStreamPresence.NOT_ALLOWED, null, null,
Collections.<PropertyDefinition> emptyList());
public static final SimpleType DOCUMENT_TYPE = new SimpleType(
BaseType.DOCUMENT.getId(), null, BaseType.DOCUMENT.getId(), null,
BaseType.DOCUMENT.getId(), "Document Type", BaseType.DOCUMENT, "",
- true, true, true, true, true, true, ContentStreamPresence.ALLOWED,
- null, null, Collections.<PropertyDefinition> emptyList());
+ true, true, true, true, true, true, true, true,
+ ContentStreamPresence.ALLOWED, null, null,
+ Collections.<PropertyDefinition> emptyList());
public static final SimpleType FOLDER_TYPE = new SimpleType(
BaseType.FOLDER.getId(), null, BaseType.FOLDER.getId(), null,
BaseType.FOLDER.getId(), "Folder Type", BaseType.FOLDER, "", true,
- true, false, true, true, false, ContentStreamPresence.NOT_ALLOWED,
- null, null, Collections.<PropertyDefinition> emptyList());
+ true, false, true, true, true, true, false,
+ ContentStreamPresence.NOT_ALLOWED, null, null,
+ Collections.<PropertyDefinition> emptyList());
public static final SimpleType RELATIONSHIP_TYPE = new SimpleType(
BaseType.RELATIONSHIP.getId(), null, BaseType.RELATIONSHIP.getId(),
null, BaseType.RELATIONSHIP.getId(), "Relationship Type",
- BaseType.RELATIONSHIP, "", true, true, false, true, false, false,
- ContentStreamPresence.NOT_ALLOWED, null, null,
+ BaseType.RELATIONSHIP, "", true, true, false, false, false, true,
+ false, false, ContentStreamPresence.NOT_ALLOWED, null, null,
Collections.<PropertyDefinition> emptyList());
protected static final SimpleType POLICY_TYPE = new SimpleType(
BaseType.POLICY.getId(), null, BaseType.POLICY.getId(), null,
"Policy", "Policy Type", BaseType.POLICY, "", true, true, false,
- true, false, false, ContentStreamPresence.NOT_ALLOWED, null, null,
+ false, false, true, false, false,
+ ContentStreamPresence.NOT_ALLOWED, null, null,
Collections.<PropertyDefinition> emptyList());
protected final String name;
Modified: incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/simple/SimpleType.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/simple/SimpleType.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/simple/SimpleType.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-commons/src/main/java/org/apache/chemistry/impl/simple/SimpleType.java Sun Aug 2 21:00:52 2009
@@ -273,7 +273,11 @@
protected final boolean queryable;
- protected final boolean controllable;
+ protected final boolean controllablePolicy;
+
+ protected final boolean controllableACL;
+
+ protected final boolean fulltextIndexed;
protected final boolean includedInSuperTypeQuery;
@@ -292,13 +296,15 @@
public SimpleType(String id, String parentId, String localName,
URI localNamespace, String queryName, String displayName,
BaseType baseType, String description, boolean creatable,
- boolean queryable, boolean controllable,
+ boolean queryable, boolean controllablePolicy,
+ boolean controllableACL, boolean fulltextIndexed,
boolean includedInSuperTypeQuery, boolean fileable,
boolean versionable, ContentStreamPresence contentStreamAllowed,
String[] allowedSourceTypes, String[] allowedTargetTypes,
Collection<PropertyDefinition> propertyDefinitions) {
this(id, parentId, localName, localNamespace, queryName, displayName,
- baseType, description, creatable, queryable, controllable,
+ baseType, description, creatable, queryable,
+ controllablePolicy, controllableACL, fulltextIndexed,
includedInSuperTypeQuery, fileable, versionable,
contentStreamAllowed, allowedSourceTypes, allowedTargetTypes);
addPropertyDefinitions(getBasePropertyDefinitions(baseType));
@@ -308,7 +314,8 @@
public SimpleType(String id, String parentId, String localName,
URI localNamespace, String queryName, String displayName,
BaseType baseType, String description, boolean creatable,
- boolean queryable, boolean controllable,
+ boolean queryable, boolean controllablePolicy,
+ boolean controllableACL, boolean fulltextIndexed,
boolean includedInSuperTypeQuery, boolean fileable,
boolean versionable, ContentStreamPresence contentStreamAllowed,
String[] allowedSourceTypes, String[] allowedTargetTypes) {
@@ -322,7 +329,9 @@
this.description = description;
this.creatable = creatable;
this.queryable = queryable;
- this.controllable = controllable;
+ this.controllablePolicy = controllablePolicy;
+ this.controllableACL = controllableACL;
+ this.fulltextIndexed = fulltextIndexed;
this.includedInSuperTypeQuery = includedInSuperTypeQuery;
this.fileable = fileable;
this.versionable = versionable;
@@ -399,8 +408,16 @@
return queryable;
}
- public boolean isControllable() {
- return controllable;
+ public boolean isControllablePolicy() {
+ return controllablePolicy;
+ }
+
+ public boolean isControllableACL() {
+ return controllableACL;
+ }
+
+ public boolean isFulltextIndexed() {
+ return fulltextIndexed;
}
public boolean isIncludedInSuperTypeQuery() {
Modified: incubator/chemistry/trunk/chemistry/chemistry-commons/src/test/java/org/apache/chemistry/impl/simple/TestSimpleRepository.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-commons/src/test/java/org/apache/chemistry/impl/simple/TestSimpleRepository.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-commons/src/test/java/org/apache/chemistry/impl/simple/TestSimpleRepository.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-commons/src/test/java/org/apache/chemistry/impl/simple/TestSimpleRepository.java Sun Aug 2 21:00:52 2009
@@ -61,17 +61,19 @@
Updatability.READ_WRITE, true, true, 0, null, null, -1, null);
SimpleType mt1 = new SimpleType("doc", BaseType.DOCUMENT.getId(),
"doc", null, "Doc", "My Doc Type", BaseType.DOCUMENT, "", true,
- true, true, true, true, true, ContentStreamPresence.ALLOWED,
- null, null, Arrays.asList(d1, d2, d3));
+ true, true, true, true, true, true, true,
+ ContentStreamPresence.ALLOWED, null, null, Arrays.asList(d1,
+ d2, d3));
SimpleType mt2 = new SimpleType("fold", BaseType.FOLDER.getId(),
"fold", null, "Fold", "My Folder Type", BaseType.FOLDER, "",
- true, true, true, true, false, false,
+ true, true, true, true, true, true, false, false,
ContentStreamPresence.NOT_ALLOWED, null, null, Arrays.asList(
d1, d2));
SimpleType mt3 = new SimpleType("subdoc", "doc", "subdoc", null,
"SubDoc", "My SubDoc Type", BaseType.DOCUMENT, "", true, true,
- true, true, true, true, ContentStreamPresence.ALLOWED, null,
- null, Arrays.asList(d1, d2, d3));
+ true, true, true, true, true, true,
+ ContentStreamPresence.ALLOWED, null, null, Arrays.asList(d1,
+ d2, d3));
repo = new SimpleRepository("test", Arrays.asList(mt1, mt2, mt3), null);
}
Modified: incubator/chemistry/trunk/chemistry/chemistry-jcr/src/main/java/org/apache/chemistry/jcr/JcrType.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-jcr/src/main/java/org/apache/chemistry/jcr/JcrType.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-jcr/src/main/java/org/apache/chemistry/jcr/JcrType.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-jcr/src/main/java/org/apache/chemistry/jcr/JcrType.java Sun Aug 2 21:00:52 2009
@@ -30,6 +30,7 @@
public class JcrType implements Type {
private final NodeType nodeType;
+
private final BaseType baseType;
public JcrType(NodeType nodeType, BaseType baseType) {
@@ -98,10 +99,18 @@
return null;
}
- public boolean isControllable() {
+ public boolean isControllablePolicy() {
+ return false;
+ }
+
+ public boolean isControllableACL() {
return false;
}
+ public boolean isFulltextIndexed() {
+ return false; // TODO
+ }
+
public boolean isCreatable() {
return true;
}
@@ -125,6 +134,4 @@
return false;
}
-
-
}
Modified: incubator/chemistry/trunk/chemistry/chemistry-tests/src/main/java/org/apache/chemistry/test/BasicHelper.java
URL: http://svn.apache.org/viewvc/incubator/chemistry/trunk/chemistry/chemistry-tests/src/main/java/org/apache/chemistry/test/BasicHelper.java?rev=800147&r1=800146&r2=800147&view=diff
==============================================================================
--- incubator/chemistry/trunk/chemistry/chemistry-tests/src/main/java/org/apache/chemistry/test/BasicHelper.java (original)
+++ incubator/chemistry/trunk/chemistry/chemistry-tests/src/main/java/org/apache/chemistry/test/BasicHelper.java Sun Aug 2 21:00:52 2009
@@ -61,11 +61,12 @@
Updatability.READ_WRITE, true, true, 0, null, null, -1, null);
SimpleType dt = new SimpleType("doc", BaseType.DOCUMENT.getId(), "doc",
null, "Doc", "My Doc Type", BaseType.DOCUMENT, "", true, true,
- true, true, true, true, ContentStreamPresence.ALLOWED, null,
- null, Arrays.asList(p1, p2, p3));
+ true, true, true, true, true, true,
+ ContentStreamPresence.ALLOWED, null, null, Arrays.asList(p1,
+ p2, p3));
SimpleType ft = new SimpleType("fold", BaseType.FOLDER.getId(), "fold",
null, "Fold", "My Folder Type", BaseType.FOLDER, "", true,
- true, true, true, false, false,
+ true, true, true, true, true, false, false,
ContentStreamPresence.NOT_ALLOWED, null, null, Arrays.asList(
p1, p2));
SimpleRepository repo = new SimpleRepository("test", Arrays.asList(dt,