From efa3e0e3efc23ee34fef739425df043c7fb571bb Mon Sep 17 00:00:00 2001 From: Stone_Red <56473591+Stone-Red-Code@users.noreply.github.com> Date: Mon, 10 May 2021 17:35:49 +0200 Subject: [PATCH] Created CollectionExtentions (markdown) --- CollectionExtentions.md | 46 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 CollectionExtentions.md diff --git a/CollectionExtentions.md b/CollectionExtentions.md new file mode 100644 index 0000000..61b611f --- /dev/null +++ b/CollectionExtentions.md @@ -0,0 +1,46 @@ +# Stone_Red_Utilities.CollectionExtentions + +## Methods + +* Print\ + * Description: Prints items of an IEnumerable\ + * Parameters: `this IEnumerable collection`, `char delimiter`, `bool printToDebugConsole` + * Example usage: + + ```cs + string[] yourArray = { "str1", "str2", "str3" }; + yourArray.Print(';'); + ``` + + * Output: + + ```text + str1; str2; str3 + ``` + +* PrintTable\ + * Description: Creates and prints table from 2D array + * Parameters: `this T[,] array`, `TableStyle tableStyle` + * Example usage: + + ```cs + int[,] your2dArray = + { + {1,2,3 }, + {4,5,6 }, + {7,8,9 } + }; + your2dArray.PrintTable(TableStyle.Default); + ``` + + * Output: + + ```text + ------------- + | 1 | 2 | 3 | + ------------- + | 4 | 5 | 6 | + ------------- + | 7 | 8 | 9 | + ------------- + ``` \ No newline at end of file