summaryrefslogtreecommitdiff
path: root/reference/csharp/eina/src/eina_list.cs
diff options
context:
space:
mode:
authorXavi Artigas <xavierartigas@yahoo.es>2019-01-15 13:19:08 +0100
committerXavi Artigas <xavierartigas@yahoo.es>2019-01-15 13:19:08 +0100
commita5c08814d897e6c00729b61e3886532b7e942705 (patch)
treed6ca3bc47827cca95702d252b9d0ab31e98c64a3 /reference/csharp/eina/src/eina_list.cs
parente06157c1f625adc2fe7c1df79a0148308bf67e57 (diff)
examples-mono: Update Eina comments to latest syntax
Diffstat (limited to 'reference/csharp/eina/src/eina_list.cs')
-rw-r--r--reference/csharp/eina/src/eina_list.cs14
1 files changed, 7 insertions, 7 deletions
diff --git a/reference/csharp/eina/src/eina_list.cs b/reference/csharp/eina/src/eina_list.cs
index ecdf7d3..e04dc20 100644
--- a/reference/csharp/eina/src/eina_list.cs
+++ b/reference/csharp/eina/src/eina_list.cs
@@ -1,8 +1,8 @@
1 1
2/* 2/*
3 * Eina List examples. 3 * Eina.List examples.
4 * 4 *
5 * These examples demonstrate how to work with Eina_list data and methods. 5 * These examples demonstrate how to work with Eina.List data and methods.
6 * We create a simple list of names by appending strings to an empty list 6 * We create a simple list of names by appending strings to an empty list
7 * and then run various mutations and print each result. 7 * and then run various mutations and print each result.
8 */ 8 */
@@ -29,13 +29,13 @@ public class Example
29 29
30 var list = CreateList(); 30 var list = CreateList();
31 31
32 // print our list with a simple foreach 32 // Print our list with a simple foreach
33 Console.WriteLine("List size: {0}", list.Count()); 33 Console.WriteLine("List size: {0}", list.Count());
34 Console.WriteLine("List content:"); 34 Console.WriteLine("List content:");
35 foreach(string item in list) 35 foreach(string item in list)
36 Console.WriteLine(" {0}", item); 36 Console.WriteLine(" {0}", item);
37 37
38 // insert some more elements 38 // Insert some more elements
39 list.Prepend("Cain"); 39 list.Prepend("Cain");
40// list.PrependRelative("Tigh", "Baltar"); // TODO: missing 40// list.PrependRelative("Tigh", "Baltar"); // TODO: missing
41 41
@@ -43,7 +43,7 @@ public class Example
43 foreach(string item in list) 43 foreach(string item in list)
44 Console.WriteLine(" {0}", item); 44 Console.WriteLine(" {0}", item);
45 45
46 // promote an item to the top of the list 46 // Promote an item to the top of the list
47 // TODO: implement ? 47 // TODO: implement ?
48// list.PromoteList(list.NthList(1)); 48// list.PromoteList(list.NthList(1));
49// list.Remove("Cain"); 49// list.Remove("Cain");
@@ -52,14 +52,14 @@ public class Example
52// foreach(string item in list) 52// foreach(string item in list)
53// Console.WriteLine(" {0}", item); 53// Console.WriteLine(" {0}", item);
54 54
55 // we can sort the list with any callback 55 // We can sort the list with any callback
56// list.Sort((string strA, string strB) => { return strA.Compare(strB); }); // TODO: FIXME custom sort 56// list.Sort((string strA, string strB) => { return strA.Compare(strB); }); // TODO: FIXME custom sort
57 list.Sort(); 57 list.Sort();
58 Console.WriteLine("List content sorted:"); 58 Console.WriteLine("List content sorted:");
59 foreach(string item in list) 59 foreach(string item in list)
60 Console.WriteLine(" {0}", item); 60 Console.WriteLine(" {0}", item);
61 61
62 // and foreach can be in reverse too 62 // And foreach can be in reverse too
63 Console.WriteLine("List content reverse sorted:"); 63 Console.WriteLine("List content reverse sorted:");
64 foreach(string item in list.Reverse()) 64 foreach(string item in list.Reverse())
65 Console.WriteLine(" {0}", item); 65 Console.WriteLine(" {0}", item);