final String SERVICE_PATH_COMPONENT = "acquisitions";
private String knownResourceId = null;
- //FIXME: Remove this method once ALL the services use "_common" instead of "-common"
- public String getCommonPartName() {
- return getServicePathComponent() + "_common";
- }
-
// ---------------------------------------------------------------
// CRUD tests : CREATE tests
// ---------------------------------------------------------------
verbose("readList: list-item[" + i + "] csid=" +
item.getCsid());
verbose("readList: list-item[" + i + "] objectNumber=" +
- item.getAccessiondate());
+ item.getAccessionDate());
verbose("readList: list-item[" + i + "] URI=" +
item.getUri());
i++;
*\r
*/\r
public interface AcquisitionJAXBSchema {\r
- final static String ACCESSIONDATE = "accessiondate";\r
+ final static String ACCESSIONDATE = "accessionDate";\r
}\r
\r
\r
<xs:element name="acquisition-list-item" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
- <xs:element name="accessiondate" type="xs:string"
+ <xs:element name="accessionDate" type="xs:string"
minOccurs="1" />
<!-- uri to retrive acquisition details -->
<xs:element name="uri" type="xs:anyURI"
while(iter.hasNext()){
DocumentModel docModel = iter.next();
AcquisitionListItem listItem = new AcquisitionListItem();
- listItem.setAccessiondate((String) docModel.getProperty(getServiceContext().getCommonPartLabel(),
+ listItem.setAccessionDate((String) docModel.getProperty(getServiceContext().getCommonPartLabel(),
AcquisitionJAXBSchema.ACCESSIONDATE));
//need fully qualified context for URI
String id = docModel.getId();
<name>services.client</name>\r
\r
<dependencies>\r
+ <dependency>\r
+ <groupId>org.collectionspace.services</groupId>\r
+ <artifactId>org.collectionspace.services.common</artifactId>\r
+ <version>1.0</version>\r
+ </dependency>\r
<dependency>\r
<groupId>org.slf4j</groupId>\r
<artifactId>slf4j-api</artifactId>\r
import javax.xml.bind.Unmarshaller;
import org.collectionspace.services.client.TestServiceClient;
+import org.collectionspace.services.common.context.ServiceContext;
import org.jboss.resteasy.client.ClientRequest;
import org.jboss.resteasy.client.ClientResponse;
@Override
public String getCommonPartName() {
- return getServicePathComponent() + "-common";
+ return getServicePathComponent() + ServiceContext.PART_LABEL_SEPERATOR +
+ ServiceContext.PART_COMMON_LABEL;
}
// ---------------------------------------------------------------
<?xml version="1.0"?>
<component name="org.collectionspace.collectionobject.coreTypes">
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="collectionobjects-common" prefix="collectionobjects-common" src="schemas/collectionobjects-common.xsd"/>
- <schema name="collectionobjects-naturalhistory" prefix="collectionobjects-naturalhistory" src="schemas/collectionobjects-naturalhistory.xsd"/>
+ <schema name="collectionobjects_common" prefix="collectionobjects_common" src="schemas/collectionobjects_common.xsd"/>
+ <schema name="collectionobjects_naturalhistory" prefix="collectionobjects_naturalhistory" src="schemas/collectionobjects_naturalhistory.xsd"/>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
<doctype name="CollectionObject" extends="Document">
<schema name="common"/>
<schema name="dublincore"/>
- <schema name="collectionobjects-common"/>
- <schema name="collectionobjects-naturalhistory"/>
+ <schema name="collectionobjects_common"/>
+ <schema name="collectionobjects_naturalhistory"/>
</doctype>
</extension>
</component>
<rows>
<row><widget>objectNumber</widget></row>
<row><widget>otherNumber</widget></row>
+ <row><widget>otherNumberType</widget></row>
<row><widget>briefDescription</widget></row>
<row><widget>comments</widget></row>
<row><widget>distFeatures</widget></row>
+ <row><widget>numberOfObjects</widget></row>
+
<row><widget>objectName</widget></row>
+ <row><widget>objectNameCurrency</widget></row>
+ <row><widget>objectNameNote</widget></row>
+ <row><widget>objectNameSystem</widget></row>
+ <row><widget>objectNameType</widget></row>
+ <row><widget>objectNameLanguage</widget></row>
+
<row><widget>responsibleDept</widget></row>
<row><widget>title</widget></row>
+ <row><widget>objectTitleLanguage</widget></row>
+ <row><widget>titleTranslation</widget></row>
+ <row><widget>titleType</widget></row>
</rows>
<widget name="objectNumber" type="text">
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">objectNumber</field>
+ <field schema="collectionobjects_common">objectNumber</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">otherNumber</field>
+ <field schema="collectionobjects_common">otherNumber</field>
+ </fields>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
+ </properties>
+ </widget>
+
+ <widget name="otherNumberType" type="text">
+ <labels>
+ <label mode="any">otherNumberType</label>
+ </labels>
+ <translated>true</translated>
+ <fields>
+ <field schema="collectionobjects_common">otherNumberType</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">briefDescription</field>
+ <field schema="collectionobjects_common">briefDescription</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">comments</field>
+ <field schema="collectionobjects_common">comments</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">distFeatures</field>
+ <field schema="collectionobjects_common">distFeatures</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">objectName</field>
+ <field schema="collectionobjects_common">objectName</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">responsibleDept</field>
+ <field schema="collectionobjects_common">responsibleDept</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="collectionobject">title</field>
+ <field schema="collectionobjects_common">title</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r
-<xs:schema \r
- xmlns:xs="http://www.w3.org/2001/XMLSchema"\r
- xmlns:ns="http://collectionspace.org/collectionobject/"\r
- xmlns="http://collectionspace.org/collectionobject/"\r
- targetNamespace="http://collectionspace.org/collectionobject/"\r
- version="0.1">\r
-\r
- <xs:element name="objectNumber" type="xs:string"/>\r
- <xs:element name="otherNumber" type="xs:string"/>\r
- <xs:element name="briefDescription" type="xs:string"/>\r
- <xs:element name="comments" type="xs:string"/>\r
- <xs:element name="distFeatures" type="xs:string"/>\r
- <xs:element name="objectName" type="xs:string"/>\r
- <xs:element name="responsibleDept" type="xs:string"/>\r
- <xs:element name="title" type="xs:string"/>\r
- \r
-</xs:schema>\r
--- /dev/null
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r
+<xs:schema \r
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"\r
+ xmlns:ns="http://collectionspace.org/collectionobject/"\r
+ xmlns="http://collectionspace.org/collectionobject/"\r
+ targetNamespace="http://collectionspace.org/collectionobject/"\r
+ version="0.1">\r
+\r
+ <!-- Object identification information -->\r
+ <xs:element name="objectNumber" type="xs:string"/>\r
+ <xs:element name="otherNumber" type="xs:string"/>\r
+ <xs:element name="otherNumberType" type="xs:string"/>\r
+ <xs:element name="briefDescription" type="xs:string"/>\r
+ <xs:element name="comments" type="xs:string"/>\r
+ <xs:element name="distFeatures" type="xs:string"/>\r
+ <xs:element name="numberOfObjects" type="xs:string"/>\r
+ <xs:element name="objectName" type="xs:string"/>\r
+ <xs:element name="objectNameCurrency" type="xs:string"/>\r
+ <xs:element name="objectNameNote" type="xs:string"/>\r
+ <xs:element name="objectNameSystem" type="xs:string"/>\r
+ <xs:element name="objectNameType" type="xs:string"/>\r
+ <xs:element name="objectNameLanguage" type="xs:string"/>\r
+ <xs:element name="responsibleDept" type="xs:string"/>\r
+ <xs:element name="title" type="xs:string"/>\r
+ <xs:element name="objectTitleLanguage" type="xs:string"/>\r
+ <xs:element name="titleTranslation" type="xs:string"/>\r
+ <xs:element name="titleType" type="xs:string"/>\r
+ \r
+ <!-- Object description information -->\r
+ <xs:element name="age" type="xs:string" />\r
+ <xs:element name="ageQualifier" type="xs:string" />\r
+ <xs:element name="ageUnit" type="xs:string" />\r
+ <xs:element name="color" type="xs:string" />\r
+\r
+ <!-- Object description Content information --> \r
+ <xs:element name="contentActivity" type="xs:string" />\r
+ <xs:element name="contentConcept" type="xs:string" />\r
+ <xs:element name="contentDate" type="xs:string" />\r
+ <xs:element name="contentDescription" type="xs:string" />\r
+ <xs:element name="contentEventName" type="xs:string" />\r
+ <xs:element name="contentEventNameType" type="xs:string" />\r
+ <xs:element name="contentNote" type="xs:string" />\r
+ <xs:element name="contentLanguage" type="xs:string" />\r
+ <xs:element name="contentObject" type="xs:string" />\r
+ <xs:element name="contentObjectType" type="xs:string" />\r
+ <xs:element name="contentOrganization" type="xs:string" />\r
+ <xs:element name="contentOther" type="xs:string" />\r
+ <xs:element name="contentOtherType" type="xs:string" />\r
+ <xs:element name="contentPeople" type="xs:string" />\r
+ <xs:element name="contentPerson" type="xs:string" />\r
+ <xs:element name="contentPlace" type="xs:string" />\r
+ <xs:element name="contentPosition" type="xs:string" />\r
+ <xs:element name="copyNumber" type="xs:string" />\r
+\r
+ <!-- Object description Dimension information -->\r
+ <xs:element name="dimension" type="xs:string" />\r
+ <xs:element name="dimensionMeasuredPart" type="xs:string" />\r
+ <xs:element name="dimensionMeasurementUnit" type="xs:string" />\r
+ <xs:element name="dimensionValue" type="xs:string" />\r
+ <xs:element name="dimensionValueDate" type="xs:string" />\r
+ <xs:element name="dimensionValueQualifier" type="xs:string" />\r
+ \r
+ <xs:element name="editionNumber" type="xs:string" />\r
+ <xs:element name="form" type="xs:string" />\r
+\r
+ <!-- Object description Inscription content information -->\r
+ <xs:element name="inscriptionContent" type="xs:string" />\r
+ <xs:element name="inscriber" type="xs:string" />\r
+ <xs:element name="inscriptionDate" type="xs:string" />\r
+ <xs:element name="inscriptionInterpretation" type="xs:string" />\r
+ <xs:element name="inscriptionLanguage" type="xs:string" />\r
+ <xs:element name="inscriptionMethod" type="xs:string" />\r
+ <xs:element name="inscriptionPosition" type="xs:string" />\r
+ <xs:element name="inscriptionScript" type="xs:string" />\r
+ <xs:element name="inscriptionTranslation" type="xs:string" />\r
+ <xs:element name="inscriptionTransliteration" type="xs:string" />\r
+ <xs:element name="inscriptionType" type="xs:string" />\r
+ \r
+\r
+ <!-- Object description Inscription description information -->\r
+ <xs:element name="inscriptionDescription" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionInscriber" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionDate" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionInterpretation" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionMethod" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionPosition" type="xs:string" />\r
+ <xs:element name="inscriptionDescriptionType" type="xs:string" />\r
+\r
+ <!-- Object description Material information -->\r
+ <xs:element name="material" type="xs:string" />\r
+ <xs:element name="materialComponent" type="xs:string" />\r
+ <xs:element name="materialComponentNote" type="xs:string" />\r
+ <xs:element name="materialName" type="xs:string" />\r
+ <xs:element name="materialSource" type="xs:string" />\r
+\r
+ <!-- Misc Object description information -->\r
+ <xs:element name="objectStatus" type="xs:string" />\r
+ <xs:element name="phase" type="xs:string" />\r
+ <xs:element name="physicalDescription" type="xs:string" />\r
+ <xs:element name="sex" type="xs:string" />\r
+ <xs:element name="style" type="xs:string" />\r
+ <xs:element name="technicalAttribute" type="xs:string" />\r
+ <xs:element name="technicalAttributeMeasurement" type="xs:string" />\r
+ <xs:element name="technicalAttributeMeasurementUnit" type="xs:string" />\r
+ <xs:element name="objectComponentName" type="xs:string" />\r
+ <xs:element name="objectComponentInformation" type="xs:string" />\r
+ \r
+ <!-- Object description Date information -->\r
+ <xs:element name="dateAssociation" type="xs:string" />\r
+ <xs:element name="dateEarliestSingle" type="xs:string" />\r
+ <xs:element name="dateEarliestSingleCertainty" type="xs:string" />\r
+ <xs:element name="dateEarlierstSingleQualifier" type="xs:string" />\r
+ <xs:element name="dateLatest" type="xs:string" />\r
+ <xs:element name="dateLatestCertainty" type="xs:string" />\r
+ <xs:element name="dateLatestQualifier" type="xs:string" />\r
+ <xs:element name="datePeriod" type="xs:string" />\r
+ <xs:element name="dateText" type="xs:string" />\r
+ \r
+</xs:schema>\r
final String SERVICE_PATH_COMPONENT = "collectionobjects";
private String knownResourceId = null;
+ //FIXME: Remove this method once ALL the services use "_common" instead of "-common"
+ public String getCommonPartName() {
+ return getServicePathComponent() + "_common";
+ }
+
// ---------------------------------------------------------------
// CRUD tests : CREATE tests
// ---------------------------------------------------------------
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<xs:schema
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:ns="http://collectionspace.org/servics/collectionobject"
- xmlns="http://collectionspace.org/services/collectionobject"
- targetNamespace="http://collectionspace.org/services/collectionobject"
- version="0.1"
->
-
-<!-- avoid XmlRootElement nightnmare, see http://weblogs.java.net/blog/kohsuke/archive/2006/03/why_does_jaxb_p.html-->
-
- <!-- collectionobjects-common -->
- <!-- convention: <servicename>-common -->
- <xs:element name="collectionobjects-common">
- <xs:complexType>
- <xs:sequence>
- <xs:element name="csid" type="xs:string" />
- <xs:element name="objectNumber" type="xs:string"/>
- <xs:element name="otherNumber" type="xs:string"/>
- <xs:element name="briefDescription" type="xs:string"/>
- <xs:element name="comments" type="xs:string"/>
- <xs:element name="distFeatures" type="xs:string"/>
- <xs:element name="objectName" type="xs:string"/>
- <xs:element name="responsibleDept" type="xs:string"/>
- <xs:element name="title" type="xs:string"/>
- </xs:sequence>
- </xs:complexType>
- </xs:element>
-
- <!-- collection objects as in nuxeo repository -->
- <xs:element name="collectionobjects-common-list">
- <xs:complexType>
- <xs:sequence>
- <xs:element name="collection-object-list-item" maxOccurs="unbounded">
- <xs:complexType>
- <xs:sequence>
- <xs:element name="objectNumber" type="xs:string"
- minOccurs="1" />
- <!-- uri to retrive collection object details -->
- <xs:element name="uri" type="xs:anyURI"
- minOccurs="1" />
- <xs:element name="csid" type="xs:string"
- minOccurs="1" />
- </xs:sequence>
- </xs:complexType>
- </xs:element>
- </xs:sequence>
- </xs:complexType>
- </xs:element>
-
-</xs:schema>
-
--- /dev/null
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<xs:schema
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ xmlns:ns="http://collectionspace.org/servics/collectionobject"
+ xmlns="http://collectionspace.org/services/collectionobject"
+ targetNamespace="http://collectionspace.org/services/collectionobject"
+ version="0.1"
+>
+
+<!-- avoid XmlRootElement nightnmare, see http://weblogs.java.net/blog/kohsuke/archive/2006/03/why_does_jaxb_p.html-->
+
+ <!-- collectionobjects-common -->
+ <!-- convention: <servicename>-common -->
+ <xs:element name="collectionobjects_common">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="csid" type="xs:string" />
+
+ <!-- Object identification information -->
+ <xs:element name="objectNumber" type="xs:string"/>
+ <xs:element name="otherNumber" type="xs:string"/>
+ <xs:element name="otherNumberType" type="xs:string"/>
+ <xs:element name="briefDescription" type="xs:string"/>
+ <xs:element name="comments" type="xs:string"/>
+ <xs:element name="distFeatures" type="xs:string"/>
+ <xs:element name="numberOfObjects" type="xs:string"/>
+ <xs:element name="objectName" type="xs:string"/>
+ <xs:element name="objectNameCurrency" type="xs:string"/>
+ <xs:element name="objectNameNote" type="xs:string"/>
+ <xs:element name="objectNameSystem" type="xs:string"/>
+ <xs:element name="objectNameType" type="xs:string"/>
+ <xs:element name="objectNameLanguage" type="xs:string"/>
+ <xs:element name="responsibleDept" type="xs:string"/>
+ <xs:element name="title" type="xs:string"/>
+ <xs:element name="objectTitleLanguage" type="xs:string"/>
+ <xs:element name="titleTranslation" type="xs:string"/>
+ <xs:element name="titleType" type="xs:string"/>
+
+ <!-- Object description information -->
+ <xs:element name="age" type="xs:string" />
+ <xs:element name="ageQualifier" type="xs:string" />
+ <xs:element name="ageUnit" type="xs:string" />
+ <xs:element name="color" type="xs:string" />
+
+ <!-- Object description Content information -->
+ <xs:element name="contentActivity" type="xs:string" />
+ <xs:element name="contentConcept" type="xs:string" />
+ <xs:element name="contentDate" type="xs:string" />
+ <xs:element name="contentDescription" type="xs:string" />
+ <xs:element name="contentEventName" type="xs:string" />
+ <xs:element name="contentEventNameType" type="xs:string" />
+ <xs:element name="contentNote" type="xs:string" />
+ <xs:element name="contentLanguage" type="xs:string" />
+ <xs:element name="contentObject" type="xs:string" />
+ <xs:element name="contentObjectType" type="xs:string" />
+ <xs:element name="contentOrganization" type="xs:string" />
+ <xs:element name="contentOther" type="xs:string" />
+ <xs:element name="contentOtherType" type="xs:string" />
+ <xs:element name="contentPeople" type="xs:string" />
+ <xs:element name="contentPerson" type="xs:string" />
+ <xs:element name="contentPlace" type="xs:string" />
+ <xs:element name="contentPosition" type="xs:string" />
+ <xs:element name="copyNumber" type="xs:string" />
+
+ <!-- Object description Dimension information -->
+ <xs:element name="dimension" type="xs:string" />
+ <xs:element name="dimensionMeasuredPart" type="xs:string" />
+ <xs:element name="dimensionMeasurementUnit" type="xs:string" />
+ <xs:element name="dimensionValue" type="xs:string" />
+ <xs:element name="dimensionValueDate" type="xs:string" />
+ <xs:element name="dimensionValueQualifier" type="xs:string" />
+
+ <xs:element name="editionNumber" type="xs:string" />
+ <xs:element name="form" type="xs:string" />
+
+ <!-- Object description Inscription content information -->
+ <xs:element name="inscriptionContent" type="xs:string" />
+ <xs:element name="inscriber" type="xs:string" />
+ <xs:element name="inscriptionDate" type="xs:string" />
+ <xs:element name="inscriptionInterpretation" type="xs:string" />
+ <xs:element name="inscriptionLanguage" type="xs:string" />
+ <xs:element name="inscriptionMethod" type="xs:string" />
+ <xs:element name="inscriptionPosition" type="xs:string" />
+ <xs:element name="inscriptionScript" type="xs:string" />
+ <xs:element name="inscriptionTranslation" type="xs:string" />
+ <xs:element name="inscriptionTransliteration" type="xs:string" />
+ <xs:element name="inscriptionType" type="xs:string" />
+
+
+ <!-- Object description Inscription description information -->
+ <xs:element name="inscriptionDescription" type="xs:string" />
+ <xs:element name="inscriptionDescriptionInscriber" type="xs:string" />
+ <xs:element name="inscriptionDescriptionDate" type="xs:string" />
+ <xs:element name="inscriptionDescriptionInterpretation" type="xs:string" />
+ <xs:element name="inscriptionDescriptionMethod" type="xs:string" />
+ <xs:element name="inscriptionDescriptionPosition" type="xs:string" />
+ <xs:element name="inscriptionDescriptionType" type="xs:string" />
+
+ <!-- Object description Material information -->
+ <xs:element name="material" type="xs:string" />
+ <xs:element name="materialComponent" type="xs:string" />
+ <xs:element name="materialComponentNote" type="xs:string" />
+ <xs:element name="materialName" type="xs:string" />
+ <xs:element name="materialSource" type="xs:string" />
+
+ <!-- Misc Object description information -->
+ <xs:element name="objectStatus" type="xs:string" />
+ <xs:element name="phase" type="xs:string" />
+ <xs:element name="physicalDescription" type="xs:string" />
+ <xs:element name="sex" type="xs:string" />
+ <xs:element name="style" type="xs:string" />
+ <xs:element name="technicalAttribute" type="xs:string" />
+ <xs:element name="technicalAttributeMeasurement" type="xs:string" />
+ <xs:element name="technicalAttributeMeasurementUnit" type="xs:string" />
+ <xs:element name="objectComponentName" type="xs:string" />
+ <xs:element name="objectComponentInformation" type="xs:string" />
+
+ <!-- Object description Date information -->
+ <xs:element name="dateAssociation" type="xs:string" />
+ <xs:element name="dateEarliestSingle" type="xs:string" />
+ <xs:element name="dateEarliestSingleCertainty" type="xs:string" />
+ <xs:element name="dateEarlierstSingleQualifier" type="xs:string" />
+ <xs:element name="dateLatest" type="xs:string" />
+ <xs:element name="dateLatestCertainty" type="xs:string" />
+ <xs:element name="dateLatestQualifier" type="xs:string" />
+ <xs:element name="datePeriod" type="xs:string" />
+ <xs:element name="dateText" type="xs:string" />
+
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- collection objects as in nuxeo repository -->
+ <xs:element name="collectionobjects-common-list">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="collection-object-list-item" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="objectNumber" type="xs:string"
+ minOccurs="1" />
+ <!-- uri to retrive collection object details -->
+ <xs:element name="uri" type="xs:anyURI"
+ minOccurs="1" />
+ <xs:element name="csid" type="xs:string"
+ minOccurs="1" />
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+
+</xs:schema>
+
</service:part>
<service:part id="1" control_group="Managed"
versionable="true" auditable="false"
- label="collectionobjects-common" updated="" order="1">
+ label="collectionobjects_common" updated="" order="1">
<service:content contentType="application/xml">
<service:xmlContent
namespaceURI="http://collectionspace.org/services/collectionobject"
- schemaLocation="http://collectionspace.org/services/collectionobject http://services.collectionspace.org/collectionobject/collectionobjects-common.xsd">
+ schemaLocation="http://collectionspace.org/services/collectionobject http://services.collectionspace.org/collectionobject/collectionobjects_common.xsd">
</service:xmlContent>
</service:content>
</service:part>
<service:part id="2" control_group="Managed"
versionable="true" auditable="false"
- label="collectionobjects-naturalhistory" updated="" order="2">
+ label="collectionobjects_naturalhistory" updated="" order="2">
<service:content contentType="application/xml">
<service:xmlContent
namespaceURI="http://collectionspace.org/services/collectionobject/domain/naturalhistory"
- schemaLocation="http://collectionspace.org/services/collectionobject/domain/naturalhistory http://collectionspace.org/services/collectionobject/domain/collectionobjects-naturalhistory.xsd">
+ schemaLocation="http://collectionspace.org/services/collectionobject/domain/naturalhistory http://collectionspace.org/services/collectionobject/domain/collectionobjects_naturalhistory.xsd">
</service:xmlContent>
</service:content>
</service:part>
</service:part>
<service:part id="1" control_group="Managed"
versionable="true" auditable="false"
- label="intakes-common" updated="" order="1">
+ label="intakes_common" updated="" order="1">
<service:content contentType="application/xml">
<service:xmlContent
namespaceURI="http://collectionspace.org/services/intake"
- schemaLocation="http://collectionspace.org/services/intake http://services.collectionspace.org/intake/intakes-common.xsd">
+ schemaLocation="http://collectionspace.org/services/intake http://services.collectionspace.org/intake/intakes_common.xsd">
</service:xmlContent>
</service:content>
</service:part>
</service:part>
<service:part id="1" control_group="Managed"
versionable="true" auditable="false"
- label="vocabularies-common" updated="" order="1">
+ label="vocabularies_common" updated="" order="1">
<service:content contentType="application/xml">
<service:xmlContent
namespaceURI="http://collectionspace.org/services/vocabulary"
- schemaLocation="http://collectionspace.org/services/vocabulary http://services.collectionspace.org/vocabulary/vocabularies-common.xsd">
+ schemaLocation="http://collectionspace.org/services/vocabulary http://services.collectionspace.org/vocabulary/vocabularies_common.xsd">
</service:xmlContent>
</service:content>
</service:part>
</service:part>
<service:part id="1" control_group="Managed"
versionable="true" auditable="false"
- label="relations-common" updated="" order="1">
+ label="relations_common" updated="" order="1">
<service:content contentType="application/xml">
<service:xmlContent
namespaceURI="http://collectionspace.org/services/relation"
- schemaLocation="http://collectionspace.org/services/relation http://services.collectionspace.org/relation/relations-common.xsd">
+ schemaLocation="http://collectionspace.org/services/relation http://services.collectionspace.org/relation/relations_common.xsd">
</service:xmlContent>
</service:content>
</service:part>
Map<String, ObjectPartType> objectPartMap = new HashMap<String, ObjectPartType>();
private ServiceBindingType serviceBinding;
private TenantBindingType tenantBinding;
-
+
public AbstractServiceContext(String serviceName) {
TenantBindingConfigReader tReader =
ServiceMain.getInstance().getTenantBindingConfigReader();
*/
@Override
public String getCommonPartLabel() {
- return getServiceName().toLowerCase() + "-common";
+ return getServiceName().toLowerCase() + PART_LABEL_SEPERATOR + PART_COMMON_LABEL;
}
@Override
*/
public interface ServiceContext<T1, T2> {
+ /**
+ * The charactor used to separtate the words in a part label
+ */
+ public static final String PART_LABEL_SEPERATOR = "_";
+ public static final String PART_COMMON_LABEL = "common";
+
/**
* getTenantId get tenant id
* @return tenant id
StringTokenizer tkz = new StringTokenizer(qProp, ":");
if(tkz.countTokens() != 2){
String msg = "Property must be in the form xxx:yyy, " +
- "e.g. collectionobjects-common:objectNumber";
+ "e.g. collectionobjects_common:objectNumber";
logger.error(msg);
throw new IllegalArgumentException(msg);
}
>\r
\r
<!-- Relation -->\r
- <xs:element name="relations-common">\r
+ <xs:element name="relations_common">\r
<xs:complexType>\r
<xs:sequence>\r
<xs:element name="csid" type="xs:string" /> \r
<?xml version="1.0"?>
<component name="org.collectionspace.intake.coreTypes">
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="intakes-common" prefix="intakes-common" src="schemas/intakes-common.xsd"/>
+ <schema name="intakes_common" prefix="intakes_common" src="schemas/intakes_common.xsd"/>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
<doctype name="Intake" extends="Document">
<schema name="common"/>
<schema name="dublincore"/>
- <schema name="intakes-common"/>
+ <schema name="intakes_common"/>
</doctype>
</extension>
</component>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">currentOwner</field>
+ <field schema="intakes_common">currentOwner</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">depositor</field>
+ <field schema="intakes_common">depositor</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">depositorsRequirements</field>
+ <field schema="intakes_common">depositorsRequirements</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">entryDate</field>
+ <field schema="intakes_common">entryDate</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">entryMethod</field>
+ <field schema="intakes_common">entryMethod</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">entryNote</field>
+ <field schema="intakes_common">entryNote</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">entryNumber</field>
+ <field schema="intakes_common">entryNumber</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">entryReason</field>
+ <field schema="intakes_common">entryReason</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">packingNote</field>
+ <field schema="intakes_common">packingNote</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="intake">returnDate</field>
+ <field schema="intakes_common">returnDate</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
<!-- See http://wiki.collectionspace.org/display/collectionspace/Intake+Schema -->
<!-- intake -->
- <xs:element name="intakes-common">
+ <xs:element name="intakes_common">
<xs:complexType>
<xs:sequence>
<xs:element name="csid" type="xs:string" />
-->
<component name="org.collectionspace.relation.coreTypes">
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="relations-common" prefix="relations-common" src="schemas/relations-common.xsd"/>
+ <schema name="relations_common" prefix="relations_common" src="schemas/relations_common.xsd"/>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
<doctype name="Relation" extends="Document">
<schema name="common"/>
<schema name="dublincore"/>
- <schema name="relations-common"/>
+ <schema name="relations_common"/>
</doctype>
</extension>
</component>
<layout name="relation">
<templates>
<template mode="any">/layouts/layout_default_template.xhtml</template>
- </templates>
-
+ </templates>
<rows>
- <row>
- <widget>relationtype</widget>
- </row>
+ <row><widget>relationshipType</widget></row>
+ <row><widget>documentId1</widget></row>
+ <row><widget>documentType1</widget></row>
+ <row><widget>documentId2</widget></row>
+ <row><widget>documentType2</widget></row>
</rows>
- <widget name="relationtype" type="template">
+ <widget name="relationshipType" type="text">
+ <labels>
+ <label mode="any">Relationship Type</label>
+ </labels>
+ <translated>true</translated>
<fields>
- <field>rel:relationtype</field>
+ <field schema="relations_common">relationshipType</field>
</fields>
- <properties mode="any">
- <property name="template">
- /widgets/complex_widget_template.xhtml
- </property>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
+ </properties>
+ </widget>
+
+ <widget name="documentId1" type="text">
+ <labels>
+ <label mode="any">Document ID 1</label>
+ </labels>
+ <translated>true</translated>
+ <fields>
+ <field schema="relations_common">documentId1</field>
+ </fields>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
+ </properties>
+ </widget>
+
+ <widget name="documentType1" type="text">
+ <labels>
+ <label mode="any">Document Type 1</label>
+ </labels>
+ <translated>true</translated>
+ <fields>
+ <field schema="relations_common">documentType1</field>
+ </fields>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
</properties>
-
- <subWidgets>
-
- <widget name="documentId1" type="text">
- <labels>
- <label mode="any">Document ID 1</label>
- </labels>
- <translated>true</translated>
- <fields>
- <field>documentId1</field>
- </fields>
- <properties widgetMode="edit">
- <property name="styleClass">dataInputText</property>
- </properties>
- </widget>
-
- <widget name="documentType1" type="text">
- <labels>
- <label mode="any">Document Type 1</label>
- </labels>
- <translated>true</translated>
- <fields>
- <field>documentType1</field>
- </fields>
- <properties widgetMode="edit">
- <property name="styleClass">dataInputText</property>
- </properties>
- </widget>
-
- <widget name="documentId2" type="text">
- <labels>
- <label mode="any">Document ID 2</label>
- </labels>
- <translated>true</translated>
- <fields>
- <field>documentId2</field>
- </fields>
- <properties widgetMode="edit">
- <property name="styleClass">dataInputText</property>
- </properties>
- </widget>
-
- <widget name="documentType2" type="text">
- <labels>
- <label mode="any">Document Type 2</label>
- </labels>
- <translated>true</translated>
- <fields>
- <field>documentType2</field>
- </fields>
- <properties widgetMode="edit">
- <property name="styleClass">dataInputText</property>
- </properties>
- </widget>
-
- </subWidgets>
</widget>
+ <widget name="documentId2" type="text">
+ <labels>
+ <label mode="any">Document ID 2</label>
+ </labels>
+ <translated>true</translated>
+ <fields>
+ <field schema="relations_common">documentId2</field>
+ </fields>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
+ </properties>
+ </widget>
+
+ <widget name="documentType2" type="text">
+ <labels>
+ <label mode="any">Document Type 2</label>
+ </labels>
+ <translated>true</translated>
+ <fields>
+ <field schema="relations_common">documentType2</field>
+ </fields>
+ <properties widgetMode="edit">
+ <property name="styleClass">dataInputText</property>
+ </properties>
+ </widget>
+
</layout>
</extension>
</component>
<?xml version="1.0"?>
<component name="org.collectionspace.vocabulary.coreTypes">
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="vocabularies-common" prefix="vocabularies-common" src="schemas/vocabularies-common.xsd"/>
+ <schema name="vocabularies_common" prefix="vocabularies_common" src="schemas/vocabularies_common.xsd"/>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="schema">
- <schema name="vocabularyitems-common" prefix="vocabularyitems-common" src="schemas/vocabularyitems-common.xsd"/>
+ <schema name="vocabularyitems_common" prefix="vocabularyitems_common" src="schemas/vocabularyitems_common.xsd"/>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
<doctype name="Vocabulary" extends="Document">
<schema name="common"/>
<schema name="dublincore"/>
- <schema name="vocabularies-common"/>
+ <schema name="vocabularies_common"/>
</doctype>
</extension>
<extension target="org.nuxeo.ecm.core.schema.TypeService" point="doctype">
<doctype name="VocabularyItem" extends="Document">
<schema name="common"/>
<schema name="dublincore"/>
- <schema name="vocabularyitems-common"/>
+ <schema name="vocabularyitems_common"/>
</doctype>
</extension>
</component>
</labels>
<translated>true</translated>
<fields>
- <field schema="vocabulary">displayName</field>
+ <field schema="vocabularies_common">displayName</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="vocabulary">vocabType</field>
+ <field schema="vocabularies_common">vocabType</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="vocabularyitem">displayName</field>
+ <field schema="vocabularyitems_common">displayName</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
</labels>
<translated>true</translated>
<fields>
- <field schema="vocabularyitem">inVocabulary</field>
+ <field schema="vocabularyitems_common">inVocabulary</field>
</fields>
<properties widgetMode="edit">
<property name="styleClass">dataInputText</property>
<!-- See http://wiki.collectionspace.org/display/collectionspace/Vocabulary+Schema -->
<!-- Vocabulary -->
- <xs:element name="vocabularies-common">
+ <xs:element name="vocabularies_common">
<xs:complexType>
<xs:sequence>
<!-- Common identifier -->