C# 3.0 ile birlikte gelen yeniliklerden, otomatik özellikler ile artık kolay ve hızlı bir biçimde standart özellikler (property) tanımlayabiliyoruz.

Örneğin;

class Person
{
   public int No { get; set; }
   public string Ad { get; set; }
   public FizikselOzellik Ozellik { get; set; }
}

class FizikselOzellik
{
   public int Kilo { get; set; }
   public int Boy { get; set; }
   public string Cinsiyet { get; set; }
}

gibi. Aslında IL kodlarını incelersek, derleyicinin C# 2.0 daki gibi (arka planda bir field oluşturup, get ve set erişimcilerini otomatik kendisi yazıyor) özellik tanımladığını görebiliriz. Yeni gelen diğer bir özellik ise Nesneye Ilk Değerini verme ile ilgili. Aşağıdaki sentaks ile artık nesneleri oluştururken özelliklerine de ilk değerlerini vererek nesneyi oluşturabiliriz.


Person nesnemiz içerisinde özellik olarak FizikselOzellik isimli başka bir nesne içeriyor. Bu durumda da aşağıdaki sentaks ile Person nesnemize ilk değerini verebiliriz.,

Person p = new Person {
               
Ad="oguz",No=169,
               Ozellik = new FizikselOzellik{Kilo=120,Boy=173,Cinsiyet="E"}
};

Görüldüğü gibi C# 3.0 ile gelen yenilikleri dili kullanmayı daha hızlı, zevkli ve kolay bir hale getiriyor ;)

 
Monday, May 18, 2009 5:29:02 PM (GTB Daylight Time, UTC+03:00)
Hello everyone. Read over your compositions, and wherever you meet with a passage which you think is particularly fine, strike it out. Help me! There is an urgent need for sites: alcohol abuse treatment centers. I found only this - <a href="http://design.ru-deluxe.ru/">adobe photoshop cs2 ramki</a>. In addition to california alcohol treatment and drug rehab programs, we provide specialty services in the treatment of chronic pain and addiction. Find alcohol drug abuse information treatment in chicago, il yellowpages. Best regards :rolleyes:, Joseph from Botswana.
Friday, October 16, 2009 9:08:46 AM (GTB Daylight Time, UTC+03:00)
<h2 align="center">Costs For Uggs--What It Costs?</h2>
<p>--&gt;Are you lusting after a few (or even more) <a href="http://www.goodugg.co.uk/ugg-classic-cardy-c-161.html">Ugg boots</a> and if so, you're in good company, as girls and women of all ages, especially with the simple, slipper-like design of these sheepskin <a href="http://www.goodugg.co.uk/grey-ugg-boots-5819-classic-cardy-p-23458.html">ugg boots sale </a>, which are relatively easy and very comfortable to wear. And they appear to be affected. Some men are also jumping on the trend and luxury UGGs? Australia, the brand also offers a range of contemporary styles for them.</p>
<p>--&gt;Could you mind giving everyone loves from <a href="http://www.goodugg.co.uk/ugg-classic-tall-c-162.html">ugg classic </a>? There are so many types of uggs, <a href="http://www.goodugg.co.uk/ugg-bailey-button-c-178.html?zenid=847c0f495b87cb43928dcc19d09f4019">ugg bailey button</a>,ugg <a href="http://www.goodugg.co.uk/ugg-classic-tall-c-162.html">classic tall</a>, ugg <a href="http://www.goodugg.co.uk/ugg-classic-short-c-160.html">classic short</a>, ugg <a href="http://www.goodugg.co.uk/ugg-classic-cardy-c-161.html">classic cardy</a>. How to choose your favorite? Or do you really want to one uggs regardless its style? Despite their design is awkward and slipper-lile, <a href="http://www.goodugg.co.uk/">Uggs</a> is one of the few stations that are of general interest, have argued that cross generational lines.</p>
<p>--&gt;Young people, students and young mothers and the Middle Ages, the original Black <a href="http://www.goodugg.co.uk/ugg-ultra-tall-c-167.html">Ultra Tall UGG Boots</a>, seem pulled the fleecy-lined boots that are manufactured in Australia, with the best materials. Are you sure that your feet warm in winter without socks, and cool in summer so that is more versatile too? If no, hurry up to take one <strong>ugg boots </strong>on <a href="http://www.goodugg.co.uk/ugg-classic-tall-c-162.html">uggs on sale</a> ! That's why we see people wear them in schools, supermarkets, on the slopes and even in the most popular beaches in the United States and abroad. Many surfers also use uggs to keep their feet warm.</p>
<p>--&gt;What do you really care about? Is its price or quality, or you just following the general trend? You know what are you thinking in your heart!</p>
Saturday, November 14, 2009 10:20:14 AM (GTB Standard Time, UTC+02:00)
JFGLGHKLJ
Tuesday, December 22, 2009 3:14:03 AM (GTB Standard Time, UTC+02:00)
20091222c1ygy I wear <a href="http://www.boonoutlet.com/ugg-genuine-womens-nightfall-boots-black-p-1251.html">UGG Nightfall Boots on sale</a>is considered a kind of a fashion trend, this trend has affected the whole world. If you have not tried, then it is regrettable. With the advent of winter, <a href="http://www.boonoutlet.com/ugg-new-arrival-suede-boots-5230-black-p-1279.html">UGG New Arrival Suede Boots </a>online become popular up a lot of people can not wait to experience the feeling of wearing ugg prices ugg some people appear to be high, ugg boots online above ugg style good, <a href="http://www.boonoutlet.com/ugg-boots-gray-carved-in-pattern-on-hot-sale-p-1226.html">UGG Gray classic tall</a> are always welcome to many people as it is high quality and fashion design.For myself,i like this
<a href="http://www.boonoutlet.com/ugg-authority-classic-mini-boot-black-for-women-p-1014.html">UGG Classic Mini Boot </a> very much,you can have it and show yourself now,it is not let you downUgg Napoule Sandal,the price is not expensive. To meet your needs, make haste to experience the feeling of the trend.


Name
E-mail
Home page

Comment (HTML not allowed)  

Enter the code shown (prevents robots):

Live Comment Preview