Esempio n. 1
0
        /// <summary>
        /// Pull callback SMS messages status.
        /// </summary>
        /// <param name="max">maximum number of message status</param>
        /// <returns>SmsStatusPullCallbackResult</returns>
        public SmsStatusPullCallbackResult pullCallback(int max)
        {
            // May throw HttpRequestException
            HTTPResponse res = pull(0, max);

            SmsStatusPullCallbackResult result = new SmsStatusPullCallbackResult();

            // May throw JSONException
            result.parseFromHTTPResponse(res);

            return(result);
        }
Esempio n. 2
0
        /// <summary>
        /// Pull SMS messages status for single mobile.
        /// </summary>
        /// <param name="nationCode">nation dialing code, e.g. China is 86, USA is 1</param>
        /// <param name="mobile">mobile number</param>
        /// <param name="beginTime">begin time, unix timestamp</param>
        /// <param name="endTime">begin time, unix timestamp</param>
        /// <param name="max">maximum number of message status</param>
        /// <returns>SmsStatusPullCallbackResult</returns>
        public SmsStatusPullCallbackResult pullCallback(string nationCode, string mobile,
                                                        long beginTime, long endTime, int max)
        {
            // May throw HttpRequestException
            HTTPResponse res = pull(0, nationCode, mobile, beginTime, endTime, max);

            SmsStatusPullCallbackResult result = new SmsStatusPullCallbackResult();

            // May throw JSONException
            result.parseFromHTTPResponse(res);

            return(result);
        }