CreateSyncRequest() static private method

Create a generic Sync request without command references by using the specified sync key, folder collectionId and body preference option.
static private CreateSyncRequest ( string syncKey, string collectionId, Request bodyPreference ) : SyncRequest
syncKey string Specify the sync key obtained from the last Sync response.
collectionId string Specify the serverId of the folder to be synchronized.
bodyPreference Microsoft.Protocols.TestSuites.Common.Request Sets preference information related to the type and size of information for body.
return SyncRequest
        /// <summary>
        /// Create a Sync Add request.
        /// </summary>
        /// <param name="syncKey">Specify the sync key obtained from the last Sync response</param>
        /// <param name="collectionId">Specify the serverId of the folder to be synchronized.</param>
        /// <param name="applicationData">The data used to specify the Add element for Sync command.</param>
        /// <returns>The SyncRequest instance.</returns>
        internal static SyncRequest CreateSyncAddRequest(string syncKey, string collectionId, Request.SyncCollectionAddApplicationData applicationData)
        {
            SyncRequest syncAddRequest = TestSuiteHelper.CreateSyncRequest(syncKey, collectionId, null);

            Request.SyncCollectionAdd add = new Request.SyncCollectionAdd
            {
                ClientId        = Guid.NewGuid().ToString("N"),
                ApplicationData = applicationData
            };

            List <object> commandList = new List <object> {
                add
            };

            syncAddRequest.RequestData.Collections[0].Commands = commandList.ToArray();

            return(syncAddRequest);
        }