]> git.aero2k.de Git - tmp/jakarta-migration.git/commitdiff
CSPACE-3851 Consumer can perform CRUDL operations on a group. Basic Group support...
authorPatrick Schmitz <pschmitz@berkeley.edu>
Thu, 21 Apr 2011 00:09:29 +0000 (00:09 +0000)
committerPatrick Schmitz <pschmitz@berkeley.edu>
Thu, 21 Apr 2011 00:09:29 +0000 (00:09 +0000)
47 files changed:
services/group/.classpath [new file with mode: 0644]
services/group/.project [new file with mode: 0644]
services/group/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/3rdparty/.classpath [new file with mode: 0644]
services/group/3rdparty/.project [new file with mode: 0644]
services/group/3rdparty/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/3rdparty/build.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/.classpath [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/.project [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/build.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/pom.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/META-INF/MANIFEST.MF [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/core-types-contrib.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/deployment-fragment.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/ecm-types-contrib.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/layouts-contrib.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/life-cycle-contrib.xml [new file with mode: 0644]
services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/schemas/groups_common.xsd [new file with mode: 0644]
services/group/3rdparty/pom.xml [new file with mode: 0644]
services/group/build.xml [new file with mode: 0644]
services/group/client/.classpath [new file with mode: 0644]
services/group/client/.project [new file with mode: 0644]
services/group/client/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/client/pom.xml [new file with mode: 0644]
services/group/client/src/main/java/org/collectionspace/services/client/GroupClient.java [new file with mode: 0644]
services/group/client/src/main/java/org/collectionspace/services/client/GroupProxy.java [new file with mode: 0644]
services/group/client/src/test/java/org/collectionspace/services/client/test/GroupServiceTest.java [new file with mode: 0644]
services/group/client/src/test/resources/log4j.properties [new file with mode: 0644]
services/group/jaxb/.classpath [new file with mode: 0644]
services/group/jaxb/.project [new file with mode: 0644]
services/group/jaxb/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/jaxb/pom.xml [new file with mode: 0644]
services/group/jaxb/src/main/java/org/collectionspace/services/GroupJAXBSchema.java [new file with mode: 0644]
services/group/jaxb/src/main/java/org/collectionspace/services/GroupListItemJAXBSchema.java [new file with mode: 0644]
services/group/jaxb/src/main/resources/groups_common.xsd [new file with mode: 0644]
services/group/pom.xml [new file with mode: 0644]
services/group/service/.classpath [new file with mode: 0644]
services/group/service/.project [new file with mode: 0644]
services/group/service/.settings/org.maven.ide.eclipse.prefs [new file with mode: 0644]
services/group/service/pom.xml [new file with mode: 0644]
services/group/service/profiles.xml [new file with mode: 0644]
services/group/service/src/main/java/org/collectionspace/services/group/GroupResource.java [new file with mode: 0644]
services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupDocumentModelHandler.java [new file with mode: 0644]
services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupValidatorHandler.java [new file with mode: 0644]
services/group/service/src/test/java/org/collectionspace/services/test/GroupServiceTest.java [new file with mode: 0644]
services/group/service/src/test/resources/log4j.xml [new file with mode: 0644]

diff --git a/services/group/.classpath b/services/group/.classpath
new file mode 100644 (file)
index 0000000..0469885
--- /dev/null
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/.project b/services/group/.project
new file mode 100644 (file)
index 0000000..4266eac
--- /dev/null
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<projectDescription>\r
+       <name>org.collectionspace.services.group</name>\r
+       <comment></comment>\r
+       <projects>\r
+       </projects>\r
+       <buildSpec>\r
+               <buildCommand>\r
+                       <name>org.eclipse.jdt.core.javabuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+               <buildCommand>\r
+                       <name>org.maven.ide.eclipse.maven2Builder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+       </buildSpec>\r
+       <natures>\r
+               <nature>org.eclipse.jdt.core.javanature</nature>\r
+               <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+       </natures>\r
+</projectDescription>\r
diff --git a/services/group/.settings/org.maven.ide.eclipse.prefs b/services/group/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..1156693
--- /dev/null
@@ -0,0 +1,9 @@
+#Fri Dec 03 15:35:01 PST 2010\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/3rdparty/.classpath b/services/group/3rdparty/.classpath
new file mode 100644 (file)
index 0000000..0469885
--- /dev/null
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/3rdparty/.project b/services/group/3rdparty/.project
new file mode 100644 (file)
index 0000000..738d25d
--- /dev/null
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<projectDescription>\r
+       <name>org.collectionspace.services.group.3rdparty</name>\r
+       <comment></comment>\r
+       <projects>\r
+       </projects>\r
+       <buildSpec>\r
+               <buildCommand>\r
+                       <name>org.eclipse.jdt.core.javabuilder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+               <buildCommand>\r
+                       <name>org.maven.ide.eclipse.maven2Builder</name>\r
+                       <arguments>\r
+                       </arguments>\r
+               </buildCommand>\r
+       </buildSpec>\r
+       <natures>\r
+               <nature>org.eclipse.jdt.core.javanature</nature>\r
+               <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+       </natures>\r
+</projectDescription>\r
diff --git a/services/group/3rdparty/.settings/org.maven.ide.eclipse.prefs b/services/group/3rdparty/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..e2ce08c
--- /dev/null
@@ -0,0 +1,9 @@
+#Fri Aug 27 16:35:21 PDT 2010\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/3rdparty/build.xml b/services/group/3rdparty/build.xml
new file mode 100644 (file)
index 0000000..59882a4
--- /dev/null
@@ -0,0 +1,127 @@
+
+<project name="group.3rdparty" default="package" basedir=".">
+    <description>
+        group service 3rdparty
+    </description>
+  <!-- set global properties for this build -->
+    <property name="services.trunk" value="../../.."/>
+    <!-- environment should be declared before reading build.properties -->
+    <property environment="env" />
+    <property file="${services.trunk}/build.properties" />
+    <property name="mvn.opts" value="" />
+    <property name="src" location="src"/>
+
+    <condition property="osfamily-unix">
+        <os family="unix" />
+    </condition>
+    <condition property="osfamily-windows">
+        <os family="windows" />
+    </condition>
+
+    <target name="init" >
+    <!-- Create the time stamp -->
+        <tstamp/>
+    </target>
+
+    <target name="package" depends="package-unix,package-windows"
+  description="Package CollectionSpace Services" />
+    <target name="package-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="package-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="install" depends="install-unix,install-windows"
+  description="Install" />
+    <target name="install-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="install-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    
+    <target name="clean" depends="clean-unix,clean-windows"
+  description="Delete target directories" >
+        <delete dir="${build}"/>
+    </target>
+    <target name="clean-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="clean-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="test" depends="test-unix,test-windows" description="Run tests" />
+    <target name="test-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="test-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="deploy" depends="install"
+    description="deploy group in ${jboss.server.nuxeo}">
+        <ant antfile="nuxeo-platform-cs-group/build.xml" target="deploy" inheritall="false"/>
+    </target>
+
+    <target name="undeploy"
+    description="undeploy group from ${jboss.server.nuxeo}">
+        <ant antfile="nuxeo-platform-cs-group/build.xml" target="undeploy" inheritall="false"/>
+    </target>
+
+    <target name="dist"
+    description="generate distribution for group" depends="package">
+        <ant antfile="nuxeo-platform-cs-group/build.xml" target="dist" inheritall="false"/>
+    </target>
+
+
+</project>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/.classpath b/services/group/3rdparty/nuxeo-platform-cs-group/.classpath
new file mode 100644 (file)
index 0000000..199bbbb
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="src" output="target/classes" path="src/main/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/.project b/services/group/3rdparty/nuxeo-platform-cs-group/.project
new file mode 100644 (file)
index 0000000..96967c7
--- /dev/null
@@ -0,0 +1,17 @@
+<projectDescription>\r
+  <name>org.collectionspace.services.group.3rdparty.nuxeo</name>\r
+  <comment>Group Nuxeo Document Type. NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>\r
+  <projects/>\r
+  <buildSpec>\r
+    <buildCommand>\r
+      <name>org.eclipse.jdt.core.javabuilder</name>\r
+    </buildCommand>\r
+    <buildCommand>\r
+      <name>org.maven.ide.eclipse.maven2Builder</name>\r
+    </buildCommand>\r
+  </buildSpec>\r
+  <natures>\r
+    <nature>org.eclipse.jdt.core.javanature</nature>\r
+    <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+  </natures>\r
+</projectDescription>\r
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/.settings/org.maven.ide.eclipse.prefs b/services/group/3rdparty/nuxeo-platform-cs-group/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..e2ce08c
--- /dev/null
@@ -0,0 +1,9 @@
+#Fri Aug 27 16:35:21 PDT 2010\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/build.xml b/services/group/3rdparty/nuxeo-platform-cs-group/build.xml
new file mode 100644 (file)
index 0000000..03f1a75
--- /dev/null
@@ -0,0 +1,143 @@
+
+<project name="nuxeo-platform-cs-group" default="package" basedir=".">
+    <description>
+        group nuxeo document type
+    </description>
+    <!-- set global properties for this build -->
+    <property name="services.trunk" value="../../../.."/>
+    <!-- environment should be declared before reading build.properties -->
+    <property environment="env" />
+    <property file="${services.trunk}/build.properties" />
+    <property name="mvn.opts" value="" />
+    <property name="src" location="src"/>
+    <property name="nuxeo.group.jar"
+        value="org.collectionspace.services.group.3rdparty.nuxeo-${cspace.release}.jar"/>
+    <property name="nuxeo.group.jars.all"
+        value="org.collectionspace.services.group.3rdparty.nuxeo-*.jar"/>
+
+    <condition property="osfamily-unix">
+        <os family="unix" />
+    </condition>
+    <condition property="osfamily-windows">
+        <os family="windows" />
+    </condition>
+
+    <target name="init" >
+        <!-- Create the time stamp -->
+        <tstamp/>
+    </target>
+
+    <target name="package" depends="package-unix,package-windows"
+        description="Package CollectionSpace Services" />
+    <target name="package-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="package-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="install" depends="install-unix,install-windows"
+        description="Install" />
+    <target name="install-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="install-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="clean" depends="clean-unix,clean-windows"
+        description="Delete target directories" >
+        <delete dir="${build}"/>
+    </target>
+    <target name="clean-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="clean-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="test" depends="test-unix,test-windows" description="Run tests" />
+    <target name="test-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="test-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="deploy" depends="install"
+        description="deploy group doctype in ${jboss.server.nuxeo}">
+        <copy file="${basedir}/target/${nuxeo.group.jar}"
+        todir="${jboss.deploy.nuxeo.plugins}"/>
+    </target>
+
+    <target name="undeploy"
+        description="undeploy group doctype from ${jboss.server.nuxeo}">
+        <delete>
+            <fileset dir="${jboss.deploy.nuxeo.plugins}">
+                <include name="${nuxeo.group.jars.all}"/>
+            </fileset>
+            <!-- Legacy deployment location through release 0.6 -->
+            <fileset dir="${jboss.deploy.nuxeo.system}">
+                <include name="${nuxeo.group.jars.all}"/>
+            </fileset>
+        </delete>
+    </target>
+
+
+    <target name="dist"
+        description="generate distribution for group doctype" depends="package">
+        <copy todir="${services.trunk}/${dist.deploy.nuxeo.plugins}">
+            <fileset file="${basedir}/target/${nuxeo.group.jar}"/>
+        </copy>
+    </target>
+
+</project>
+
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/pom.xml b/services/group/3rdparty/nuxeo-platform-cs-group/pom.xml
new file mode 100644 (file)
index 0000000..5e8e1e1
--- /dev/null
@@ -0,0 +1,38 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <parent>
+        <groupId>org.collectionspace.services</groupId>
+        <artifactId>org.collectionspace.services.group.3rdparty</artifactId>
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+    
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group.3rdparty.nuxeo</artifactId>
+    <name>services.group.3rdparty.nuxeo</name>
+    <packaging>jar</packaging>
+    <description>
+        Group Nuxeo Document Type
+    </description>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-jar-plugin</artifactId>
+                <configuration>
+                    <archive>
+                        <manifestFile> src/main/resources/META-INF/MANIFEST.MF </manifestFile>
+                        <manifestEntries>
+                            <Bundle-Version>${eclipseVersion}</Bundle-Version>
+                            <Bundle-ManifestVersion>2</Bundle-ManifestVersion>
+                        </manifestEntries>
+                    </archive>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/META-INF/MANIFEST.MF b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..46363cd
--- /dev/null
@@ -0,0 +1,23 @@
+Manifest-Version: 1.0 \r
+Bundle-ManifestVersion: 1 \r
+Bundle-Name: NuxeoCS\r
+Bundle-SymbolicName: org.collectionspace.group;singleton:=true \r
+Bundle-Version: 1.0.0\r
+Bundle-Localization: plugin\r
+Bundle-Vendor: Nuxeo \r
+Require-Bundle: org.nuxeo.runtime, \r
+ org.nuxeo.ecm.core.api, \r
+ org.nuxeo.ecm.core,\r
+ org.nuxeo.ecm.core.api,\r
+ org.nuxeo.ecm.platform.types.api,\r
+ org.nuxeo.ecm.platform.versioning.api,\r
+ org.nuxeo.ecm.platform.ui,\r
+ org.nuxeo.ecm.platform.forms.layout.client,\r
+ org.nuxeo.ecm.platform.ws,\r
+ org.collectionspace.collectionspace_core\r
+Provide-Package: org.collectionspace.group\r
+Nuxeo-Component: OSGI-INF/core-types-contrib.xml,\r
+ OSGI-INF/life-cycle-contrib.xml,\r
+ OSGI-INF/ecm-types-contrib.xml,\r
+ OSGI-INF/layouts-contrib.xml\r
+\r
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/core-types-contrib.xml b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/core-types-contrib.xml
new file mode 100644 (file)
index 0000000..095ed18
--- /dev/null
@@ -0,0 +1,15 @@
+<?xml version="1.0"?>
+<component name="org.collectionspace.group.coreTypes">
+  <extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
+    <schema name="groups_common" prefix="groups_common" src="schemas/groups_common.xsd"/>
+  </extension>
+  
+  <extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
+    <doctype name="Group" extends="Document">
+      <schema name="common"/>
+      <schema name="dublincore"/>
+      <schema name="collectionspace_core"/>
+      <schema name="groups_common"/>
+    </doctype>
+  </extension>
+</component>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/deployment-fragment.xml b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/deployment-fragment.xml
new file mode 100644 (file)
index 0000000..88b94ff
--- /dev/null
@@ -0,0 +1,408 @@
+<?xml version="1.0"?>
+<fragment>
+
+  <extension target="application#MODULE">
+    <module>
+      <ejb>${bundle.fileName}</ejb>
+    </module>
+
+    <module>
+      <web>
+        <web-uri>nuxeo.war</web-uri>
+        <context-root>/nuxeo</context-root>
+      </web>
+    </module>
+  </extension>
+
+  <!-- uncomment that to enable tomcat based auth
+    <extension target="web#LOGIN-CONFIG">
+    <login-config>
+    <auth-method>FORM</auth-method>
+    <realm-name>nuxeo.ecm</realm-name>
+    <form-login-config>
+    <form-login-page>/login.jsp</form-login-page>
+    <form-error-page>/login.jsp?loginFailed=true</form-error-page>
+    </form-login-config>
+    </login-config>
+    </extension>
+  -->
+
+  <extension target="web#FILTER-MAPPING">
+
+    <!-- Seam Context Filter is declared in org.nuxeo.ecm.platform.ui.web
+      deployment fragment -->
+
+    <filter-mapping>
+      <filter-name>Seam Context Filter</filter-name>
+      <url-pattern>/ws/FileManageWS</url-pattern>
+    </filter-mapping>
+
+    <filter-mapping>
+      <filter-name>Seam Context Filter</filter-name>
+      <url-pattern>/DocumentManagerWS</url-pattern>
+    </filter-mapping>
+  </extension>
+
+  <extension target="web#SERVLET">
+  </extension>
+
+  <extension target="web#SERVLET-MAPPING">
+  </extension>
+
+  <extension target="pages#PAGES">
+    <!-- This calls a method which load the Workspace logo -->
+    <page view-id="/showLogo.xhtml" action="#{logoHelper.getLogo}"/>
+
+    <!-- Bind URL to the Document URL resolver-->
+    <page view-id="/getDocument.xhtml"
+        action="#{navigationContext.navigateToURL}">
+    </page>
+
+    <page view-id="/nxliveedit.xhtml" action="#{liveEditHelper.getBootstrap()}"/>
+
+    <!-- Bind URL to the Parallele conversation Document URL resolver-->
+    <page view-id="/parallele.xhtml"
+        action="#{paralleleNavigationHelper.navigateToURL}">
+    </page>
+
+    <!-- Post login and 'home' view handler -->
+    <page view-id="/nxstartup.xhtml"
+        action="#{startupHelper.initDomainAndFindStartupPage('Default domain', 'view')}"/>
+
+    <!-- To redirect to the user dashboard instead, use instead:
+
+      <page view-id="/nxstartup.xhtml"
+      action="#{startupHelper.initDomainAndFindStartupPage('Default domain', 'user_dashboard')}" />
+    -->
+
+    <!--  config for workspace management
+      = give a description for each viewId
+    -->
+
+    <page view-id="/view_domains.xhtml">
+      #{currentServerLocation.name}/#{currentTabAction.label}
+    </page>
+
+    <page view-id="/select_document_type.faces.xhtml">
+      Create new document in #{currentDocument.name}
+    </page>
+
+    <page view-id="/create_document.faces.xhtml">
+      Create new document in #{currentDocument.name}
+    </page>
+
+    <page view-id="/user_dashboard.xhtml">
+      breadcrumb=command.user_dashboard
+    </page>
+
+    <page view-id="/view_users.xhtml">
+      breadcrumb=command.manageMembers
+    </page>
+
+    <page view-id="/view_many_users.xhtml">
+      breadcrumb=command.manageMembers
+    </page>
+
+    <page view-id="/view_vocabularies.xhtml">
+      breadcrumb=title.vocabularies
+    </page>
+
+    <page view-id="/search/search_form.xhtml">
+      breadcrumb=command.advancedSearch
+    </page>
+  </extension>
+
+  <extension target="faces-config#APPLICATION">
+    <locale-config>
+      <default-locale>en</default-locale>
+      <supported-locale>en_GB</supported-locale>
+      <supported-locale>en_US</supported-locale>
+      <supported-locale>fr</supported-locale>
+      <supported-locale>de</supported-locale>
+      <supported-locale>es</supported-locale>
+      <supported-locale>it</supported-locale>
+      <supported-locale>ar</supported-locale>
+      <supported-locale>ru</supported-locale>
+      <supported-locale>ja</supported-locale>
+      <supported-locale>vn</supported-locale>
+    </locale-config>
+
+    <message-bundle>messages</message-bundle>
+  </extension>
+
+  <extension target="components#PAGEFLOW">
+    <value>config/addWorkspace.jpdl.xml</value>
+  </extension>
+
+  <extension target="faces-config#NAVIGATION">
+    <!-- generic pages -->
+    <navigation-case>
+      <from-outcome>generic_error_page</from-outcome>
+      <to-view-id>/generic_error_page.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>generic_message_page</from-outcome>
+      <to-view-id>/generic_message_page.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>home</from-outcome>
+      <to-view-id>/nxstartup.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>user_login</from-outcome>
+      <to-view-id>/login.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>user_logout</from-outcome>
+      <to-view-id>/logout.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_servers</from-outcome>
+      <to-view-id>/view_servers.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- pages for document actions -->
+
+    <navigation-case>
+      <from-outcome>view_domains</from-outcome>
+      <to-view-id>/view_domains.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>select_document_type</from-outcome>
+      <to-view-id>/select_document_type.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>create_document</from-outcome>
+      <to-view-id>/create_document.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>edit_document</from-outcome>
+      <to-view-id>/edit_document.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_documents</from-outcome>
+      <to-view-id>/view_documents.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>create_file</from-outcome>
+      <to-view-id>/create_file.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>create_workspace_wizard</from-outcome>
+      <to-view-id>/createWorkspaceWizard.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>send_email</from-outcome>
+      <to-view-id>/document_email.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- AT: BBB, use view_documents instead -->
+    <navigation-case>
+      <from-outcome>view_workspaces</from-outcome>
+      <to-view-id>/view_workspaces.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- AT: BBB, use create_document instead -->
+    <navigation-case>
+      <from-outcome>create_domain</from-outcome>
+      <to-view-id>/create_domain.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- AT: BBB, use edit_document instead -->
+    <navigation-case>
+      <from-outcome>edit_domain</from-outcome>
+      <to-view-id>/edit_domain.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- AT: BBB, use create_document instead -->
+    <navigation-case>
+      <from-outcome>create_workspace</from-outcome>
+      <to-view-id>/create_workspace.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- AT: BBB, use edit_document instead -->
+    <navigation-case>
+      <from-outcome>edit_workspace</from-outcome>
+      <to-view-id>/edit_workspace.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- users ang groups -->
+
+    <navigation-case>
+      <from-outcome>members_management</from-outcome>
+      <to-view-id>/members_management.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_users</from-outcome>
+      <to-view-id>/view_users.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_many_users</from-outcome>
+      <to-view-id>/view_many_users.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>edit_user</from-outcome>
+      <to-view-id>/edit_user.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>edit_user_password</from-outcome>
+      <to-view-id>/edit_user_password.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_user</from-outcome>
+      <to-view-id>/view_user.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>create_user</from-outcome>
+      <to-view-id>/create_user.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_groups</from-outcome>
+      <to-view-id>/view_groups.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_group</from-outcome>
+      <to-view-id>/view_group.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>edit_group</from-outcome>
+      <to-view-id>/edit_group.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>create_group</from-outcome>
+      <to-view-id>/create_group.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_vocabularies</from-outcome>
+      <to-view-id>/view_vocabularies.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>view_vocabulary</from-outcome>
+      <to-view-id>/view_vocabulary.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- search -->
+
+    <navigation-case>
+      <from-outcome>search_form</from-outcome>
+      <to-view-id>/search/search_form.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>search_results_nxql</from-outcome>
+      <to-view-id>/search/search_results_nxql.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>search_results_advanced</from-outcome>
+      <to-view-id>
+        /search/search_results_advanced.xhtml
+      </to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>search_results_simple</from-outcome>
+      <to-view-id>/search/search_results_simple.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <!-- miscellaneaous -->
+
+    <navigation-case>
+      <from-outcome>clipboard</from-outcome>
+      <to-view-id>/incl/clipboard.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>user_dashboard</from-outcome>
+      <to-view-id>/user_dashboard.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>select_workspace_template</from-outcome>
+      <to-view-id>/select_workspace_template.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>pdf_generation_error</from-outcome>
+      <to-view-id>/pdf_generation_error.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>mass_edit</from-outcome>
+      <to-view-id>/massedit_documents.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+
+    <navigation-case>
+      <from-outcome>mass_edit_confirm</from-outcome>
+      <to-view-id>/massedit_documents_preview.xhtml</to-view-id>
+      <redirect/>
+    </navigation-case>
+  </extension>
+
+</fragment>
+
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/ecm-types-contrib.xml b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/ecm-types-contrib.xml
new file mode 100644 (file)
index 0000000..fece3e4
--- /dev/null
@@ -0,0 +1,29 @@
+<?xml version="1.0"?>
+<component name="org.collectionspace.group.ecm.types">
+  <extension target="org.nuxeo.ecm.platform.types.TypeService" point="types">
+    <type id="Group" coretype="Group">
+      <label>org.collectionspace.group</label>
+      <!--icon>/icons/file.gif</icon-->
+      <default-view>view_documents</default-view>
+
+      <layouts mode="any">
+        <layout>heading</layout>
+        <layout>collectionspace_core</layout>
+        <layout>group</layout>
+      </layouts>        
+    </type>
+
+    <type id="Folder" coretype="Folder">
+      <subtypes>
+        <type>Group</type>
+      </subtypes>
+    </type>
+    
+    <type id="Workspace" coretype="Workspace">
+      <subtypes>
+        <type>Group</type>
+      </subtypes>
+    </type>
+
+  </extension>
+</component>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/layouts-contrib.xml b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/layouts-contrib.xml
new file mode 100644 (file)
index 0000000..0e73267
--- /dev/null
@@ -0,0 +1,78 @@
+<?xml version="1.0"?>
+
+<!--
+layouts-contrib.xml
+
+Layout file for configuring screen layouts in the
+user interface of Nuxeo EP's web application, for
+viewing or editing CollectionSpace records stored
+in the Nuxeo repository,
+
+See the "Nuxeo Book" for an introductory description
+of how to edit this file.  For instance, for Nuxeo EP 5.3:
+http://doc.nuxeo.org/5.3/books/nuxeo-book/html/
+
+$LastChangedRevision: $
+$LastChangedDate: $
+-->
+
+<component name="org.collectionspace.group.layouts.webapp">
+
+    <extension target="org.nuxeo.ecm.platform.forms.layout.WebLayoutManager"
+               point="layouts">
+
+        <layout name="group">
+            <templates>
+                <template mode="any">/layouts/layout_default_template.xhtml</template>
+            </templates>       
+            
+            <rows>
+                <row><widget>title</widget></row>
+                <row><widget>scopeNote</widget></row>
+                <row><widget>responsibleDept</widget></row>
+                
+            </rows>
+
+            <widget name="title" type="text">
+                <labels>
+                    <label mode="any">Title</label>
+                </labels>
+                <translated>true</translated>
+                <fields>
+                    <field schema="groups_common">title</field>
+                </fields>
+                <properties widgetMode="edit">
+                    <property name="styleClass">dataInputText</property>
+                </properties>
+            </widget>
+
+            <widget name="scopeNote" type="text">
+                <labels>
+                    <label mode="any">Scope Note</label>
+                </labels>
+                <translated>true</translated>
+                <fields>
+                    <field schema="groups_common">scopeNote</field>
+                </fields>
+                <properties widgetMode="edit">
+                    <property name="styleClass">dataInputText</property>
+                </properties>
+            </widget>
+            
+            <widget name="responsibleDept" type="text">
+                <labels>
+                    <label mode="any">Responsible Dept.</label>
+                </labels>
+                <translated>true</translated>
+                <fields>
+                    <field schema="groups_common">responsibleDepartment</field>
+                </fields>
+                <properties widgetMode="edit">
+                    <property name="styleClass">dataInputText</property>
+                </properties>
+            </widget>
+            
+
+        </layout>
+    </extension>
+</component>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/life-cycle-contrib.xml b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/OSGI-INF/life-cycle-contrib.xml
new file mode 100644 (file)
index 0000000..18caecf
--- /dev/null
@@ -0,0 +1,11 @@
+<?xml version="1.0"?>
+<component name="org.collectionspace.ecm.platform.group.LifeCycleManagerExtensions">
+
+  <extension target="org.nuxeo.ecm.core.lifecycle.LifeCycleService"
+             point="types">
+    <types>
+      <type name="Group">default</type>
+    </types>
+  </extension>
+
+</component>
diff --git a/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/schemas/groups_common.xsd b/services/group/3rdparty/nuxeo-platform-cs-group/src/main/resources/schemas/groups_common.xsd
new file mode 100644 (file)
index 0000000..745a89b
--- /dev/null
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r
+\r
+<!--\r
+    Loan Out schema (XSD)\r
+    \r
+    Entity  : Group\r
+    Part    : Common\r
+    Used for: Nuxeo EP core document type\r
+\r
+    $LastChangedRevision: 2316 $\r
+    $LastChangedDate: 2010-06-02 16:03:51 -0700 (Wed, 02 Jun 2010) $\r
+-->\r
+\r
+<xs:schema \r
+    xmlns:xs="http://www.w3.org/2001/XMLSchema"\r
+    xmlns:ns="http://collectionspace.org/group/"\r
+    xmlns="http://collectionspace.org/group/"\r
+    targetNamespace="http://collectionspace.org/group/"\r
+    version="0.1">\r
+    \r
+    <!-- See http://wiki.collectionspace.org/display/collectionspace/Groups+Schema -->\r
+\r
+    <!--  Group Information Group -->\r
+    <xs:element name="title" type="xs:string"/>\r
+    <xs:element name="scopeNote" type="xs:string"/>\r
+    <xs:element name="responsibleDepartment" type="xs:string"/>\r
+</xs:schema>\r
diff --git a/services/group/3rdparty/pom.xml b/services/group/3rdparty/pom.xml
new file mode 100644 (file)
index 0000000..459c0ae
--- /dev/null
@@ -0,0 +1,24 @@
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <parent>
+        <artifactId>org.collectionspace.services.group</artifactId>
+        <groupId>org.collectionspace.services</groupId>
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+    
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group.3rdparty</artifactId>
+    <name>services.group.3rdparty</name>
+    <packaging>pom</packaging>
+    
+    <description>
+        3rd party build for group service
+    </description>
+
+    <modules>
+        <module>nuxeo-platform-cs-group</module>
+    </modules>
+</project>
diff --git a/services/group/build.xml b/services/group/build.xml
new file mode 100644 (file)
index 0000000..b85db18
--- /dev/null
@@ -0,0 +1,124 @@
+
+<project name="group" default="package" basedir=".">
+    <description>
+        group service
+    </description>
+  <!-- set global properties for this build -->
+    <property name="services.trunk" value="../.."/>
+    <!-- environment should be declared before reading build.properties -->
+    <property environment="env" />
+    <property file="${services.trunk}/build.properties" />
+    <property name="mvn.opts" value="" />
+    <property name="src" location="src"/>
+
+    <condition property="osfamily-unix">
+        <os family="unix" />
+    </condition>
+    <condition property="osfamily-windows">
+        <os family="windows" />
+    </condition>
+
+    <target name="package" depends="package-unix,package-windows"
+  description="Package CollectionSpace Services" />
+  
+    <target name="package-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    
+    <target name="package-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="package" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+
+    <target name="install" depends="install-unix,install-windows"
+  description="Install" />
+    <target name="install-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="install-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="install" />
+            <arg value="-Dmaven.test.skip=true" />
+            <arg value="-f" />
+            <arg value="${basedir}/pom.xml" />
+            <arg value="-N" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="clean" depends="clean-unix,clean-windows"
+  description="Delete target directories" >
+        <delete dir="${build}"/>
+    </target>
+    <target name="clean-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="clean-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="clean" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="test" depends="test-unix,test-windows" description="Run tests" />
+    <target name="test-unix" if="osfamily-unix">
+        <exec executable="mvn" failonerror="true">
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+    <target name="test-windows" if="osfamily-windows">
+        <exec executable="cmd" failonerror="true">
+            <arg value="/c" />
+            <arg value="mvn.bat" />
+            <arg value="test" />
+            <arg value="${mvn.opts}" />
+        </exec>
+    </target>
+
+    <target name="deploy" depends="install"
+    description="deploy group service">
+        <ant antfile="3rdparty/build.xml" target="deploy" inheritall="false"/>
+    </target>
+
+    <target name="undeploy"
+    description="undeploy group service">
+        <ant antfile="3rdparty/build.xml" target="undeploy" inheritall="false"/>
+    </target>
+
+    <target name="dist" depends="package"
+    description="distribute group service">
+        <ant antfile="3rdparty/build.xml" target="dist" inheritall="false"/>
+    </target>
+
+</project>
diff --git a/services/group/client/.classpath b/services/group/client/.classpath
new file mode 100644 (file)
index 0000000..425cd16
--- /dev/null
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="src" output="target/classes" path="src/main/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>\r
+       <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources"/>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/client/.project b/services/group/client/.project
new file mode 100644 (file)
index 0000000..8e3ece9
--- /dev/null
@@ -0,0 +1,29 @@
+<projectDescription>\r
+  <name>org.collectionspace.services.group.client</name>\r
+  <comment>NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>\r
+  <projects>\r
+    <project>org.collectionspace.services.3rdparty.nuxeo.quote-api</project>\r
+    <project>org.collectionspace.services.client</project>\r
+    <project>org.collectionspace.services.common</project>\r
+    <project>org.collectionspace.services.common-api</project>\r
+    <project>org.collectionspace.services.contact.client</project>\r
+    <project>org.collectionspace.services.contact.jaxb</project>\r
+    <project>org.collectionspace.services.hyperjaxb</project>\r
+    <project>org.collectionspace.services.jaxb</project>\r
+    <project>org.collectionspace.services.group.jaxb</project>\r
+    <project>org.collectionspace.services.person.client</project>\r
+    <project>org.collectionspace.services.person.jaxb</project>\r
+  </projects>\r
+  <buildSpec>\r
+    <buildCommand>\r
+      <name>org.eclipse.jdt.core.javabuilder</name>\r
+    </buildCommand>\r
+    <buildCommand>\r
+      <name>org.maven.ide.eclipse.maven2Builder</name>\r
+    </buildCommand>\r
+  </buildSpec>\r
+  <natures>\r
+    <nature>org.eclipse.jdt.core.javanature</nature>\r
+    <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+  </natures>\r
+</projectDescription>\r
diff --git a/services/group/client/.settings/org.maven.ide.eclipse.prefs b/services/group/client/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..e2ce08c
--- /dev/null
@@ -0,0 +1,9 @@
+#Fri Aug 27 16:35:21 PDT 2010\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/client/pom.xml b/services/group/client/pom.xml
new file mode 100644 (file)
index 0000000..e3f8d0c
--- /dev/null
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <parent>
+        <groupId>org.collectionspace.services</groupId>
+        <artifactId>org.collectionspace.services.group</artifactId>
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group.client</artifactId>
+    <name>services.group.client</name>
+    
+    <dependencies>
+        <!-- keep slf4j dependencies on the top -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <scope>test</scope>
+        </dependency>
+<!-- CollectionSpace dependencies -->
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.authority</artifactId>
+            <optional>true</optional>
+            <version>${project.version}</version>
+        </dependency>        
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.jaxb</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.common</artifactId>
+            <optional>true</optional>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.client</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+         <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.group.jaxb</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.person.client</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+<!-- External dependencies -->        
+        <dependency>
+            <groupId>org.testng</groupId>
+            <artifactId>testng</artifactId>
+            <version>5.6</version>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-jaxrs</artifactId>
+            <!-- filter out unwanted jars -->
+            <exclusions>
+                <exclusion>
+                    <groupId>tjws</groupId>
+                    <artifactId>webserver</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-jaxb-provider</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-multipart-provider</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>commons-httpclient</groupId>
+            <artifactId>commons-httpclient</artifactId>
+            <version>3.1</version>
+        </dependency>
+    </dependencies>
+    
+    <build>
+        <finalName>collectionspace-services-group-client</finalName>
+    </build>
+</project>
diff --git a/services/group/client/src/main/java/org/collectionspace/services/client/GroupClient.java b/services/group/client/src/main/java/org/collectionspace/services/client/GroupClient.java
new file mode 100644 (file)
index 0000000..e73ace1
--- /dev/null
@@ -0,0 +1,60 @@
+/**    
+ * This document is a part of the source code and related artifacts
+ * for CollectionSpace, an open source collections management system
+ * for museums and related institutions:
+ *
+ * http://www.collectionspace.org
+ * http://wiki.collectionspace.org
+ *
+ * Copyright (c) 2009 Regents of the University of California
+ *
+ * Licensed under the Educational Community License (ECL), Version 2.0.
+ * You may not use this file except in compliance with this License.
+ *
+ * You may obtain a copy of the ECL 2.0 License at
+ * https://source.collectionspace.org/collection-space/LICENSE.txt
+ */
+package org.collectionspace.services.client;
+
+import org.collectionspace.services.jaxb.AbstractCommonList;
+import org.jboss.resteasy.client.ClientResponse;
+
+/**
+ * GroupClient.java
+ *
+ * $LastChangedRevision: 2108 $
+ * $LastChangedDate: 2010-05-17 18:25:37 -0700 (Mon, 17 May 2010) $
+ *
+ */
+public class GroupClient extends AbstractPoxServiceClientImpl<AbstractCommonList, GroupProxy> {
+       public static final String SERVICE_NAME = "groups";
+       public static final String SERVICE_PATH_COMPONENT = SERVICE_NAME;       
+       public static final String SERVICE_PATH = "/" + SERVICE_PATH_COMPONENT;
+       public static final String SERVICE_PATH_PROXY = SERVICE_PATH + "/";     
+       public static final String SERVICE_PAYLOAD_NAME = SERVICE_NAME; 
+
+       @Override
+       public String getServiceName() {
+               return SERVICE_NAME;
+       }
+       
+       @Override
+    public String getServicePathComponent() {
+        return SERVICE_PATH_COMPONENT;
+    }
+
+       @Override
+       public Class<GroupProxy> getProxyClass() {
+               // TODO Auto-generated method stub
+               return GroupProxy.class;
+       }
+
+       /*
+        * Proxied service calls.
+        * 
+        */
+       
+    public ClientResponse<AbstractCommonList> readList() {
+        return getProxy().readList();
+    }
+}
diff --git a/services/group/client/src/main/java/org/collectionspace/services/client/GroupProxy.java b/services/group/client/src/main/java/org/collectionspace/services/client/GroupProxy.java
new file mode 100644 (file)
index 0000000..610a5a8
--- /dev/null
@@ -0,0 +1,62 @@
+/**    
+ * GroupProxy.java
+ *
+ * {Purpose of This Class}
+ *
+ * {Other Notes Relating to This Class (Optional)}
+ *
+ * $LastChangedBy: $
+ * $LastChangedRevision: $
+ * $LastChangedDate: $
+ *
+ * This document is a part of the source code and related artifacts
+ * for CollectionSpace, an open source collections management system
+ * for museums and related institutions:
+ *
+ * http://www.collectionspace.org
+ * http://wiki.collectionspace.org
+ *
+ * Copyright Â© 2011 U.C. Berkeley
+ *
+ * Licensed under the Educational Community License (ECL), Version 2.0.
+ * You may not use this file except in compliance with this License.
+ *
+ * You may obtain a copy of the ECL 2.0 License at
+ * https://source.collectionspace.org/collection-space/LICENSE.txt
+ */
+package org.collectionspace.services.client;
+
+import org.jboss.resteasy.client.ClientResponse;
+import javax.ws.rs.Consumes;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+import javax.ws.rs.QueryParam;
+
+import org.collectionspace.services.client.workflow.WorkflowClient;
+import org.collectionspace.services.jaxb.AbstractCommonList;
+
+/**
+ * @version $Revision: 2108 $
+ */
+@Path(GroupClient.SERVICE_PATH_PROXY)
+@Produces({"application/xml"})
+@Consumes({"application/xml"})
+public interface GroupProxy extends CollectionSpacePoxProxy<AbstractCommonList> {
+    // List
+    @GET
+    ClientResponse<AbstractCommonList> readList();
+    
+    @Override
+               @GET
+    @Produces({"application/xml"})
+    ClientResponse<AbstractCommonList> readIncludeDeleted(
+            @QueryParam(WorkflowClient.WORKFLOW_QUERY_NONDELETED) String includeDeleted);
+
+               @Override
+    @GET
+    @Produces({"application/xml"})
+    ClientResponse<AbstractCommonList> keywordSearchIncludeDeleted(
+               @QueryParam(IQueryManager.SEARCH_TYPE_KEYWORDS_KW) String keywords,
+            @QueryParam(WorkflowClient.WORKFLOW_QUERY_NONDELETED) String includeDeleted);
+}
diff --git a/services/group/client/src/test/java/org/collectionspace/services/client/test/GroupServiceTest.java b/services/group/client/src/test/java/org/collectionspace/services/client/test/GroupServiceTest.java
new file mode 100644 (file)
index 0000000..97b1abd
--- /dev/null
@@ -0,0 +1,279 @@
+/**
+ * This document is a part of the source code and related artifacts
+ * for CollectionSpace, an open source collections management system
+ * for museums and related institutions:
+ *
+ * http://www.collectionspace.org
+ * http://wiki.collectionspace.org
+ *
+ * Copyright Â© 2009 Regents of the University of California
+ *
+ * Licensed under the Educational Community License (ECL), Version 2.0.
+ * You may not use this file except in compliance with this License.
+ *
+ * You may obtain a copy of the ECL 2.0 License at
+ * https://source.collectionspace.org/collection-space/LICENSE.txt
+ *
+ * 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.collectionspace.services.client.test;
+
+import java.util.List;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+
+import org.collectionspace.services.client.CollectionSpaceClient;
+import org.collectionspace.services.client.GroupClient;
+import org.collectionspace.services.client.GroupProxy;
+import org.collectionspace.services.client.PayloadOutputPart;
+import org.collectionspace.services.client.PoxPayloadIn;
+import org.collectionspace.services.client.PoxPayloadOut;
+import org.collectionspace.services.jaxb.AbstractCommonList;
+import org.collectionspace.services.group.GroupsCommon;
+
+import org.jboss.resteasy.client.ClientResponse;
+
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * GroupServiceTest, carries out tests against a deployed and running Group Service. <p/>
+ * $LastChangedRevision:  $
+ * $LastChangedDate:  $
+ */
+public class GroupServiceTest extends AbstractServiceTestImpl {
+
+    private final String CLASS_NAME = GroupServiceTest.class.getName();
+    private final Logger logger = LoggerFactory.getLogger(CLASS_NAME);
+    final String SERVICE_PATH_COMPONENT = "groups";
+    private String knownResourceId = null;
+
+    @Override
+       public String getServicePathComponent() {
+               return GroupClient.SERVICE_PATH_COMPONENT;
+       }
+
+       @Override
+       protected String getServiceName() {
+               return GroupClient.SERVICE_NAME;
+       }
+    
+    @Override
+    protected CollectionSpaceClient<AbstractCommonList, GroupProxy> getClientInstance() {
+        return new GroupClient();
+    }
+
+    @Override
+    protected AbstractCommonList getAbstractCommonList(ClientResponse<AbstractCommonList> response) {
+        return response.getEntity(AbstractCommonList.class);
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class)
+    public void create(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupCreate();
+        GroupClient client = new GroupClient();
+        PoxPayloadOut multipart = createGroupInstance(createIdentifier());
+        ClientResponse<Response> res = client.create(multipart);
+        assertStatusCode(res, testName);
+        if (knownResourceId == null) {
+            knownResourceId = extractId(res);  // Store the ID returned from the first resource created for additional tests below.
+            logger.debug(testName + ": knownResourceId=" + knownResourceId);
+        }
+        allResourceIdsCreated.add(extractId(res)); // Store the IDs from every resource created by tests so they can be deleted after tests have been run.
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"create"})
+    public void createList(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        for (int i = 0; i < 3; i++) {
+            create(testName);
+        }
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"create"})
+    public void read(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupRead();
+        GroupClient client = new GroupClient();
+        ClientResponse<String> res = client.read(knownResourceId);
+        assertStatusCode(res, testName);
+        PoxPayloadIn input = new PoxPayloadIn(res.getEntity());
+        GroupsCommon group = (GroupsCommon) extractPart(input, client.getCommonPartName(), GroupsCommon.class);
+        Assert.assertNotNull(group);
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"createList", "read"})
+    public void readList(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupReadList();
+        GroupClient client = new GroupClient();
+        ClientResponse<AbstractCommonList> res = client.readList();
+        AbstractCommonList list = res.getEntity();
+        assertStatusCode(res, testName);
+        if (logger.isDebugEnabled()) {
+            List<AbstractCommonList.ListItem> items =
+                list.getListItem();
+            int i = 0;
+            for(AbstractCommonList.ListItem item : items){
+                logger.debug(testName + ": list-item[" + i + "] " +
+                        item.toString());
+                i++;
+            }
+        }
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"read"})
+    public void update(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupUpdate();
+        GroupClient client = new GroupClient();
+        ClientResponse<String> res = client.read(knownResourceId);
+        assertStatusCode(res, testName);
+        logger.debug("got object to update with ID: " + knownResourceId);
+        PoxPayloadIn input = new PoxPayloadIn(res.getEntity());
+        GroupsCommon group = (GroupsCommon) extractPart(input, client.getCommonPartName(), GroupsCommon.class);
+        Assert.assertNotNull(group);
+
+        group.setTitle("updated-" + group.getTitle());
+        logger.debug("Object to be updated:"+objectAsXmlString(group, GroupsCommon.class));
+        PoxPayloadOut output = new PoxPayloadOut(GroupClient.SERVICE_PAYLOAD_NAME);
+        PayloadOutputPart commonPart = output.addPart(group, MediaType.APPLICATION_XML_TYPE);
+        commonPart.setLabel(client.getCommonPartName());
+        res = client.update(knownResourceId, output);
+        assertStatusCode(res, testName);
+        input = new PoxPayloadIn(res.getEntity());
+        GroupsCommon updatedGroup = (GroupsCommon) extractPart(input, client.getCommonPartName(), GroupsCommon.class);
+        Assert.assertNotNull(updatedGroup);
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"update", "testSubmitRequest"})
+    public void updateNonExistent(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupUpdateNonExistent();
+        // Submit the request to the service and store the response.
+        // Note: The ID used in this 'create' call may be arbitrary.
+        // The only relevant ID may be the one used in update(), below.
+        GroupClient client = new GroupClient();
+        PoxPayloadOut multipart = createGroupInstance(NON_EXISTENT_ID);
+        ClientResponse<String> res = client.update(NON_EXISTENT_ID, multipart);
+        assertStatusCode(res, testName);
+    }
+
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"create", "readList", "testSubmitRequest", "update"})
+    public void delete(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupDelete();
+        GroupClient client = new GroupClient();
+        ClientResponse<Response> res = client.delete(knownResourceId);
+        assertStatusCode(res, testName);
+    }
+
+    // ---------------------------------------------------------------
+    // Failure outcome tests : means we expect response to fail, but test to succeed
+    // ---------------------------------------------------------------
+
+    // Failure outcome
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"read"})
+    public void readNonExistent(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupReadNonExistent();
+        GroupClient client = new GroupClient();
+        ClientResponse<String> res = client.read(NON_EXISTENT_ID);
+        assertStatusCode(res, testName);
+    }
+
+    // Failure outcome
+    @Override
+    @Test(dataProvider = "testName", dataProviderClass = AbstractServiceTestImpl.class, dependsOnMethods = {"delete"})
+    public void deleteNonExistent(String testName) throws Exception {
+        logger.debug(testBanner(testName, CLASS_NAME));
+        setupDeleteNonExistent();
+        GroupClient client = new GroupClient();
+        ClientResponse<Response> res = client.delete(NON_EXISTENT_ID);
+        assertStatusCode(res, testName);
+    }
+
+    // Failure outcomes
+    // Placeholders until the tests below can be implemented. See Issue CSPACE-401.
+
+    @Override
+    public void createWithEmptyEntityBody(String testName) throws Exception {
+    }
+
+    @Override
+    public void createWithMalformedXml(String testName) throws Exception {
+    }
+
+    @Override
+    public void createWithWrongXmlSchema(String testName) throws Exception {
+    }
+
+    @Override
+    public void updateWithEmptyEntityBody(String testName) throws Exception {
+    }
+
+    @Override
+    public void updateWithMalformedXml(String testName) throws Exception {
+    }
+
+    @Override
+    public void updateWithWrongXmlSchema(String testName) throws Exception {
+    }
+
+    // ---------------------------------------------------------------
+    // Utility tests : tests of code used in tests above
+    // ---------------------------------------------------------------
+
+    @Test(dependsOnMethods = {"create", "read"})
+    public void testSubmitRequest() {
+        final int EXPECTED_STATUS = Response.Status.OK.getStatusCode(); // Expected status code: 200 OK
+        String method = ServiceRequestType.READ.httpMethodName();
+        String url = getResourceURL(knownResourceId);
+        int statusCode = submitRequest(method, url);
+        logger.debug("testSubmitRequest: url=" + url + " status=" + statusCode);
+        Assert.assertEquals(statusCode, EXPECTED_STATUS);
+    }
+
+    // ---------------------------------------------------------------
+    // Utility methods used by tests above
+    // ---------------------------------------------------------------
+    
+    @Override
+    protected PoxPayloadOut createInstance(String identifier) {
+       GroupClient client = new GroupClient();
+       return createGroupInstance(identifier);
+    }
+    
+    private PoxPayloadOut createGroupInstance(String uid) {
+        String identifier = "title-" + uid;
+        GroupsCommon group = new GroupsCommon();
+        group.setTitle(identifier);
+        group.setResponsibleDepartment("antiquities");
+        PoxPayloadOut multipart = new PoxPayloadOut(GroupClient.SERVICE_PAYLOAD_NAME);
+        PayloadOutputPart commonPart = multipart.addPart(group, MediaType.APPLICATION_XML_TYPE);
+        commonPart.setLabel(new GroupClient().getCommonPartName());
+
+        if (logger.isDebugEnabled()) {
+            logger.debug("to be created, group common");
+            logger.debug(objectAsXmlString(group, GroupsCommon.class));
+        }
+
+        return multipart;
+    }
+}
diff --git a/services/group/client/src/test/resources/log4j.properties b/services/group/client/src/test/resources/log4j.properties
new file mode 100644 (file)
index 0000000..18c5103
--- /dev/null
@@ -0,0 +1,23 @@
+log4j.rootLogger=debug, stdout, R\r
+\r
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender\r
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout\r
+\r
+# Pattern to output the caller's file name and line number.\r
+log4j.appender.stdout.layout.ConversionPattern=%d %-5p [%t] [%c:%L] %m%n\r
+\r
+log4j.appender.R=org.apache.log4j.RollingFileAppender\r
+log4j.appender.R.File=target/test-client.log\r
+\r
+log4j.appender.R.MaxFileSize=100KB\r
+# Keep one backup file\r
+log4j.appender.R.MaxBackupIndex=1\r
+\r
+log4j.appender.R.layout=org.apache.log4j.PatternLayout\r
+log4j.appender.R.layout.ConversionPattern=%d %-5p [%t] [%c:%L] %m%n\r
+\r
+#packages\r
+log4j.logger.org.collectionspace=DEBUG\r
+log4j.logger.org.apache=INFO\r
+log4j.logger.httpclient=INFO\r
+log4j.logger.org.jboss.resteasy=INFO\r
diff --git a/services/group/jaxb/.classpath b/services/group/jaxb/.classpath
new file mode 100644 (file)
index 0000000..bd6bf38
--- /dev/null
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="src" output="target/classes" path="src/main/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>\r
+       <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/jaxb/.project b/services/group/jaxb/.project
new file mode 100644 (file)
index 0000000..11524f3
--- /dev/null
@@ -0,0 +1,19 @@
+<projectDescription>\r
+  <name>org.collectionspace.services.group.jaxb</name>\r
+  <comment>NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>\r
+  <projects>\r
+    <project>org.collectionspace.services.jaxb</project>\r
+  </projects>\r
+  <buildSpec>\r
+    <buildCommand>\r
+      <name>org.eclipse.jdt.core.javabuilder</name>\r
+    </buildCommand>\r
+    <buildCommand>\r
+      <name>org.maven.ide.eclipse.maven2Builder</name>\r
+    </buildCommand>\r
+  </buildSpec>\r
+  <natures>\r
+    <nature>org.eclipse.jdt.core.javanature</nature>\r
+    <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+  </natures>\r
+</projectDescription>\r
diff --git a/services/group/jaxb/.settings/org.maven.ide.eclipse.prefs b/services/group/jaxb/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..c9f07df
--- /dev/null
@@ -0,0 +1,9 @@
+#Wed Jan 19 22:49:45 PST 2011\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/jaxb/pom.xml b/services/group/jaxb/pom.xml
new file mode 100644 (file)
index 0000000..6bf713b
--- /dev/null
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <parent>
+        <artifactId>org.collectionspace.services.group</artifactId>
+        <groupId>org.collectionspace.services</groupId>
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+    
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group.jaxb</artifactId>
+    <name>services.group.jaxb</name>
+    
+    <dependencies>
+        <dependency>
+            <groupId>com.sun.xml.bind</groupId>
+            <artifactId>jaxb-impl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.jvnet.jaxb2-commons</groupId>
+            <artifactId>property-listener-injector</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.jvnet.jaxb2_commons</groupId>
+            <artifactId>runtime</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.jaxb</artifactId>
+            <version>${project.version}</version>
+        </dependency>        
+    </dependencies>
+    
+    <build>
+        <finalName>collectionspace-services-group-jaxb</finalName>
+        <defaultGoal>install</defaultGoal>
+        <plugins>
+            <plugin>
+                <groupId>org.jvnet.jaxb2.maven2</groupId>
+                <artifactId>maven-jaxb2-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+</project>
+
diff --git a/services/group/jaxb/src/main/java/org/collectionspace/services/GroupJAXBSchema.java b/services/group/jaxb/src/main/java/org/collectionspace/services/GroupJAXBSchema.java
new file mode 100644 (file)
index 0000000..e2e86fc
--- /dev/null
@@ -0,0 +1,10 @@
+/**
+ * 
+ */
+package org.collectionspace.services;
+
+public interface GroupJAXBSchema {
+    final static String GROUP_TITLE = "title";
+    final static String GROUP_SCOPE_NOTE = "scopeNote";
+    final static String GROUP_RESPONSIBLE_DEPARTMENT = "responsibleDepartment";
+}
diff --git a/services/group/jaxb/src/main/java/org/collectionspace/services/GroupListItemJAXBSchema.java b/services/group/jaxb/src/main/java/org/collectionspace/services/GroupListItemJAXBSchema.java
new file mode 100644 (file)
index 0000000..22f35ec
--- /dev/null
@@ -0,0 +1,6 @@
+package org.collectionspace.services;
+
+public interface GroupListItemJAXBSchema {
+       final static String CSID = "csid";
+       final static String URI = "url";
+}
diff --git a/services/group/jaxb/src/main/resources/groups_common.xsd b/services/group/jaxb/src/main/resources/groups_common.xsd
new file mode 100644 (file)
index 0000000..cd79309
--- /dev/null
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+
+<!--
+    Loan Out schema (XSD)
+    
+    Entity  : Group
+    Part    : Common
+    Used for: JAXB binding between XML and Java objects
+
+    $LastChangedRevision: 2316 $
+    $LastChangedDate: 2010-06-02 16:03:51 -0700 (Wed, 02 Jun 2010) $
+-->
+
+<xs:schema 
+  xmlns:xs="http://www.w3.org/2001/XMLSchema"
+  xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
+  jaxb:version="1.0" elementFormDefault="unqualified"
+  xmlns:ns="http://collectionspace.org/services/group"
+  xmlns="http://collectionspace.org/services/group"
+  targetNamespace="http://collectionspace.org/services/group"
+  version="0.1"
+>
+
+<!--
+    Avoid XmlRootElement nightmare:
+    See http://weblogs.java.net/blog/kohsuke/archive/2006/03/why_does_jaxb_p.html
+-->
+<!-- See http://wiki.collectionspace.org/display/collectionspace/Loans+Out+Schema -->    
+    
+    <!-- group -->
+    <xs:element name="groups_common">
+        <xs:complexType>
+            <xs:sequence>
+                <!--  Group Information Group -->
+                <xs:element name="title" type="xs:string"/>
+                <xs:element name="scopeNote" type="xs:string"/>
+                <xs:element name="responsibleDepartment" type="xs:string"/>
+            </xs:sequence>
+        </xs:complexType>
+    </xs:element>
+    
+    <!-- This is the base class for paginated lists -->
+    <xs:complexType name="abstractCommonList">
+        <xs:annotation>
+            <xs:appinfo>
+                <jaxb:class ref="org.collectionspace.services.jaxb.AbstractCommonList"/>
+            </xs:appinfo>
+        </xs:annotation>
+    </xs:complexType>
+    
+</xs:schema>
+
diff --git a/services/group/pom.xml b/services/group/pom.xml
new file mode 100644 (file)
index 0000000..1791592
--- /dev/null
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- A comment. -->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <parent>
+        <groupId>org.collectionspace.services</groupId>
+        <artifactId>org.collectionspace.services.main</artifactId>
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+    
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group</artifactId>
+    <name>services.group</name>
+    <packaging>pom</packaging>
+
+    <modules>
+        <module>jaxb</module>
+        <module>service</module>
+        <module>3rdparty</module>
+        <module>client</module>
+    </modules>
+
+</project>
+
diff --git a/services/group/service/.classpath b/services/group/service/.classpath
new file mode 100644 (file)
index 0000000..425cd16
--- /dev/null
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<classpath>\r
+       <classpathentry kind="src" output="target/classes" path="src/main/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>\r
+       <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>\r
+       <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources"/>\r
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>\r
+       <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>\r
+       <classpathentry kind="output" path="target/classes"/>\r
+</classpath>\r
diff --git a/services/group/service/.project b/services/group/service/.project
new file mode 100644 (file)
index 0000000..7d7a7c2
--- /dev/null
@@ -0,0 +1,31 @@
+<projectDescription>\r
+  <name>org.collectionspace.services.group.service</name>\r
+  <comment>NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>\r
+  <projects>\r
+    <project>org.collectionspace.services.3rdparty.nuxeo.quote-api</project>\r
+    <project>org.collectionspace.services.client</project>\r
+    <project>org.collectionspace.services.collectionobject.jaxb</project>\r
+    <project>org.collectionspace.services.common</project>\r
+    <project>org.collectionspace.services.common-api</project>\r
+    <project>org.collectionspace.services.contact.client</project>\r
+    <project>org.collectionspace.services.contact.jaxb</project>\r
+    <project>org.collectionspace.services.hyperjaxb</project>\r
+    <project>org.collectionspace.services.jaxb</project>\r
+    <project>org.collectionspace.services.group.client</project>\r
+    <project>org.collectionspace.services.group.jaxb</project>\r
+    <project>org.collectionspace.services.person.client</project>\r
+    <project>org.collectionspace.services.person.jaxb</project>\r
+  </projects>\r
+  <buildSpec>\r
+    <buildCommand>\r
+      <name>org.eclipse.jdt.core.javabuilder</name>\r
+    </buildCommand>\r
+    <buildCommand>\r
+      <name>org.maven.ide.eclipse.maven2Builder</name>\r
+    </buildCommand>\r
+  </buildSpec>\r
+  <natures>\r
+    <nature>org.eclipse.jdt.core.javanature</nature>\r
+    <nature>org.maven.ide.eclipse.maven2Nature</nature>\r
+  </natures>\r
+</projectDescription>\r
diff --git a/services/group/service/.settings/org.maven.ide.eclipse.prefs b/services/group/service/.settings/org.maven.ide.eclipse.prefs
new file mode 100644 (file)
index 0000000..e2ce08c
--- /dev/null
@@ -0,0 +1,9 @@
+#Fri Aug 27 16:35:21 PDT 2010\r
+activeProfiles=\r
+eclipse.preferences.version=1\r
+fullBuildGoals=process-test-resources\r
+includeModules=false\r
+resolveWorkspaceProjects=true\r
+resourceFilterGoals=process-resources resources\:testResources\r
+skipCompilerPlugin=true\r
+version=1\r
diff --git a/services/group/service/pom.xml b/services/group/service/pom.xml
new file mode 100644 (file)
index 0000000..acbcc69
--- /dev/null
@@ -0,0 +1,122 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <parent>
+        <groupId>org.collectionspace.services</groupId>
+        <artifactId>org.collectionspace.services.group</artifactId>        
+        <version>1.7-SNAPSHOT</version>
+    </parent>
+    
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.collectionspace.services</groupId>
+    <artifactId>org.collectionspace.services.group.service</artifactId>
+    <name>services.group.service</name>
+    <packaging>jar</packaging>       
+
+    <dependencies>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.common</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.group.client</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.group.jaxb</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.collectionspace.services</groupId>
+            <artifactId>org.collectionspace.services.collectionobject.jaxb</artifactId> <!-- FIXME: REM - Is this really a required dependency? -->
+            <version>${project.version}</version>
+        </dependency>
+        <!-- External dependencies -->        
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>4.1</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.testng</groupId>
+            <artifactId>testng</artifactId>
+            <version>5.6</version>
+        </dependency>
+        
+      <!-- javax -->
+
+        <dependency>
+            <groupId>javax.security</groupId>
+            <artifactId>jaas</artifactId>
+            <version>1.0.01</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>dom4j</groupId>
+            <artifactId>dom4j</artifactId>
+            <version>1.6.1</version>
+            <scope>provided</scope>
+        </dependency>
+        
+        <!-- jboss -->
+
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-jaxrs</artifactId>
+            <exclusions>
+                <exclusion>
+                    <groupId>tjws</groupId>
+                    <artifactId>webserver</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-jaxb-provider</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.jboss.resteasy</groupId>
+            <artifactId>resteasy-multipart-provider</artifactId>
+        </dependency>
+        
+        <!-- nuxeo -->
+
+        <dependency>
+            <groupId>org.nuxeo.ecm.core</groupId>
+            <artifactId>nuxeo-core-api</artifactId>
+            <version>${nuxeo.core.version}</version>
+            <exclusions>
+                <exclusion>
+                    <artifactId>jboss-remoting</artifactId>
+                    <groupId>jboss</groupId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+
+        <dependency>
+            <groupId>org.restlet</groupId>
+            <artifactId>org.restlet</artifactId>
+            <version>1.0.7</version>
+        </dependency>
+        <dependency>
+            <groupId>com.noelios.restlet</groupId>
+            <artifactId>com.noelios.restlet.ext.httpclient</artifactId>
+            <version>1.0.7</version>
+        </dependency>
+        <dependency>
+            <groupId>com.noelios.restlet</groupId>
+            <artifactId>com.noelios.restlet</artifactId>
+            <version>1.0.7</version>
+        </dependency>
+    </dependencies>
+    
+    <build>
+        <finalName>collectionspace-services-group</finalName>
+    </build>
+</project>
+
diff --git a/services/group/service/profiles.xml b/services/group/service/profiles.xml
new file mode 100644 (file)
index 0000000..347b9df
--- /dev/null
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<profilesXml xmlns="http://maven.apache.org/PROFILES/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/PROFILES/1.0.0 http://maven.apache.org/xsd/profiles-1.0.0.xsd">
+</profilesXml>
\ No newline at end of file
diff --git a/services/group/service/src/main/java/org/collectionspace/services/group/GroupResource.java b/services/group/service/src/main/java/org/collectionspace/services/group/GroupResource.java
new file mode 100644 (file)
index 0000000..3f856be
--- /dev/null
@@ -0,0 +1,59 @@
+/**
+ *  This document is a part of the source code and related artifacts
+ *  for CollectionSpace, an open source collections management system
+ *  for museums and related institutions:
+
+ *  http://www.collectionspace.org
+ *  http://wiki.collectionspace.org
+
+ *  Copyright 2009 University of California at Berkeley
+
+ *  Licensed under the Educational Community License (ECL), Version 2.0.
+ *  You may not use this file except in compliance with this License.
+
+ *  You may obtain a copy of the ECL 2.0 License at
+
+ *  https://source.collectionspace.org/collection-space/LICENSE.txt
+
+ *  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.collectionspace.services.group;
+
+import org.collectionspace.services.client.GroupClient;
+import org.collectionspace.services.common.ResourceBase;
+
+import javax.ws.rs.Consumes;
+import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+
+@Path(GroupClient.SERVICE_PATH)
+@Produces({"application/xml"})
+@Consumes({"application/xml"})
+public class GroupResource extends ResourceBase {
+
+    @Override
+    public String getServiceName(){
+        return GroupClient.SERVICE_NAME;
+    }
+
+    @Override
+    protected String getVersionString() {
+       final String lastChangeRevision = "$LastChangedRevision: 2108 $";
+       return lastChangeRevision;
+    }
+
+    @Override
+    //public Class<GroupsCommon> getCommonPartClass() {
+    public Class getCommonPartClass() {
+       try {
+            return Class.forName("org.collectionspace.services.group.GroupsCommon");//.class;
+        } catch (ClassNotFoundException e){
+            return null;
+        }
+    }
+    
+}
diff --git a/services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupDocumentModelHandler.java b/services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupDocumentModelHandler.java
new file mode 100644 (file)
index 0000000..e39abbb
--- /dev/null
@@ -0,0 +1,32 @@
+/**
+ *  This document is a part of the source code and related artifacts
+ *  for CollectionSpace, an open source collections management system
+ *  for museums and related institutions:
+
+ *  http://www.collectionspace.org
+ *  http://wiki.collectionspace.org
+
+ *  Copyright 2009 University of California at Berkeley
+
+ *  Licensed under the Educational Community License (ECL), Version 2.0.
+ *  You may not use this file except in compliance with this License.
+
+ *  You may obtain a copy of the ECL 2.0 License at
+
+ *  https://source.collectionspace.org/collection-space/LICENSE.txt
+
+ *  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.collectionspace.services.group.nuxeo;
+
+import org.collectionspace.services.nuxeo.client.java.DocHandlerBase;
+import org.collectionspace.services.group.GroupsCommon;
+
+public class GroupDocumentModelHandler 
+       extends DocHandlerBase<GroupsCommon> {
+}
+
diff --git a/services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupValidatorHandler.java b/services/group/service/src/main/java/org/collectionspace/services/group/nuxeo/GroupValidatorHandler.java
new file mode 100644 (file)
index 0000000..dc2964c
--- /dev/null
@@ -0,0 +1,18 @@
+package org.collectionspace.services.group.nuxeo;
+
+import org.collectionspace.services.common.context.ServiceContext;
+import org.collectionspace.services.common.document.InvalidDocumentException;
+import org.collectionspace.services.common.document.ValidatorHandler;
+import org.collectionspace.services.common.document.DocumentHandler.Action;
+
+public class GroupValidatorHandler implements ValidatorHandler {
+
+       @Override
+       public void validate(Action action, ServiceContext ctx)
+                       throws InvalidDocumentException {
+               // TODO Auto-generated method stub
+               System.out.println("GroupValidatorHandler executed.");
+
+       }
+
+}
diff --git a/services/group/service/src/test/java/org/collectionspace/services/test/GroupServiceTest.java b/services/group/service/src/test/java/org/collectionspace/services/test/GroupServiceTest.java
new file mode 100644 (file)
index 0000000..6d15319
--- /dev/null
@@ -0,0 +1,13 @@
+package org.collectionspace.services.test;
+
+//import org.collectionspace.services.group.Group;
+//import org.collectionspace.services.group.GroupList;
+
+/**
+ * Placeholder for server-side testing of Loan Out service code.
+ * 
+ * @version $Revision: 2108 $
+ */
+public class GroupServiceTest {
+       //empty
+}
diff --git a/services/group/service/src/test/resources/log4j.xml b/services/group/service/src/test/resources/log4j.xml
new file mode 100644 (file)
index 0000000..52121cb
--- /dev/null
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+
+       <appender name="console" class="org.apache.log4j.ConsoleAppender">
+               <param name="Target" value="System.out" />
+               <layout class="org.apache.log4j.TTCCLayout">
+                       <param name="DateFormat" value="ISO8601" />
+               </layout>
+       </appender>
+
+
+       <appender name="unit-tests"
+               class="org.apache.log4j.RollingFileAppender">
+               <param name="File" value="./target/unit-tests.log" />
+               <param name="MaxFileSize" value="10240KB" />
+               <param name="MaxBackupIndex" value="6" />
+               <layout class="org.apache.log4j.TTCCLayout">
+                       <param name="DateFormat" value="ISO8601" />
+               </layout>
+       </appender>
+
+       <logger name="org.apache.commons.httpclient" additivity="false">
+               <level value="warn" />
+               <appender-ref ref="console" />
+               <appender-ref ref="unit-tests" />
+       </logger>
+
+       <logger name="httpclient.wire" additivity="false">
+               <level value="info" />
+               <appender-ref ref="console" />
+               <appender-ref ref="unit-tests" />
+       </logger>
+
+       <root>
+               <priority value="debug" />
+               <appender-ref ref="console" />
+               <appender-ref ref="unit-tests" />
+       </root>
+
+</log4j:configuration>
+
+
+
+