protected String buildResourcePath(String basePath,String resourcePath){
  if (basePath == null) {
    basePath="";
  }
  String base=trimSlashes(basePath);
  if (!base.equals("")) {
    base="/" + base;
  }
  String result=StringUtils.removeEnd(base + "/" + trimSlashes(resourcePath),"/");
  if (result.equals("")) {
    result="/";
  }
  return result;
}

protected String buildResourcePath ( String basePath , String resourcePath ) { if ( basePath == null ) { basePath = "" ; } String base = trimSlashes ( basePath ) ; if ( ! base . equals ( "" ) ) { base = "/" + base ; } String result = StringUtils . removeEnd ( base + "/" + trimSlashes ( resourcePath ) , "/" ) ; if ( result . equals ( "" ) ) { result = "/" ; } return result ; }
build the full resource path , including base path , add any missing leading ' / ' , remove any trailing ' / ' , and remove any double ' / '
