package org.collectionspace.services.common.vocabulary.nuxeo;
import org.collectionspace.services.client.AuthorityClient;
-import org.collectionspace.services.client.CollectionSpaceClient;
import org.collectionspace.services.client.IQueryManager;
import org.collectionspace.services.client.PoxPayloadIn;
import org.collectionspace.services.client.PoxPayloadOut;
-import org.collectionspace.services.common.api.CommonAPI;
import org.collectionspace.services.common.api.RefName;
import org.collectionspace.services.common.api.Tools;
import org.collectionspace.services.common.authorityref.AuthorityRefDocList;
import org.collectionspace.services.common.document.DocumentException;
import org.collectionspace.services.common.document.DocumentFilter;
import org.collectionspace.services.common.document.DocumentWrapper;
-import org.collectionspace.services.common.document.DocumentWrapperImpl;
import org.collectionspace.services.common.vocabulary.AuthorityJAXBSchema;
import org.collectionspace.services.common.vocabulary.AuthorityItemJAXBSchema;
import org.collectionspace.services.common.vocabulary.RefNameServiceUtils;
// for general logic.
boolean hasDisplayName = false;
boolean hasShortId = false;
- boolean hasRefName = false;
boolean hasTermStatus = false;
for (int i = 0; i < nFields; i++) {
ListResultField field = list.get(i);
hasDisplayName = true;
} else if (AuthorityItemJAXBSchema.SHORT_IDENTIFIER.equals(elName)) {
hasShortId = true;
- } else if (AuthorityItemJAXBSchema.REF_NAME.equals(elName)) {
- hasRefName = true;
} else if (AuthorityItemJAXBSchema.TERM_STATUS.equals(elName)) {
hasTermStatus = true;
}
field.setXpath(AuthorityItemJAXBSchema.SHORT_IDENTIFIER);
list.add(field);
}
- if (!hasRefName) {
- field = new ListResultField();
- field.setElement(AuthorityItemJAXBSchema.REF_NAME);
- field.setXpath(AuthorityItemJAXBSchema.REF_NAME);
- list.add(field);
- }
if (!hasTermStatus) {
field = getListResultsTermStatusField();
list.add(field);
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>
<service:element>displayName</service:element>
<service:xpath>displayName</service:xpath>
</service:ListResultField>
- <service:ListResultField>
- <service:element>refName</service:element>
- <service:xpath>refName</service:xpath>
- </service:ListResultField>
<service:ListResultField>
<service:element>shortIdentifier</service:element>
<service:xpath>shortIdentifier</service:xpath>