/// <summary> /// Convenience method to return a <see cref="System.String"/> /// array as a delimited (e.g. CSV) <see cref="System.String"/>. /// </summary> /// <param name="source"> /// The array to parse. Elements may be of any type ( /// <see cref="System.Object.ToString"/> will be called on each /// element). /// </param> /// <param name="delimiter"> /// The delimiter to use (probably a ','). /// </param> public static string ArrayToDelimitedString <T>(IEnumerable <T> source, string delimiter) { if (source == null) { return("null"); } else { return(StringUtils.CollectionToDelimitedString(source, delimiter)); } }
/// <summary> /// Convenience method to return a <see cref="System.String"/> /// array as a delimited (e.g. CSV) <see cref="System.String"/>. /// </summary> /// <param name="source"> /// The array to parse. Elements may be of any type ( /// <see cref="System.Object.ToString"/> will be called on each /// element). /// </param> /// <param name="delimiter"> /// The delimiter to use (probably a ','). /// </param> public static string ArrayToDelimitedString( object[] source, string delimiter) { if (source == null) { return("null"); } else { return(StringUtils.CollectionToDelimitedString(source, delimiter)); } }