call() публичный Метод

Overload for call that allows multiple calls to be made with one parmameter.
public call ( ArrayList to ) : void
to ArrayList An ArryList containing recipients to call.
Результат void
Пример #1
0
        public void testCallUsingCallObject()
        {
            Tropo tropo = new Tropo();

            Hashtable headers = new Hashtable();
            headers.Add("foo", "bar");
            headers.Add("bling", "baz");

            StartRecording recording = new StartRecording(AudioFormat.mp3, Method.post, "http://blah.com/recordings/1234.wav", "jose", "password");

            ArrayList to = new ArrayList(1);
            to.Add("3055195825");

            Call call = new Call();
            call.recording = recording;
            call.headers = headers;
            call.timeout = 10;
            call.answerOnMedia = false;
            call.channel = Channel.text;
            call.network = Network.sms;
            call.to = to;
            call.from = new Endpoint("3055551212", null, null, null);

            tropo.call(call);
            Assert.AreEqual(this.callJsonAllOptions, TropoJSON.render(tropo));
        }
Пример #2
0
        public void testToOnly()
        {
            ArrayList numbersToCall = new ArrayList(2);
            numbersToCall.Add("3055195825");
            numbersToCall.Add("3054445567");

            Tropo tropo = new Tropo();
            tropo.call(numbersToCall);
            Assert.AreEqual(this.callJson, TropoJSON.render(tropo));
        }
Пример #3
0
        public void testCallUseAllOptions()
        {
            Tropo tropo = new Tropo();

            Hashtable headers = new Hashtable(2);
            headers.Add("foo", "bar");
            headers.Add("bling", "baz");

            StartRecording recording = new StartRecording(AudioFormat.mp3, Method.post, "http://blah.com/recordings/1234.wav", "jose", "password");

            tropo.call("3055195825", "3055551212", Network.sms, Channel.text, false, 10, headers, recording);
            Assert.AreEqual(this.callJsonAllOptions, TropoJSON.render(tropo));
        }