Example #1
0
 /// <summary>
 /// Records a response in the last RequestFlowItem stored in the Items list.
 /// </summary>
 /// <param name="responseObject"></param>
 public void RecordResponse(IPayPalSerializableObject responseObject)
 {
     if (responseObject != null && this.Items.Any())
     {
         this.Items.Last().Response = Common.FormatJsonString(responseObject.ConvertToJson());
     }
 }
Example #2
0
 /// <summary>
 /// Records a response in the last RequestFlowItem stored in the Items list.
 /// </summary>
 /// <param name="responseObject"></param>
 public void RecordResponse(IPayPalSerializableObject responseObject)
 {
     if(responseObject != null && this.Items.Any())
     {
         this.Items.Last().Response = Common.FormatJsonString(responseObject.ConvertToJson());
     }
 }
Example #3
0
 /// <summary>
 /// Adds a new RequestFlowItem to the list of Items.
 /// </summary>
 /// <param name="title">Title of this flow item.</param>
 /// <param name="requestObject">(Optional) The object used for the request.</param>
 /// <param name="description">(Optional) The description of the request.</param>
 public void AddNewRequest(string title, IPayPalSerializableObject requestObject = null, string description = "")
 {
     this.Items.Add(new RequestFlowItem()
     {
         Request     = requestObject == null ? string.Empty : Common.FormatJsonString(requestObject.ConvertToJson()),
         Title       = title,
         Description = description
     });
 }
Example #4
0
 /// <summary>
 /// Adds a new RequestFlowItem to the list of Items.
 /// </summary>
 /// <param name="title">Title of this flow item.</param>
 /// <param name="requestObject">(Optional) The object used for the request.</param>
 /// <param name="description">(Optional) The description of the request.</param>
 public void AddNewRequest(string title, IPayPalSerializableObject requestObject = null, string description = "")
 {
     this.Items.Add(new RequestFlowItem()
     {
         Request = requestObject == null ? string.Empty : Common.FormatJsonString(requestObject.ConvertToJson()),
         Title = title,
         Description = description
     });
 }
Example #5
0
 public static void LogRecord(IPayPalSerializableObject responseObject)
 {
     Tools.Tool.Log.Write("Paypal", FormatJsonString(responseObject.ConvertToJson()));
 }