* @version $Id: URLUtilities.java,v 1.2 2014/03/12 19:45:41 eby Exp $\r
*/\r
public class URLUtilities {\r
+\r
/**\r
* Generate the URL used to access a feed.\r
*\r
* @return the URL\r
*/\r
public static String generateFeedURL(int feedid) {\r
- return "https://" + BaseServlet.prov_name + "/feed/" + feedid;\r
+ return "https://" + BaseServlet.getProvName() + "/feed/" + feedid;\r
}\r
\r
/**\r
* @return the URL\r
*/\r
public static String generatePublishURL(int feedid) {\r
- return "https://" + BaseServlet.prov_name + "/publish/" + feedid;\r
+ return "https://" + BaseServlet.getProvName() + "/publish/" + feedid;\r
}\r
\r
/**\r
* @return the URL\r
*/\r
public static String generateSubscribeURL(int feedid) {\r
- return "https://" + BaseServlet.prov_name + "/subscribe/" + feedid;\r
+ return "https://" + BaseServlet.getProvName() + "/subscribe/" + feedid;\r
}\r
\r
/**\r
* @return the URL\r
*/\r
public static String generateFeedLogURL(int feedid) {\r
- return "https://" + BaseServlet.prov_name + "/feedlog/" + feedid;\r
+ return "https://" + BaseServlet.getProvName() + "/feedlog/" + feedid;\r
}\r
\r
/**\r
* @return the URL\r
*/\r
public static String generateSubscriptionURL(int subid) {\r
- return "https://" + BaseServlet.prov_name + "/subs/" + subid;\r
+ return "https://" + BaseServlet.getProvName() + "/subs/" + subid;\r
}\r
\r
/**\r
* @return the URL\r
*/\r
public static String generateSubLogURL(int subid) {\r
- return "https://" + BaseServlet.prov_name + "/sublog/" + subid;\r
+ return "https://" + BaseServlet.getProvName() + "/sublog/" + subid;\r
}\r
\r
/**\r
public static String generatePeerLogsURL() {\r
//Fixes for Itrack ticket - DATARTR-4#Fixing if only one Prov is configured, not to give exception to fill logs.\r
String peerPodUrl = getPeerPodName();\r
- if (peerPodUrl.equals("") || peerPodUrl.equals(null)) {\r
+ if (peerPodUrl.equals("") || peerPodUrl==null) {\r
return "";\r
}\r
\r
}\r
System.out.println("ALL PODS: " + Arrays.asList(BaseServlet.getPods()));\r
for (String pod : BaseServlet.getPods()) {\r
- if (!pod.equals(this_pod))\r
+ if (!pod.equals(this_pod)) {\r
other_pod = pod;\r
+ }\r
}\r
}\r
return other_pod;\r