Exemplo n.º 1
0
 public MediaInput(string ed2k, JMMContracts.PlexAndKodi.Media m)
 {
     int outsize;
     byte[] data = CompressionHelper.SerializeObject(m, out outsize);
     ED2K = ed2k;
     MediaInfo = new byte[data.Length + 4];
     MediaInfo[0] = (byte)(outsize >> 24);
     MediaInfo[1] = (byte)((outsize >> 16) & 0xFF);
     MediaInfo[2] = (byte)((outsize >> 8) & 0xFF);
     MediaInfo[3] = (byte)(outsize & 0xFF);
     Array.Copy(data, 0, MediaInfo, 4, data.Length);
     Version = VideoLocal.MEDIA_VERSION;
     this.Username = ServerSettings.AniDB_Username;
     if (ServerSettings.WebCache_Anonymous)
         this.Username = Constants.AnonWebCacheUsername;
     this.AuthGUID = string.Empty;
 }
Exemplo n.º 2
0
 public void AddSubtitle(JMMContracts.PlexAndKodi.Stream dict)
 {
     subtitles.Add(subtitles.Count + 1, dict);
 }
Exemplo n.º 3
0
 public void AddAudio(JMMContracts.PlexAndKodi.Stream dict)
 {
     audios.Add(audios.Count + 1, dict);
 }
Exemplo n.º 4
0
 private object EvaluateGroupFilter(JMMContracts.Contract_GroupFilter a)
 {
     return _impl.EvaluateGroupFilter(a);
 }
Exemplo n.º 5
0
 private object SaveUser(JMMContracts.Contract_JMMUser a)
 {
     return _impl.SaveUser(a);
 }
Exemplo n.º 6
0
 private object SaveServerSettings(JMMContracts.Contract_ServerSettings a)
 {
     return _impl.SaveServerSettings(a);
 }
Exemplo n.º 7
0
 private object SaveSeries(JMMContracts.Contract_AnimeSeries_Save a, int b)
 {
     return _impl.SaveSeries(a,b);
 }
Exemplo n.º 8
0
 //Not using simple parameters
 //private object GetSeriesForGroup(int a, List<Entities.AnimeSeries> b)
 //{
 //    return _impl.GetSeriesForGroup(a,b);
 //}
 private object SaveBookmarkedAnime(JMMContracts.Contract_BookmarkedAnime a)
 {
     return _impl.SaveBookmarkedAnime(a);
 }
Exemplo n.º 9
0
 private object SavePlaylist(JMMContracts.Contract_Playlist a)
 {
     return _impl.SavePlaylist(a);
 }
Exemplo n.º 10
0
 private object SaveImportFolder(JMMContracts.Contract_ImportFolder a)
 {
     return _impl.SaveImportFolder(a);
 }
Exemplo n.º 11
0
 private object SaveGroupFilter(JMMContracts.Contract_GroupFilter a)
 {
     return _impl.SaveGroupFilter(a);
 }
Exemplo n.º 12
0
 private object SaveGroup(JMMContracts.Contract_AnimeGroup_Save a, int b)
 {
     return _impl.SaveGroup(a,b);
 }
Exemplo n.º 13
0
 private object SaveFFDPreset(JMMContracts.Contract_FileFfdshowPreset a)
 {
     _impl.SaveFFDPreset(a);
     return "ok";
 }
Exemplo n.º 14
0
 private object SaveCustomTagCrossRef(JMMContracts.Contract_CrossRef_CustomTag a)
 {
     return _impl.SaveCustomTagCrossRef(a);
 }
Exemplo n.º 15
0
 private object SaveCustomTag(JMMContracts.Contract_CustomTag a)
 {
     return _impl.SaveCustomTag(a);
 }
Exemplo n.º 16
0
 public void AddVideo(JMMContracts.PlexAndKodi.Stream dict)
 {
     videos.Add(videos.Count + 1, dict);
 }
Exemplo n.º 17
0
        public static void Send_Media(string ed2k, JMMContracts.PlexAndKodi.Media media)
        {
            //if (!ServerSettings.WebCache_XRefFileEpisode_Send) return;

            string uri = string.Format(@"http://{0}/api/Media", azureHostBaseAddress);

            List<MediaInput> inputs = new List<MediaInput>();
            MediaInput input = new MediaInput(ed2k, media);
            inputs.Add(input);
            string json = JsonConvert.SerializeObject(inputs);
            SendData(uri, json, "POST");
        }
Exemplo n.º 18
0
 private object SaveRenameScript(JMMContracts.Contract_RenameScript a)
 {
     return _impl.SaveRenameScript(a);
 }