Changeset 1630
- Timestamp:
- 11/25/11 22:47:10 (12 years ago)
- Location:
- MDService2/branches/MDService_simple3/src/eu/clarin/cmdi/mdservice
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
MDService2/branches/MDService_simple3/src/eu/clarin/cmdi/mdservice/action/RepoAction.java
r1629 r1630 141 141 return; 142 142 case SRU: 143 setTargetProxy(new SRUProxy(new Query( getActionkey(), this.getParams())));143 setTargetProxy(new SRUProxy(new Query(Query.SRURECORDSET, this.getParams()))); 144 144 return; 145 145 case MD: -
MDService2/branches/MDService_simple3/src/eu/clarin/cmdi/mdservice/model/Query.java
r1627 r1630 43 43 public static String RECORD = "record"; 44 44 public static String SRUEXTERN = "sruextern"; 45 public static String SRURECORDSET = "srurecordset"; 45 46 46 47 public static String PARSED = "parsed"; … … 241 242 242 243 log.debug("QUERY.FULLQUERYSTRING:" + query_string); 243 if ( type.equals(RECORDSET) && (query_string.length() > 0)) {244 if ((type.equals(RECORDSET) || (type.equals(SRURECORDSET))) && (query_string.length() > 0)) { 244 245 parse(); 245 246 //preprocess(); … … 450 451 log.debug("Query.toURLParam.corrid=" + corrid); 451 452 targetRequest = "//MdSelfLink[ft:query(.,'" + corrid + "')]"; 453 } else if (type.equals(SRURECORDSET)) { 454 targetRequest = "?query="+ getParam("query") + "&operation=" + getParam("operation"); 455 456 if (!getParam("startItem").equals("")) { 457 targetRequest = targetRequest + "&startItem=" + getParam("startItem"); 458 } 459 if (!getParam("maximumItems").equals("")) { 460 targetRequest = targetRequest + "&maxItems=" + getParam("maximumItems"); 461 } 462 if ((!getParam("version").equals(""))) { 463 targetRequest = targetRequest + "&version" + getParam("version"); 464 } 452 465 } else { 453 466 if (query_cql == null){ -
MDService2/branches/MDService_simple3/src/eu/clarin/cmdi/mdservice/proxy/SRUProxy.java
r1627 r1630 35 35 // check and set defaults 36 36 if (getParam("operation").equals("")) { 37 //getSourceAction().setParam("operation","searchRetrieve"); 37 38 getSourceAction().getDiagnostics().Add(Diagnostic.MANDATORY_NOTSUPPLIED, "operation"); 38 39 } 39 40 if (getParam("version").equals("")) { 41 //getSourceAction().setParam("version","1.2"); 40 42 getSourceAction().getDiagnostics().Add(Diagnostic.MANDATORY_NOTSUPPLIED, "version"); 41 43 }
Note: See TracChangeset
for help on using the changeset viewer.