public static void execute() { char exec = '-'; if (exec == '+') { Console.WriteLine("Exemple d'utilisation Propriété:\r\n"); newClass nc = new newClass("Prop1 init value"); Console.WriteLine("Prop1:" + nc.Prop1); Console.WriteLine("Prop2:" + nc.Prop2); Console.WriteLine("Prop3:" + nc.Prop3); Console.WriteLine("Prop4:" + nc.Prop4); Console.WriteLine("Prop4 <- ESSAI"); nc.Prop4 = "ESSAI"; Console.WriteLine("Prop2:" + nc.Prop2); Console.WriteLine("Prop4:" + nc.Prop4); Console.WriteLine("Prop4 <- ''"); nc.Prop4 = ""; Console.WriteLine("Prop2:" + nc.Prop2); Console.WriteLine("Prop4:" + nc.Prop4); Console.WriteLine("\r\n"); } }
static void Main(string[] args) { newClass a = new newClass(); Console.WriteLine("hello im Zolboo"); a.setName("Bold"); a.print(); }
public static void Main(String [] args) { newClass n = new newClass(); n.names(); Console.WriteLine("My Name is " + n.name); }
public static void Find(object obj) { // Console.WriteLine("Here"); newClass o = (newClass)obj; int search = 3; for (int i = o.start; i < o.stop; i++) { if (intArray[i] == search) { Console.Write(i + " "); } } }
public void newClass_Property() { var test_instance = new newClass(); Assert.That(test_instance.TestProperty.Equals("Teststring")); }