public override string ToString() { StringBuilder stringBuilder = new StringBuilder(); try { stringBuilder.Append("InteractionId : " + InteractionId); stringBuilder.Append("\nCommonSearchData : " + CommonSearchData); stringBuilder.Append("\nCommonPopupObjects : " + CommonPopupObjects); stringBuilder.Append("\nCommonSearchFormats : " + CommonSearchFormats); stringBuilder.Append("\nLeadData : " + ((LeadData != null) ? LeadData.ToString() : "null")); stringBuilder.Append("\nContactData : " + ((ContactData != null) ? ContactData.ToString() : "null")); stringBuilder.Append("\nAccountData : " + ((AccountData != null) ? AccountData.ToString() : "null")); stringBuilder.Append("\nCaseData : " + ((CaseData != null) ? CaseData.ToString() : "null")); stringBuilder.Append("\nOpportunityData : " + ((OpportunityData != null) ? OpportunityData.ToString() : "null")); stringBuilder.Append("\nUserActivityData : " + ((UserActivityData != null) ? UserActivityData.ToString() : "null")); if (this.CustomObjectData != null) { string cstdata = string.Empty; foreach (CustomObjectData cst in this.CustomObjectData) { cstdata += "\n" + cst.ToString(); } stringBuilder.Append("\nCustomObjectData : " + cstdata); } else { stringBuilder.Append("\nCustomObjectData : " + "null"); } } catch { return(stringBuilder.ToString()); } return(stringBuilder.ToString()); }