Exemple #1
0
        protected override void ParseResponsePost()
        {
            dynamic JObj = JSONHelper.ParseJSON(JsonOutput);

            Response = JSONHelper.ParseJObject <ResponseStreams>(JObj);

            if (Response.Result == "success")
            {
            }
            else
            {
                throw new FailedCallException(Response);
            }
        }
Exemple #2
0
        protected override void ParseResponseGet()
        {
            dynamic JObj = JSONHelper.ParseJSON(JsonOutput);

            Response = JSONHelper.ParseJObject <ResponseStreams>(JObj);

            if (Response.Result == "success")
            {
                StreamCollection = new StreamCollection();
                var result = JSONHelper.ParseJArray <Stream>(Response.Streams);
                if (result != null)
                {
                    foreach (var stream in result)
                    {
                        this.StreamCollection.Add(stream);
                    }
                }
            }
            else
            {
                throw new FailedCallException(Response);
            }
        }