/// <summary>
        /// Parses the response.
        /// </summary>
        /// <param name="reader">The reader.</param>
        /// <returns>Response object.</returns>
        internal override object ParseResponse(EwsServiceXmlReader reader)
        {
            GetPhoneCallResponse response = new GetPhoneCallResponse(Service);

            response.LoadFromXml(reader, XmlElementNames.GetPhoneCallResponse);
            return(response);
        }
        /// <summary>
        /// Executes this request.
        /// </summary>
        /// <returns>Service response.</returns>
        internal GetPhoneCallResponse Execute()
        {
            GetPhoneCallResponse serviceResponse = (GetPhoneCallResponse)this.InternalExecute();

            serviceResponse.ThrowIfNecessary();
            return(serviceResponse);
        }
        /// <summary>
        /// Executes this request.
        /// </summary>
        /// <returns>Service response.</returns>
        internal async Task <GetPhoneCallResponse> Execute()
        {
            GetPhoneCallResponse serviceResponse = (GetPhoneCallResponse)await this.InternalExecuteAsync().ConfigureAwait(false);

            serviceResponse.ThrowIfNecessary();
            return(serviceResponse);
        }
        /// <summary>
        /// Retrieves information about a current phone call.
        /// </summary>
        /// <param name="id">The Id of the phone call.</param>
        /// <returns>An object providing status for the phone call.</returns>
        internal PhoneCall GetPhoneCallInformation(PhoneCallId id)
        {
            GetPhoneCallRequest request = new GetPhoneCallRequest(service);

            request.Id = id;
            GetPhoneCallResponse response = request.Execute();

            return(response.PhoneCall);
        }
        /// <summary>
        /// Retrieves information about a current phone call.
        /// </summary>
        /// <param name="id">The Id of the phone call.</param>
        /// <returns>An object providing status for the phone call.</returns>
        internal async Task <PhoneCall> GetPhoneCallInformation(PhoneCallId id, CancellationToken token)
        {
            GetPhoneCallRequest request = new GetPhoneCallRequest(service);

            request.Id = id;
            GetPhoneCallResponse response = await request.Execute(token).ConfigureAwait(false);

            return(response.PhoneCall);
        }
 /// <summary>
 /// Parses the response.
 /// </summary>
 /// <param name="reader">The reader.</param>
 /// <returns>Response object.</returns>
 internal override object ParseResponse(EwsServiceXmlReader reader)
 {
     GetPhoneCallResponse response = new GetPhoneCallResponse(Service);
     response.LoadFromXml(reader, XmlElementNames.GetPhoneCallResponse);
     return response;
 }