summaryrefslogtreecommitdiff
path: root/reference/csharp/eina/src/eina_hash.cs
diff options
context:
space:
mode:
authorXavi Artigas <xavierartigas@yahoo.es>2018-11-06 10:39:14 +0100
committerXavi Artigas <xavierartigas@yahoo.es>2018-12-19 16:51:15 +0100
commitd74a4df9946b69f769cd0ad40d4414c90d19a515 (patch)
tree7d4de6983ac9b319085fd84f559d2f592fc215b3 /reference/csharp/eina/src/eina_hash.cs
parent656b746be7ffb834a31d0a693071f9eebba186c6 (diff)
csharp examples: Adapt to new classes syntax
Summary: Mainly use PascalCase Namespaces and Classes and proper event names. Test Plan: Check all examples still build. Reviewers: lauromoura, vitor.sousa, felipealmeida, bu5hm4n Reviewed By: bu5hm4n Differential Revision: https://phab.enlightenment.org/D7479
Diffstat (limited to 'reference/csharp/eina/src/eina_hash.cs')
-rw-r--r--reference/csharp/eina/src/eina_hash.cs16
1 files changed, 8 insertions, 8 deletions
diff --git a/reference/csharp/eina/src/eina_hash.cs b/reference/csharp/eina/src/eina_hash.cs
index b85bfaf..19c3db0 100644
--- a/reference/csharp/eina/src/eina_hash.cs
+++ b/reference/csharp/eina/src/eina_hash.cs
@@ -1,7 +1,7 @@
1/* 1/*
2 * Eina Hash examples. 2 * Eina Hash examples.
3 * 3 *
4 * These examples demonstrate how to work with eina_hash data and methods. 4 * These examples demonstrate how to work with Eina_hash data and methods.
5 * 5 *
6 * We have two main hash objects here, firstly an int keyed hash with some 6 * We have two main hash objects here, firstly an int keyed hash with some
7 * dummy content. 7 * dummy content.
@@ -14,10 +14,10 @@ using System.Collections.Generic;
14 14
15public class Example 15public class Example
16{ 16{
17 static eina.Hash<Int32, string> CreateHash() 17 static Eina.Hash<Int32, string> CreateHash()
18 { 18 {
19 // let's create a simple hash with integers as keys 19 // let's create a simple hash with integers as keys
20 var hash = new eina.Hash<Int32, string>(); 20 var hash = new Eina.Hash<Int32, string>();
21 21
22 // Add initial entries to our hash 22 // Add initial entries to our hash
23 for (int i = 0; i < 10; ++i) 23 for (int i = 0; i < 10; ++i)
@@ -53,7 +53,7 @@ public class Example
53 Console.WriteLine($" Name: {key}\tNumber {data}\n"); 53 Console.WriteLine($" Name: {key}\tNumber {data}\n");
54 } 54 }
55 55
56 static void PrintPhonebook(eina.Hash<string, string> book) 56 static void PrintPhonebook(Eina.Hash<string, string> book)
57 { 57 {
58 int count = book.Population(); 58 int count = book.Population();
59 Console.WriteLine($"Complete phone book ({count}):"); 59 Console.WriteLine($"Complete phone book ({count}):");
@@ -65,7 +65,7 @@ public class Example
65 Console.WriteLine(""); 65 Console.WriteLine("");
66 } 66 }
67 67
68 static eina.Hash<string, string> CreatePhonebook() 68 static Eina.Hash<string, string> CreatePhonebook()
69 { 69 {
70 string[] names = 70 string[] names =
71 { 71 {
@@ -79,7 +79,7 @@ public class Example
79 }; 79 };
80 80
81 // create hash of strings to strings 81 // create hash of strings to strings
82 var hash = new eina.Hash<string, string>(); 82 var hash = new Eina.Hash<string, string>();
83 83
84 // Add initial entries to our hash 84 // Add initial entries to our hash
85 for (int i = 0; i < 4; ++i) 85 for (int i = 0; i < 4; ++i)
@@ -119,11 +119,11 @@ public class Example
119 119
120 public static void Main() 120 public static void Main()
121 { 121 {
122 efl.All.Init(); 122 Efl.All.Init();
123 123
124 HashDemo(); 124 HashDemo();
125 PhonebookDemo(); 125 PhonebookDemo();
126 126
127 efl.All.Shutdown(); 127 Efl.All.Shutdown();
128 } 128 }
129} 129}