예제 #1
0
 public static string ConstructSearchUrl(HttpContext ctx, string limit, string query, bool searchTag, bool short_url = false)
 {
     if (searchTag)
     {
         return(APIHelper.ProperURL(ctx, "/api/searchTag/" + limit + "/" + System.Net.WebUtility.UrlEncode(query),
                                    short_url));
     }
     else
     {
         return(APIHelper.ProperURL(ctx, "/api/search/" + limit + "/" + System.Net.WebUtility.UrlEncode(query),
                                    short_url));
     }
 }
예제 #2
0
 public static string ConstructPlaylistIdUrl(HttpContext ctx, int pid, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/metadata/" + (int)JMMType.Playlist + "/" + pid, short_url));
 }
예제 #3
0
 public static string ConstructFiltersUrl(HttpContext ctx, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "__TEST__", short_url));
 }
예제 #4
0
 public static string ConstructVideoUrl(HttpContext ctx, string vid, JMMType type, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "__TEST__" + (int)type + "/" + vid, short_url));
 }
예제 #5
0
 public static string ConstructFilterIdUrl(HttpContext ctx, int groupfilter_id, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/filter?id=" + groupfilter_id, short_url));
 }
예제 #6
0
 public static string ConstructGroupIdUrl(HttpContext ctx, string gid, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "__TEST__" + (int)JMMType.Group + "/" + gid, short_url));
 }
예제 #7
0
 public static string ConstructSerieIdUrl(HttpContext ctx, string sid, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "__TEST__" + (int)JMMType.Serie + " / " + sid, short_url));
 }
예제 #8
0
 public static string ConstructUnsortUrl(HttpContext ctx, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/file/unsort", short_url));
 }
예제 #9
0
 public static string ConstructVideoLocalStream(HttpContext ctx, int userid, string vid, string name, bool autowatch)
 {
     return(APIHelper.ProperURL(ctx, "/Stream/" + vid + "/" + userid + "/" + autowatch + "/" + name));
 }
예제 #10
0
 public static string ConstructImageLinkFromTypeAndId(NancyContext ctx, int type, int id, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/image/" + type.ToString() + "/" + id.ToString()));
 }
예제 #11
0
 public static string ConstructPlaylistUrl(NancyContext ctx, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/metadata/" + (int)JMMType.Playlist + "/0", short_url));
 }
예제 #12
0
 public static string ConstructFilterUrl(NancyContext ctx, bool short_url = false)
 {
     return(APIHelper.ProperURL(ctx, "/api/filter", short_url));
 }