protected override void loadRequest()
 {
     QueryParameters.Clear();
     BodyParameters.Clear();
     if (After != null)
     {
         QueryParameters.Add("after", new List <string>(new string[] { After }));
     }
     if (Before != null)
     {
         QueryParameters.Add("before", new List <string>(new string[] { Before }));
     }
     if (First != 20)
     {
         QueryParameters.Add("first", new List <string>(new string[] { First + "" }));
     }
     if (GameID.Count != 0)
     {
         QueryParameters.Add("game_id", GameID);
     }
     if (Language.Count != 0)
     {
         QueryParameters.Add("language", Language);
     }
     if (UserID.Count != 0)
     {
         QueryParameters.Add("user_id", UserID);
     }
     if (UserLogin.Count != 0)
     {
         QueryParameters.Add("user_login", UserLogin);
     }
 }
 protected override void loadRequest()
 {
     QueryParameters.Clear();
     BodyParameters.Clear();
     if (UserIDs.Length != 0)
     {
         List <string> ids = new List <string>(UserIDs);
         QueryParameters.Add("id", ids);
     }
     if (LoginNames.Length != 0)
     {
         List <string> names = new List <string>(LoginNames);
         QueryParameters.Add("login", names);
     }
 }
Exemple #3
0
        protected override void loadRequest()
        {
            QueryParameters.Clear();
            BodyParameters.Clear();
            BodyParameters["broadcaster_id"] = BroadcasterID;
            switch (Length)
            {
            case TwitchCommercialLength.TIME180:    BodyParameters["length"] = 180; break;

            case TwitchCommercialLength.TIME150:    BodyParameters["length"] = 150; break;

            case TwitchCommercialLength.TIME120:    BodyParameters["length"] = 120; break;

            case TwitchCommercialLength.TIME90:     BodyParameters["length"] = 90; break;

            case TwitchCommercialLength.TIME60:     BodyParameters["length"] = 60; break;

            case TwitchCommercialLength.TIME30:
            default:                                BodyParameters["length"] = 30; break;
            }
        }
Exemple #4
0
 protected override void loadRequest()
 {
     QueryParameters.Clear();
     BodyParameters.Clear();
     QueryParameters.Add("emotesets", new List <string>(new string[] { SetID }));
 }