Advertisement
Guest User

Quiz riflessivo per programmatori c#.

a guest
Jul 27th, 2011
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.58 KB | None | 0 0
  1. using System;
  2. using System.Linq;
  3.  
  4. namespace ConsoleApplication2
  5. {
  6.     class Program
  7.     {
  8.         static void Main(string[] args)
  9.         {
  10.             Type t = Type.GetType("ConsoleApplication2.X_Class");
  11.             var tt = t.GetProperties().Where(i => i.PropertyType.Equals(typeof(Zeta)));
  12.             foreach (var item in tt)
  13.             {
  14.                 Console.WriteLine(item.ToString());
  15.             }
  16.  
  17.             Console.ReadLine();
  18.         }
  19.     }
  20.  
  21.     class X_Class
  22.     {
  23.         public Zeta Y_Property { get; set; }
  24.     }
  25.  
  26.     class Zeta
  27.     {
  28.     }
  29.  
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement