2 * This document is a part of the source code and related artifacts for
3 * CollectionSpace, an open source collections management system for museums and
4 * related institutions:
6 * http://www.collectionspace.org http://wiki.collectionspace.org
8 * Copyright © 2009 The Regents of the University of California
10 * Licensed under the Educational Community License (ECL), Version 2.0. You may
11 * not use this file except in compliance with this License.
13 * You may obtain a copy of the ECL 2.0 License at
14 * https://source.collectionspace.org/collection-space/LICENSE.txt
16 package org.collectionspace.services.client;
18 import org.collectionspace.services.material.MaterialsCommon;
21 * The Class MaterialAuthorityClient.
23 public class MaterialAuthorityClient extends AuthorityClientImpl<MaterialsCommon, MaterialAuthorityProxy> {
25 public static final String SERVICE_NAME = "materialauthorities";
26 public static final String SERVICE_PATH_COMPONENT = SERVICE_NAME;
27 public static final String SERVICE_PATH = "/" + SERVICE_PATH_COMPONENT;
28 public static final String SERVICE_PAYLOAD_NAME = SERVICE_NAME;
29 public static final String TERM_INFO_GROUP_XPATH_BASE = "materialTermGroupList";
33 public static final String SERVICE_ITEM_NAME = "materials";
34 public static final String SERVICE_ITEM_PAYLOAD_NAME = SERVICE_ITEM_NAME;
36 // Payload Part/Schema part names
38 public static final String SERVICE_COMMON_PART_NAME = SERVICE_NAME
39 + PART_LABEL_SEPARATOR + PART_COMMON_LABEL;
40 public static final String SERVICE_ITEM_COMMON_PART_NAME = SERVICE_ITEM_NAME
41 + PART_LABEL_SEPARATOR + PART_COMMON_LABEL;
46 public MaterialAuthorityClient() {
50 public MaterialAuthorityClient(String clientPropertiesFilename) {
51 super(clientPropertiesFilename);
55 public String getServiceName() {
60 public String getServicePathComponent() {
61 return SERVICE_PATH_COMPONENT;
65 public String getItemCommonPartName() {
66 return getCommonPartName(SERVICE_ITEM_NAME);
70 public Class<MaterialAuthorityProxy> getProxyClass() {
71 return MaterialAuthorityProxy.class;
75 public String getInAuthority(MaterialsCommon item) {
76 return item.getInAuthority();
80 public void setInAuthority(MaterialsCommon item, String inAuthorityCsid) {
81 item.setInAuthority(inAuthorityCsid);