public string GetBookmark(String base_url, String page, ClientSelections selections) { try { try { if (WebConfigurationManager.AppSettings["XFordMapping_Enabled"].ToString() == "1" || WebConfigurationManager.AppSettings["XFordMapping_Enabled"].ToString().ToUpper() == "TRUE") { base_url = base_url.Replace(WebConfigurationManager.AppSettings["XFordMapping_Key"].ToString(), WebConfigurationManager.AppSettings["XFordMapping_Value"].ToString()); } } catch (Exception e) { } FISBookmark b = new FISBookmark(selections); //return base_url + "?b=" + b.GetBookmark(); return(base_url + "wsl/WSLHandler.aspx?page=" + page + "&data=" + b.GetBookmark() + "&ts=" + DateTime.Now.Second); } catch (Exception ex) { FISLogging.Log("[E] Exception Encountered: " + ex.Message); FISLogging.Log("[E-P] Params: selections = " + selections.ToString()); FISLogging.Log("[E-ST] " + ex.StackTrace); HttpContext.Current.Response.StatusCode = 500; throw ex; } }
public ClientSelections LoadBookmark(String data) { try { FISBookmark b = new FISBookmark(null); b.LoadBookmark(data); b.selections.lst_strSelectedNodeSuperPaths = b.selections.lst_strSelectedNodeSuperPaths.Distinct().ToList(); return(b.selections); } catch (Exception ex) { FISLogging.Log("[E] Exception Encountered: " + ex.Message); FISLogging.Log("[E-P] Params: data = " + data); FISLogging.Log("[E-ST] " + ex.StackTrace); HttpContext.Current.Response.StatusCode = 500; throw ex; } }
public ClientSelections BookmarkOnDemand(String type, List <String> payload) { try { ClientSelections c = new ClientSelections(); foreach (String arg in payload) { c.lst_strSelectedNodeSuperPaths.AddRange(FISBookmark.ParseOnDemandBookmark(type, arg)); } c.lst_strSelectedNodeSuperPaths = c.lst_strSelectedNodeSuperPaths.Distinct().ToList(); return(c); } catch (Exception ex) { FISLogging.Log("[E] Exception Encountered: " + ex.Message); FISLogging.Log("[E-P] Params: Type = " + type + ", Payload: " + String.Join("//", payload)); FISLogging.Log("[E-ST] " + ex.StackTrace); HttpContext.Current.Response.StatusCode = 500; throw ex; } }