View Javadoc
1   package org.kuali.ole.loaders.common.constants;
2   
3   import org.kuali.ole.OLEPropertyConstants;
4   import org.kuali.rice.core.api.config.property.ConfigContext;
5   
6   /**
7    * Created by sheiksalahudeenm on 2/4/15.
8    */
9   public class OLELoaderConstants {
10  
11      public static final String API_ROOT = ConfigContext.getCurrentContextConfig().getProperty(OLEPropertyConstants.OLE_URL_BASE) + "/api";
12      public static final String LOCATION_URI = API_ROOT + "/location";
13      public static final String LOCATION_LEVEL_URI = API_ROOT + "/locationLevel";
14      public static final String SLASH = "/";
15  
16      public static final class OLEloaderCode {
17          public static final String LOCATION_NOT_EXIST = "001";
18          public static final String LOCATION_LEVEL_NOT_EXIST = "002";
19          public static final String PARENT_LOCATION_NOT_EXIST = "003";
20          public static final String LOCATION_SUCCESS = "004";
21          public static final String LOCATION_FAILED = "005";
22          public static final String LOCATION_INVALID_CONTENT = "006";
23          public static final String PARENT_LOCATION_LEVEL_NOT_EXIST = "007";
24          public static final String LOCATION_LEVEL_SUCCESS = "008";
25          public static final String LOCATION_LEVEL_FAILED = "009";
26          public static final String SCHELVING_SCHEME_NOT_EXIST = "010";
27          public static final String SCHELVING_SCHEME_SUCCESS = "011";
28          public static final String SCHELVING_SCHEME_FAILED = "012";
29          public static final String SCHELVING_SCHEME_INVALID_CONTENT = "013";
30  
31  
32          public static final String PATRON_NOT_EXIST = "014";
33          public static final String PATRON_SUCCESS = "015";
34          public static final String PATRON_FAILED = "016";
35          public static final String PATRON_INVALID_CONTENT = "017";
36  
37          public static final String BORROWER_TYPE_NOT_EXIST = "018";
38          public static final String BORROWER_TYPE_SUCCESS = "019";
39          public static final String BORROWER_TYPE_FAILED = "020";
40          public static final String BORROWER_TYPE_INVALID_CONTENT = "021";
41  
42          public static final String ITEM_TYPE_NOT_EXIST = "022";
43          public static final String ITEM_TYPE_SUCCESS = "023";
44          public static final String ITEM_TYPE_FAILED = "024";
45          public static final String ITEM_TYPE_INVALID_CONTENT = "025";
46  
47  
48          public static final String BAD_REQUEST = "400";
49      }
50  
51      public static final class OLEloaderStatus{
52          public static final int LOCATION_NOT_EXIST = 404;
53          public static final int LOCATION_LEVEL_NOT_EXIST = 404;
54          public static final int PARENT_LOCATION_NOT_EXIST = 404;
55          public static final int LOCATION_SUCCESS = 200;
56          public static final int LOCATION_FAILED = 500;
57          public static final int LOCATION_INVALID_CONTENT = 500;
58          public static final int PARENT_LOCATION_LEVEL_NOT_EXIST = 200;
59          public static final int LOCATION_LEVEL_SUCCESS = 200;
60          public static final int LOCATION_LEVEL_FAILED = 500;
61          public static final int SCHELVING_SCHEME_NOT_EXIST = 200;
62          public static final int SCHELVING_SCHEME_SUCCESS = 200;
63          public static final int SCHELVING_SCHEME_FAILED = 500;
64          public static final int SCHELVING_SCHEME_INVALID_CONTENT = 500;
65  
66          public static final int PATRON_NOT_EXIST = 200;
67          public static final int PATRON_SUCCESS = 200;
68          public static final int PATRON_FAILED = 500;
69          public static final int PATRON_INVALID_CONTENT = 500;
70  
71          public static final int BORROWER_TYPE_NOT_EXIST = 200;
72          public static final int BORROWER_TYPE_SUCCESS = 200;
73          public static final int BORROWER_TYPE_FAILED = 500;
74          public static final int BORROWER_TYPE_INVALID_CONTENT = 500;
75  
76          public static final int ITEM_TYPE_NOT_EXIST = 200;
77          public static final int ITEM_TYPE_SUCCESS = 200;
78          public static final int ITEM_TYPE_FAILED = 500;
79          public static final int ITEM_TYPE_INVALID_CONTENT = 500;
80  
81          public static final int BAD_REQUEST = 400;
82      }
83  
84      public static final class OLEloaderMessage {
85          public static final String LOCATION_NOT_EXIST = "Location does not exist";
86          public static final String LOCATION_LEVEL_NOT_EXIST = "Location level does not exist.";
87          public static final String PARENT_LOCATION_NOT_EXIST = "Parent Location does not exist.";
88          public static final String LOCATION_SUCCESS= "Successfully Updated the location.";
89          public static final String LOCATION_FAILED = "Location update failed.";
90          public static final String LOCATION_INVALID_CONTENT = "Invalid Input Content for location import";
91          public static final String PARENT_LOCATION_LEVEL_NOT_EXIST = "Parent Location Level does not exist.";
92          public static final String LOCATION_LEVEL_SUCCESS = "Successfully Updated the location level";
93          public static final String LOCATION_LEVEL_FAILED = "Location Level update failed.";
94          public static final String SCHELVING_SCHEME_NOT_EXIST = "Schelving Scheme does not exist";
95          public static final String SCHELVING_SCHEME_SUCCESS = "Successfully Updated the schelving scheme.";
96          public static final String SCHELVING_SCHEME_FAILED = "Schelving scheme update failed.";
97          public static final String SCHELVING_SCHEME_INVALID_CONTENT = "Invalid input content for schelving scheme import";
98  
99          public static final String PATRON_NOT_EXIST = "Patron does not exits.";
100         public static final String PATRON_SUCCESS = "Successfully Updated the patron.";
101         public static final String PATRON_FAILED = "Patron update failed.";
102         public static final String PATRON_INVALID_CONTENT = "Invalid input content for Patron import";
103 
104         public static final String BORROWER_TYPE_NOT_EXIST = "Borrower type does not exits.";
105         public static final String BORROWER_TYPE_SUCCESS = "Successfully Updated the Borrower type.";
106         public static final String BORROWER_TYPE_FAILED = "Borrower type update failed.";
107         public static final String BORROWER_TYPE_INVALID_CONTENT = "Invalid input content for Borrower type import";
108 
109         public static final String ITEM_TYPE_NOT_EXIST = "Item type does not exits.";
110         public static final String ITEM_TYPE_SUCCESS = "Successfully Updated the Item type.";
111         public static final String ITEM_TYPE_FAILED = "Item type update failed.";
112         public static final String ITEM_TYPE_INVALID_CONTENT = "Invalid input content for Item type import";
113 
114         public static final String BAD_REQUEST = "Bad Request";
115     }
116 
117     public static final class OLELoaderContext {
118 
119         public static String LOCATION = "http;//ole.kuali.org/standards/api/location.jsonld";
120         public static String LOCATION_LEVEL = "http;//ole.kuali.org/standards/api/locationLevel.jsonld";
121         public static String ITEM_TYPE = "http;//ole.kuali.org/standards/api/itemType.jsonld";
122         public static String ITEM_STATUS = "http;//ole.kuali.org/standards/api/itemAvailabilityStatus.jsonld";
123         public static String SCHELVING_SCHEME = "http;//ole.kuali.org/standards/api/callNumberType.jsonld";
124         public static String STATISTICAL_SEARCH = "http;//ole.kuali.org/standards/api/statSearchCode.jsonld";
125        /* public static String BIBLIOGRAPHIC_RECORD_STATUS = "http;//ole.kuali.org/standards/api/location.jsonld";*/
126         public static String BORROWER_TYPE = "http;//ole.kuali.org/standards/api/borrowerType.jsonld";
127         public static String PATRON = "http;//ole.kuali.org/standards/api/patron.jsonld";
128         public static String CIRCULATION_DESK = "http;//ole.kuali.org/standards/api/circulationDesk.jsonld";
129     }
130 
131 
132 }