tag:blogger.com,1999:blog-32032904270459981522024-03-13T14:26:26.923-07:00Project 11 Main Boardsimplicity - no alternativeJambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.comBlogger25125tag:blogger.com,1999:blog-3203290427045998152.post-78226875424349967812014-03-30T10:50:00.000-07:002014-06-20T07:54:41.708-07:00Serial Reader (პროექტი CL / C#)<br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-qgq3odOQxuo/UzhUYFiL6pI/AAAAAAAADOE/ot2zsaQ0Las/s1600/pr2.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-qgq3odOQxuo/UzhUYFiL6pI/AAAAAAAADOE/ot2zsaQ0Las/s1600/pr2.PNG" height="312" width="640" /></a></div><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">მოგესალმებით ჩემი მორიგი პოსტით, რომელიც შეიცავს ინფორმაციას სერიული წამკითხველის შესახებ (რესურს ფაილებსა და საინსტალაციო ვერსიას). ზემოთ მოცემული პროგრამა "Serial Reader" დავწერე C# ში .NET 4 CP პლათფორმაზე დაფუძნებით, რადგან მეოთხე ვერსია უფრო გავრცელებულია ვიდრე 4.5, სიახლის გამო. მოცემული პროგრამა პიდაპირ უმიზნებს და გამოიყენება <a href="http://tfmako.blogspot.com/2014/03/cl.html">სპექტრის ანალიზატორისთვის</a>, რომელიც შეგიძლიათ ნახოთ ჩემს ბლოგზე.</div><a name='more'></a>პროგრამა დაწერილია WF ის გამოყენებით. WPF ში უფრო დახვეწილი დიზაინი იქნებოდა, მაგრამ ჯერ ჯერობით ჩემს ინტერესებში არ შედის ვიზუალური მიმზიდველობა ამ პროგრამაში. რაც შეეხება ინტერფეისს საკმაოდ მარტივია, ფუნქციიდან გამომდინარე.<br /><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">პროგრამის ჩართვისას ირჩევთ სერიული პორტის სახელს, რომელზეც თქვენი არდუინოა მიერთებული ან რაიმე მოწყობილობა სერიული ინტერფერისით. ამის შემდგომ სერიული პორტის სიხშირეს და ვაჭერთ ღილაკს SC (Start Communication). ამის შემდეგ Serial Reader ფორმა გაუჩინარდება და გაიხსენება Graph ფორმა, რომელშიც პროგრამის ძირითადი ნაწილი სრუდება. </div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-uIBhOkFtklw/UzhUYaIFh9I/AAAAAAAADOA/aU0fa8YUcHs/s1600/pr1.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-uIBhOkFtklw/UzhUYaIFh9I/AAAAAAAADOA/aU0fa8YUcHs/s1600/pr1.PNG" /></a></div><div class="separator" style="clear: both; text-align: justify;">კომუნიკაციის პროტოკოლი კი შემდეგნაირია: კომპიუტერი უგზავნის char ტიპის ცვლადს მიკროპროცესორს (ჩემს შემთხვევაში 's') და მიკროპროცესორი ცნობს ამ სიმბოლოს. საპასუხოდ ის კომპიუტერს უგზავნის 128 ბაიტს, რომელსაც კომპიუტერი კითხულობს. გრაფიკის აფსცისათა ღერძი დაყოფილია 128 წერტილად, რადგან ინფორმაციის მოცულობა ამდენივეა, ხოლო ორდინატათა ღერძზე აიღება გამოგზავნილი ინფორმაციის შესაბამისი მნიშვნელობები. </div><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">მაგალითად:</div><div class="separator" style="clear: both; text-align: justify;">data [0] = 21;</div><div class="separator" style="clear: both; text-align: justify;">data [1] = 23;</div><div class="separator" style="clear: both; text-align: justify;">data [2] = 34;</div><div class="separator" style="clear: both; text-align: justify;">...</div><div class="separator" style="clear: both; text-align: justify;">data [127] = 54;</div><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">შესაბამისად აიღება კოორდინატები, სადაც პირველი კოორდინატი x ია ხოლო, მეორე y და i იცვლება 0-დან 127 მდე (<128). წერტილები კი ასე აიღება point ( i , data[i] ).</div><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">როდესაც დაიწყება კომუნიკაცია და გამოჩნდება მეორე, გრაფიკის ფორმა, კომუნიკაციის საბოლოოდ დასაწყებად საჭიროა გრაფიკზე დავაწკაპოთ, რაც საბოლოოდ უკვე მოგცემთ ვიზუალურ შედეგს, ამის შემდეგ, როდესაც უკვე საჭირო მუშაობას მორჩებით კიდევ ერთხელ უნდა დააჭიროთ გრაფიკზე და ის გაშეშდება, რაც იმას ნიშნავს, რომ კომუნიკაცია დასრულებულია. თუ ფორმას გამორთავთ გამოჩნდება საწყისი ფორმა, რომელიც საშუალებას მოგცემთ კომუნიკაციის ხელახლა დაწყების, თუ წინა არ გსურთ, მაშინ უბრალოდ საწყისი ფორმაც გამორთეთ. </div><div class="separator" style="clear: both; text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: justify;">ქვემოთ მოცემულია რესურს ფაილები, სადაც მთლიანი პროექტია მოცემული თავისი კოდი (<a href="https://drive.google.com/file/d/0B8INmvEfFu2zaFpqWlFieERNR2s/edit?usp=sharing">SourceFile</a>), ხოლო არის ასევე მზა საინსტალაციო პროგრამა, რომელიც მარტივად დასაყენებელია (<a href="https://drive.google.com/file/d/0B8INmvEfFu2zSWxnZUtWZzVnZUk/edit?usp=sharing">InstallFile</a>).</div><br />Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-31808982929719549162014-03-26T11:48:00.001-07:002014-06-20T07:54:41.764-07:00აუდიო სპექტრზე დაფუძნებულო ეკვალაიზერი<div dir="ltr"><br /></div><div class="separator" style="clear: both; text-align: left;"><a href="http://4.bp.blogspot.com/-qw_Mgw71Y9w/UzMddlWta1I/AAAAAAAAC88/dLDLYnyGSqc/s1600/IMG_20140324_224348+(1).jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-qw_Mgw71Y9w/UzMddlWta1I/AAAAAAAAC88/dLDLYnyGSqc/s1600/IMG_20140324_224348+(1).jpg" height="320" width="239" /></a><a href="http://4.bp.blogspot.com/-o_xJ-WgvNCc/UzMddZxQ0BI/AAAAAAAAC9A/mVle1wot9Tw/s1600/IMG_20140324_224359.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-o_xJ-WgvNCc/UzMddZxQ0BI/AAAAAAAAC9A/mVle1wot9Tw/s1600/IMG_20140324_224359.jpg" height="320" width="239" /></a></div><br /><div dir="ltr"><br /></div><div dir="ltr">ეს პროექტი დაფუძნებულია ჩემს წინა პროექტზე - სპექტრის ანალიზატორზე. ჩემი აზრით, ეს პროექტი საკმაოდ ლოგიკური გაგრძელებაა ძირითადი პროექტისა, რომელიც საკმაოდ რთული გამოდგა გასალეთებლად.</div><a name='more'></a>მოკლედ რომ მოვჭრა, გამაძლიერებლის სქემა იგივეა, რაც პროექტ <a href="http://tfmako.blogspot.com/2014/03/cl.html">CL </a>ში. კოდიც იმავეა, რაც ამ პროექტში, მაგრამ დამატებულია რამდენიმე მეთოდი, რომელიც უზრუნველყოფს სიხშირეების დეტექტირებას და 595 შიფტ რეგისტრის გავლით LED ის მართვას, რომელიც თავიდან რვა იყო, ახლა კი ოთხია, რაც, ჩემი აზრით აღარ არის საჭირო, რადგან ამ მიკროსქემის მართვას 3 პინი სჭირდება, ხოლო ერთი პინი, რომ დავამატოთ მივიღებთ 4 LED ის მართვას.<br /><div dir="ltr"><br /></div><div dir="ltr">აქ მოცემულია კოდი 595 შიფტ რეგისტრის სამართავად, რომელიც მე მაქვს გამოყენებული, ხოლო კიდევ დამატებულია სურათი, რომელიც საჭიროა 2 ჩიპის სამართავად, ხოლო ჩემს შემთხვევაში გამოყენებულია მხოლოდ ერთი</div><div dir="ltr"><br /></div><div class="separator" style="clear: both; text-align: left;"><a href="http://3.bp.blogspot.com/-dtXQhmVBxY8/UzMg0G8jq2I/AAAAAAAAC9Y/inF7CVMbFxM/s1600/1.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-dtXQhmVBxY8/UzMg0G8jq2I/AAAAAAAAC9Y/inF7CVMbFxM/s1600/1.PNG" height="400" width="241" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-gxYUAWYca9Y/UzMg2baKMSI/AAAAAAAAC9g/sBMT6-T4dF4/s1600/74HC595_4.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-gxYUAWYca9Y/UzMg2baKMSI/AAAAAAAAC9g/sBMT6-T4dF4/s1600/74HC595_4.png" height="358" width="400" /></a></div><div dir="ltr"><br /></div><div dir="ltr"><br /></div><div dir="ltr"><br /></div><div dir="ltr"><br /></div><div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.youtube.com/embed/sj5qqrdPFIw?feature=player_embedded' frameborder='0'></iframe></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.youtube.com/embed/TXWISNg1h00?feature=player_embedded' frameborder='0'></iframe></div><div dir="ltr"><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-11444016098835363182014-03-26T11:48:00.000-07:002014-06-20T07:54:41.747-07:00კონტექსტური მენიუ<div class="MsoNormal"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">მოგესალმებით</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";">, </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ქვემოთ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">მოცემულია</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">კონტექსტური</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">მენიუ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";">, </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">რომელიც</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">გაგიადვილებთ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ნავიგაციას</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">და</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">აღარ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">მოგიწევთ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ბლოგის</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ძველ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">პოსტებში</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ხეტიალი</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">სასურველი</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">პოსტის</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">აღმოსაჩენად</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";">, </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ყველაფერი</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">თავმოყრილი</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">იქნება</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">ერთ</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"> </span><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">პოსტში</span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div><table border="0" cellpadding="0" cellspacing="0" class="MsoNormalTable" style="border-collapse: collapse; mso-padding-alt: 0cm 0cm 0cm 0cm; mso-yfti-tbllook: 1184; width: 601px;"> <tbody><tr> <td style="background: #70AD47; border: solid #70AD47 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span lang="EN-US" style="color: white; font-size: 12.0pt; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">W P F</span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #70AD47; border-left: none; border: solid #70AD47 1.0pt; mso-border-left-alt: solid #70AD47 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><b><span lang="EN-US" style="color: white; font-size: 12.0pt; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">C #</span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/11/wpf-0.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">Windows Presentation Foundation</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/blog-post.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">ანონიმური მეთოდები</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/11/wpf-1."><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">კლასები და სახელსივრცეები</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://acerberus.tfmako.com/2013/12/lambda-expressions.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">Lambda Expressions</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/wpf-2.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">გეომეტრია</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/15.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">დელეგატებიში შესავალი</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/wpf-3.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">კონტროლების ტრანსფორმაცია</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/25.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">დელეგატების გამოყენება</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/wpf-4.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">ფუნჯები</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2014/01/35.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">BubbleSorter ალგორითმი</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><a href="http://tfmako.blogspot.com/2013/12/wpf-51-12.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">კონტროლები I</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><a href="http://tfmako.blogspot.com/2013/12/func-action.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">Action<T> და Func<T></span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><a href="http://tfmako.blogspot.com/2013/12/wpf-52-22.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">კონტროლები II</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2014/01/55-multicast-delegates.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">Multicast Delegates</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><a href="http://tfmako.blogspot.com/2013/12/wpf-6-layout.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">განლაგებები (Layout)</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2014/01/13.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">მოვლენის განმსაზღვრელი</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2013/12/wpf-62-17.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">სტილები და რესურსები I</span></a><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span><a href="http://tfmako.blogspot.com/2014/01/23.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">მოვლენის მსმენელი</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><a href="http://tfmako.blogspot.com/2013/12/wpf-62-27.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">სტილები და რესურსები II</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="background: #E2EFD9; border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.55pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2014/02/generics-in-c.html"><span lang="EN-US" style="font-size: 12.0pt; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">Generics in C#</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-top: none; border: solid #A8D08D 1.0pt; mso-border-top-alt: solid #A8D08D 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.25pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"> </span></b><a href="http://tfmako.blogspot.com/2013/12/wpf-73-37.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">სტილები და რესურსები III</span></a><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="padding: 0cm 0cm 0cm 0cm; width: 225.55pt;" width="301"></td> </tr></tbody></table><br /><br /><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><table border="1" cellpadding="0" cellspacing="0" class="MsoNormalTable" style="border-collapse: collapse; border: none; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="background: #70AD47; border: solid #70AD47 1.0pt; mso-background-themecolor: accent6; mso-border-alt: solid #70AD47 .5pt; mso-border-right-alt: solid #70AD47 1.0pt; mso-border-right-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themecolor: accent6; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.2pt;" valign="top" width="300"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="color: white; font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-themecolor: background1;">მიკრო პროცესორები</span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> <td style="border-bottom: solid #A8D08D 1.0pt; border: none; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-cell-special: placeholder;" width="1"><div class="MsoNormal"><br /></div></td> </tr><tr> <td colspan="2" style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-border-themetint: 153; mso-border-top-alt: solid #A8D08D .5pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.6pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"><a href="http://tfmako.blogspot.com/2014/01/i2c.html">I2C კომუნიკაციის პროტოკოლი</a></span></div></td></tr></tbody></table><br /><table border="1" cellpadding="0" cellspacing="0" class="MsoNormalTable" style="border-collapse: collapse; border: none; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="background: #70AD47; border: solid #70AD47 1.0pt; mso-background-themecolor: accent6; mso-border-alt: solid #70AD47 .5pt; mso-border-right-alt: solid #70AD47 1.0pt; mso-border-right-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themecolor: accent6; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.4pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><b><span style="color: white; font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-themecolor: background1;">ჩემი პროექტები</span></b><span style="font-family: "Times New Roman","serif"; font-size: 12.0pt; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-border-themetint: 153; mso-border-top-alt: solid #A8D08D .5pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.4pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="text-align: center;"><a href="http://tfmako.blogspot.com/2014/02/blog-post.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-bidi-font-weight: bold; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">პროექტი </span><span lang="EN-US" style="font-size: 12.0pt; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-bidi-font-weight: bold; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;">DVC</span></a><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: "Times New Roman"; mso-bidi-font-weight: bold; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin;"><o:p></o:p></span></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-border-themetint: 153; mso-border-top-alt: solid #A8D08D .5pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.4pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="margin-bottom: 0.0001pt; text-align: center;"><a href="http://tfmako.blogspot.com/2014/03/cl.html"><span style="font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;">სპექტრის ანალიზატორი (CL)</span></a><u><span style="color: blue; font-size: 12.0pt; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: "Times New Roman"; mso-fareast-font-family: "Times New Roman"; mso-fareast-language: "GEO\/KAT"; mso-hansi-font-family: Sylfaen;"><o:p></o:p></span></u></div></td> </tr><tr> <td style="background: #E2EFD9; border-top: none; border: solid #A8D08D 1.0pt; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-alt: solid #A8D08D .5pt; mso-border-themecolor: accent6; mso-border-themecolor: accent6; mso-border-themetint: 153; mso-border-themetint: 153; mso-border-top-alt: solid #A8D08D .5pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0cm 5.4pt 0cm 5.4pt; width: 225.4pt;" valign="top" width="301"><div align="center" class="MsoNormal" style="margin-bottom: 0.0001pt; text-align: center;"><a href="http://tfmako.blogspot.com/2014/03/blog-post.html">ეკვალაიზერი</a></div></td></tr></tbody></table><br /><div><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-36819207259425974232014-03-09T12:17:00.000-07:002014-09-07T04:02:12.129-07:00აუდიო სპექტრის ანალიზატორი (CL)<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-UCReJTEnY-w/Uxy2uJV0feI/AAAAAAAACzU/Ztx-P0yyjgk/s1600/Capture.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-UCReJTEnY-w/Uxy2uJV0feI/AAAAAAAACzU/Ztx-P0yyjgk/s1600/Capture.PNG" height="307" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
<a href="http://en.wikipedia.org/wiki/Spectrum_analyzer">სპექტრის ანალიზატორი</a> ზომავს ამპლიტუდის დამოკიდებულებას სიხშირეზე. ხოლო <a href="http://en.wikipedia.org/wiki/Spectrum_analyzer#Audio-frequency_uses">აუდიო სპექტრის ანალიზატორი</a> არის უფრო კონკრეტული და სპეციალიზებული, რომელიც ზომავს აუდიო სიხშირის დიაპაზონს 20 ჰერციდან 20 კილოჰერცამდე, მიუხედავად იმისა, რომ ადამიანს იშვიათად უწევს მაღალ სიხშირეებთან შეხვედრა. ქვემოთ მოცემულია ჩემი პროექტის აღწერა და იმპლემენტაციის გზა. </div>
<a href="https://www.blogger.com/null" name="more"></a><br />
<br />
პირველ რიგში ჩამოვთვლი საჭირო მასალას, რასაც საჭიროებს ამ პროექტის განხოციელება :<br />
<br />
1. გამაძლიერებლის სქემა, რომელიც ქვემოთ არის მოცემული (შენიშნვა, A წერტილში მდებარე C2 კონდესატორი მოვხსენი, რადგან ასე გახდა საჭირო ჩემს შემთხვევაში, თუ დაბრკოლება არ შეგიქმნათ, მაშინ დატოვეთ!)<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-nn8i2F7q61A/Uxy2veWOPPI/AAAAAAAACzs/rxbhwCngSwc/s1600/IMGP0251.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-nn8i2F7q61A/Uxy2veWOPPI/AAAAAAAACzs/rxbhwCngSwc/s1600/IMGP0251.JPG" height="374" width="640" /></a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
გამაძლიერებლისათვის კი შემდეგი ნაწილებია საჭირო</div>
<div class="separator" style="clear: both; text-align: justify;">
1) C2 | C3 | C4 = 2.2 მიკროფარადი</div>
<div class="separator" style="clear: both; text-align: justify;">
2) C1 = 1 მიკროფარადი, რომელიც 10 მიკროფარადით შევცვალე, პროექტის ინტერესებიდან გამომდინარე</div>
<div class="separator" style="clear: both; text-align: justify;">
3) R7 | R8 = 4.7K</div>
<div class="separator" style="clear: both; text-align: justify;">
4) R1 | R2 | = 50K - 50K ამ წინაღობების მთავარი აზრი ის არის, რომ მოხდეს ძაბვის გაყოფა შუა წერტილში</div>
<div class="separator" style="clear: both; text-align: justify;">
5) R3 | R4 | R5 | R6 - კი გაძლიერების კოეფიციენტებს არეგულირებენ, რომელიც შესაძლებელია ასე გამოითვალოს, პირველი გამაძლიერებლისათვის, R4 / R3 ხოლო მეორესათვის R6 / R5</div>
<div class="separator" style="clear: both; text-align: justify;">
6) C5 = 100 მიკროფარადი, რომელიც + სა და 0 ს შორის ირთვება</div>
<div class="separator" style="clear: both; text-align: justify;">
7) ელექტრონული მიკროფონი</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/--gFS3ShT7k4/Uxy2xrSnTBI/AAAAAAAAC0I/rymgpxh10aw/s1600/IMGP0259.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/--gFS3ShT7k4/Uxy2xrSnTBI/AAAAAAAAC0I/rymgpxh10aw/s1600/IMGP0259.JPG" height="240" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
8) და მიკროსქემა LM358 ან უბრალოდ დაბალ ხმაურიანი ერთჯერადი კვების საშუალების მქონე ოპ. გამაძლიერებელი. </div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-oNxlmYSJ_NE/Uxy2uCmXD2I/AAAAAAAACzg/CD4px887zMg/s1600/1.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-oNxlmYSJ_NE/Uxy2uCmXD2I/AAAAAAAACzg/CD4px887zMg/s1600/1.PNG" /></a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
სქემა მოკლედ, რომ აღვწერო, გვაქვს ელექტრონული მიკროფონი, რომელიც მარაგდება R7 + R8 წინაღობების გავლით, ეს ორი წინაღობა ჩემს შემთხვევაში შეიძლება ერთით შეცვალოთ, რადგან C2 ის გამოა ეს ყველაფერი. ამის შემდეგ სიგნალი შედის C1 ის გავლით ინვერტული გამაძლიერებლის ერთ კომპონენტში, რომელიც DC კომპონენტს ფილტრავს და ატარებს AC კომპონენტს. ამის შემდეგ ეს სიგნალი ძლიერდება და გადადის მეორე საფეხურზე. <b>რეკომენდირებულია</b>, რომ თითოეული გამაძლიერებლის კოეფიციენტი არ აღემატებოდეს 30ს. ხოლო აღნიშვნები FS და SS, გამოყვანილია x30, რომელსაც ვიყენებ და x900, რომელზეც საკმაოდ ძლიერი სიგნალი მოდის. </div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
<b>ძაბვა</b>, არის Arduino სთან თავსებადი, რაც იმას ნიშნავს, რომ 5 ვოლტი სავსებით საკმარისია, ხოლო თუ კიდევ 2 გამაძლიერებელ მოდულს დაამატებთ 3,3 ვოლტიც საკმარისი იქნება, მაგრამ უნდა არეგულიროთ გაძლიერების კოეფიციენტი, მე პირადად არ მიცდია. </div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
2. Arduino ს ნებისმიერი დაფა (Uno / Leonardo ჩემს შემთხვევაში), რომელსაც 1K ზე მეტი RAM ექნება, რადგან ინფორმაციის სწრაფი დამუშავებისათვის არის საჭირო. </div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
3. FFT ბიბლიოთეკა, რომელიც განთავსებულია შემდეგ <a href="http://wiki.openmusiclabs.com/wiki/ArduinoFFT">ლინკზე</a>, რომელიც აგზავნის 128 წერტილს (ჩემს შემთხვევაში. უფრო ნაკლებიც არის შესაძლებელი). </div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
4. კომპიუტერი, რომელსაც მე ამ ეტაპზე ვიყენებ გრაფიკის ასაგებად, მაგრამ ეს შესაძლებელია იყოს პროცესორზე მიერთებული თხევადკრისტალური დისფლეი ან LED მატრიცა</div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
5. პროგრამა, რომელიც ჯერ ბოლომდე არ არის დასრულებული და მხოლოდ საცდელი ვარიანტია. პროგრამის ხორცშესასხმელად დაგჭირდებათ System.IO.SerialPort კლასი, რომელიც Arduino ს დაუკავშირდება და სინქრონიზებულად იმუშავებს მასთან. </div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-lvaKR51lY-M/Uxy2wGaIS1I/AAAAAAAAC0Q/6M0UdP87bjk/s1600/IMGP0257.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-lvaKR51lY-M/Uxy2wGaIS1I/AAAAAAAAC0Q/6M0UdP87bjk/s1600/IMGP0257.JPG" height="240" width="320" /></a></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-gH3lY5C7uso/Uxy2vidRyzI/AAAAAAAACzw/ktqjQ2seGP8/s1600/IMGP0250.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-gH3lY5C7uso/Uxy2vidRyzI/AAAAAAAACzw/ktqjQ2seGP8/s1600/IMGP0250.JPG" height="240" width="320" /></a></div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-mzv4hRPEd9o/Uxy2xUOdbvI/AAAAAAAAC0E/6g_LgHpoQuA/s1600/IMGP0258.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-mzv4hRPEd9o/Uxy2xUOdbvI/AAAAAAAAC0E/6g_LgHpoQuA/s1600/IMGP0258.JPG" height="240" width="320" /></a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<div class="separator" style="clear: both; text-align: justify;">
დამატებითი ინფორმაციისთვის / პროექტთან დაკავშირებული იდეებისთვის <a href="http://tfmako.blogspot.com/search/label/ContactUs">მომწერეთ</a></div>
<div class="separator" style="clear: both; text-align: justify;">
<br /></div>
<br />Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-7865267542555673122014-02-18T00:08:00.000-08:002014-06-20T07:54:41.826-07:00Generics in C#<span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-McgUB41fSM8/UwJZuCIRt4I/AAAAAAAACC8/2NFLAOreTpo/s1600/images.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><span style="font-family: Arial, Helvetica, sans-serif;"><img border="0" src="http://1.bp.blogspot.com/-McgUB41fSM8/UwJZuCIRt4I/AAAAAAAACC8/2NFLAOreTpo/s1600/images.jpg" height="298" width="400" /></span></a></div><div style="margin: 2pt 0cm 0pt;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ტიპების მიმოხილვა</span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;">.NET 2.0 ვერსიის შემდეგ მომხმარებელს უკვე თავისუფლად შეუძლია გამოიყენოს ის თვისება, რასაც ზოგადი ტიპის ფენომენი ეწოდება პროგრამირების ენაში. ეს არ არის მხოლოდ C# ის ნაწილი. ეს არის მთლიანად IL (Intermediate Language) ის დიდი ოჯახის წევრი, რომელშიც ეს თვისება საკმაოდ კარგად არის ინტეგრირებული. ზოგადი ტიპების გამოყენებით, რომელსაც ამიერიდან generic ებით მოვიხსენიებ, მიუხედავად იმისა, რომ ქართული თარგმანიც არსებობს (ზოგადი „ტიპი“), შესაძლებელია ტიპზე დამოუკიდებელი კლასების, ინტერფეისების, მეთოდებისა და სტრუქტურების შექმნა. აღარ არის საჭირო ყოველი ტიპისთვის დაიწეროს სხვადასხვა ოპერაცია, რომლის ლოგიკა ერთია, მაგრამ ტიპია სხვადასხვა. უბრალოდ არსებობს უფრო მარტივი გზა - generics. </span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><a name='more'></a><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">მიუხედავად იმისა, რომ ამ სფეროში ხდება ტიპის საკმაოდ ღრმა განზოგადება, მაინც დაცულია ტიპობრივი უსაფრთხოება და შესაძლებელია შეზღუდვების ხელოვნური დაწესება, რომელსაც მოგვიანებით განვიხილავ. </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"></span><span style="font-family: Arial, Helvetica, sans-serif;"> </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"></span><span style="font-family: Arial, Helvetica, sans-serif;"> </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"></span><span style="font-family: Arial, Helvetica, sans-serif;"> </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"></span><span style="font-family: Arial, Helvetica, sans-serif;"> </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><a href="http://3.bp.blogspot.com/-RmJoJx2O8m0/UwJZuC6RsiI/AAAAAAAACDA/uke2zWMcvSA/s1600/11.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><span style="font-family: Arial, Helvetica, sans-serif;"><img border="0" src="http://3.bp.blogspot.com/-RmJoJx2O8m0/UwJZuC6RsiI/AAAAAAAACDA/uke2zWMcvSA/s1600/11.jpg" /></span></a><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">Generic ები არ არის ახალი კონსტრუქცია, რომელიც არ არსებობს სხვა ენებში. მაგალითისათვის რომ ავიღოთ C++ ის Template ებს გააჩნიათ რაღაც საერთო generic ებთან. არსებობს ასევე განსხვავებები, რომლებიც იმაში მდგომარეობს, რომ C++ ის template ები მოითხოვენ კოდის წყაროს, რომ გამოიყენოთ ენის ეს თვისება, ხოლო C# ში ეს არ არის მოთხოვნა, რადგან ეს კონსტრუქცია უფრო დაბალ დონეზეა განსაზღვრული - CLR ში. აქედან გამომდინარე შესაძლებელია .NET პლატფორმიდან რომელიმე ენაში განსაზღვრული ტიპი გამოიყენოთ როგორც generic ის ტიპი. </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">ქვემოთ მოცემულია რამდენიმე მაგალითი, რომლებიც ძალიან ზერელედ შეეხებიან ამ კონსტრუქციას, რადგან უკეთ გაიცნოთ ის, ხოლო ამის შემდეგ უკვე შემოგთავაზებთ უფრო ღრმა ინფორმაციას, რომელიც დაგანახებთ ამ ყველაფრის მნიშვნელობასა და generic ების გამოყენების შედეგად მიღებულ სიმარტივეს. </span></div><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">შესრულების უნარიანობა</span></span></span></span></h3><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">ერთ-ერთი ყველაზე დიდი დადებით მხარეთ შეიძლება ჩაითვალოს შესრულების უნარიანობა, რადგან კოლექციებთან მუშაობისას ჩანს ამ კონსტრუქციის დადებითი მხარე. არსებობს კოლექციები, რომლის ტიპი არის object და რომლის ტიპი შეგვიძლია განსაზღვრისას მივუთითოთ. ცვლადის ტიპის გამოყენებისას, არა generic კოლექციებში, ძალიან დიდი მოცულობის რესურსები მიდის value-type ცვლადის reference-type ცვლადში გადაფუთვაში და მისი წაკითხვისას ამ ოპერაციის პირიქით ჩატარებაში. </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">მომდევნო მაგალით იყენებს System.Collections.ArrayList კლასს, რომლის ობიექტში შეგვიძლია დავამატოთ ნებისმიერი ტიპის ობიექტი Add() მეთოდის გამოყენებით, რომლისა პარამეტრია თვით დასამატებელი ობიექტი. ამ პროცესის მსვლელობისას ერთი საინტერესო რამ ხდება. როდესაც ობიექტს ენიჭება value ტიპის ცვლადი, კომპილატორს ავტომატურად გადაჰყავს value ტიპის reference ტიპში, რასაც boxing/შეფუთვა ეწოდება. ხოლო მის უკან წასაკითხად საჭირო ხდება unboxing საჭირო, რაც შეფუთვის შებრუნებული პროცესია. ეს შებრუნებული პროცესი მაშინ ხდება, როდესაც მომხმარებელს სურს ArrayList ში მოთავსებული ინფორმაციის წაკითხვა, ანუ ობიექტი (რომელიც reference ტიპისაა) გარდაიქმნება value ტიპად. ახლა კი დროა იხილოთ მაგალითი</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Main(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">[] args)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">var</span><span style="background: white; color: black; mso-highlight: white;"> nonGenericList = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> System.Collections.</span><span style="background: white; color: #2b91af; mso-highlight: white;">ArrayList</span><span style="background: white; color: black; mso-highlight: white;">();</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">შეფუთვა</span><span style="background: white; color: green; mso-highlight: white;"> - value </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span><span style="background: white; color: green; mso-highlight: white;"> -> reference </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>nonGenericList.Add(44); </span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; mso-highlight: white;">//unboxing reference </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span><span style="background: white; color: green; mso-highlight: white;"> -> value </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> item0 = (</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">)nonGenericList[0]; </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">Boxing/unboxing ის პროცესი საკმაოდ მარტივი გამოსაყენებელია, მაგრამ რესურსების მხრივ საკმაოდ დიდი დანაკარგი მოჰყვება ამ მარტივ ტექნიკას, როდესაც კოლექციაში წევრთა რიცხვი იზრდება. ამის მაგივრად შესაძლებელია System.Collections.Generic.List<T> ის გამოყენება, რომელსაც T-ს ნაცვლად მიუთითებთ სასურველ ტიპს, რომელზეც მუშაობს მომხმარებელი და ამ შემთხვევაში boxing/unboxing ს უკვე აღარ აქვს ადგილი. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Main(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">[] args)</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">var</span><span style="background: white; color: black; mso-highlight: white;"> GenericList = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> System.Collections.Generic.</span><span style="background: white; color: #2b91af; mso-highlight: white;">List</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">არ</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ხდება</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">არანაირი</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">შეფუთვა</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>GenericList.Add(44);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(GenericList[0]);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ტიპობრივი უსაფრთხოება<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">სხვა თვისება რაც ამ კონსტრუქციას ახასიათებს არის ტიპობრივი უსაფრთხოება, რაც იმაში მდგომარეობს, რომ თუ განვიხილავთ ArrayList ის ქვემოთ მოცემულ შემთხვევას, ეს იმას ნიშნავს, რომ ამ ობიექტში ნებისმიერი ტიპის ცვლადის „ჩაყრა“ არის შესაძლებელი.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">nonGenericList.Add(231);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;">nonGenericList.Add(</span><span style="background: white; color: #a31515; mso-highlight: white;">"Giorgi"</span><span style="background: white; color: black; mso-highlight: white;">);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">nonGenericList.Add(</span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">new</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">object</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">());</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ახლა როდესაც მოვახდენთ კოლექციის წევრების ნახვის ოპერაციას <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">foreach</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> item </span><span style="background: white; color: blue; mso-highlight: white;">in</span><span style="background: white; color: black; mso-highlight: white;"> nonGenericList)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(item);</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">მოხდება ის, რომ პირველი წევრის წაკითხვის შემდეგ კომპილატორი ამოაგდებს შეცდომას, რაც იმით იქნება გამოწვეული, რომ მომხმარებელს არ შეუძლია განსაზღვროს რა სახის ტიპებია მოთავსებული ამ სიაში წინასწარ.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ამიტომ შეცდომა რაც შეიძლება ადრე უნდა იქნას არიდებული რაც იმაში გამოიხატება, რომ გამოიყენოთ generic კლასი - List<T>. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">var</span><span style="background: white; color: black; mso-highlight: white;"> genericList = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">List</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">genericList.Add(512);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">genericList.Add(2014);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">genericList.Add(</span><span style="background: white; color: #a31515; line-height: 107%; mso-highlight: white;">"sa"</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">); </span><span style="background: white; color: green; line-height: 107%; mso-highlight: white;">//</span><span style="background: white; color: green; line-height: 107%; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">შეცდომა</span><span style="background: white; color: green; line-height: 107%; mso-highlight: white;">, </span><span style="background: white; color: green; line-height: 107%; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">რაც</span><span style="background: white; color: green; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: green; line-height: 107%; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ავტომატურად</span><span style="background: white; color: green; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: green; line-height: 107%; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">დაფიქსირდა<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ორობითი კოდის ხელახალი გამოყენების საშუალება<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">რის საშუალებასაც იძლევა generic ები. ეს იმას ნიშნავს, რომ ზოგადი ტიპის კლასი შეიძლება განისაზღვროს მხოლოდ ერთხელ და მოხდეს მისი გამოყენება ნებისმიერ ტიპთან თუ რა თქმა უნდა არ დაწესდა ტიპის შეზღუდვა (რასაც ამ სტატიაში ავხსნი მოგვიანებით). C++ ის Template ებისგან განსხვავებით აქ არ არის საჭირო კოდის წყაროზე წვდომა და როგორც ზემოთ აღვნიშნე .NET ის ერთ ენაში განსაზღვრული ზოგადი ტიპის კლასის გამოყენება სრულებით შესაძლებელია .NET პლატფორმის ნებისმიერ სხვა ენაზე.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">კოდის მოცულობა<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;">ამ ინფორმაციის ძებნისას ბევრი რამის გარკვევა მომიხდა და შემიძლია აღვნიშნო, რომ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C# </span><span style="background: white; mso-highlight: white;">და სხვა .</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NET </span><span style="background: white; mso-highlight: white;">ის პლატფორმაზე დაწერილი კოდი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">IL </span><span style="background: white; mso-highlight: white;">ში გადასვლისას ზოგადი ტიპის კლასებს ათავსებს ასამბლეაში. როდესაც ხდება ამ კლასის გამოყენება სხვა ტიპებისათვის არ გეგონოთ, რომ იქმნება ზოგადი ტიპის კლასის ასლი ზუსტად ამ ტიპისთვის. არა, უბრალოდ ყველა კლასი იყენებს ადგილობრივ კლასს, ხოლო მოგვიანებით </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JIT </span><span style="background: white; mso-highlight: white;">კომპილატორის გამოყენებით საჭიროებისამებრ იქმნება ზოგადი ტიპის კლასის მითითებულ ტიპზე ორიენტირებული ვერსია. შექმნამდე კი უბრალოდ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">32 </span><span style="background: white; mso-highlight: white;">ბიტიან<span style="mso-spacerun: yes;"> </span>სისტემაში 4 ბიტიანი მისამართი ინახება ზოგადი ტიპის კლასისა. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">სახელების დარქმევა და ერთგვარი გიდი<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ჩვეულებრივი კლასებისაგან გასარჩევად ჩემი პირადი რჩევაა, რომ გამოიყენოთ შემდეგი მითითებები, რომლებსაც მე ვიყენებ და თავის დროზე ინტერნეტის საშუალებით ვისწავლე<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpFirst" style="margin: 0cm 0cm 0pt 36pt; mso-list: l6 level1 lfo10; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings; mso-highlight: white;"><span style="mso-list: Ignore;">Ø<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Generic </span><span style="background: white; mso-highlight: white;">ების პრეფიქსი უნდა იყოს ასო </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T (</span><span style="background: white; mso-highlight: white;">ინტერნეტიდან)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpLast" style="margin: 0cm 0cm 8pt 36pt; mso-list: l6 level1 lfo10; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings; mso-highlight: white;"><span style="mso-list: Ignore;">Ø<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; mso-highlight: white;">რადგან ზოგადი ტიპი უნდა ჩანაცვლდეს სხვა კერძო, განსაზღვრული ტიპით, დროებით მარკერად გამოიყენეთ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T (</span><span style="background: white; mso-highlight: white;">ინტერნეტი, რჩევა). </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Class List<T> {<span style="mso-tab-count: 1;"> </span>}</span><span style="background: white; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="color: #1f4d78;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><o:p>ზოგადი ტიპის კლასები</o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;">ზოგადი ტიპის კლასის შესაქმნელად უბრალოდ საჭიროა ზემოთ მოცემული მასალის კარგად გაანალიზება და ცოტაოდენი ექსპერიმენტის ჩატარება რაც უკვე ნელ-ნელა პრაქტიკაში გადავა. ქვემოთ გთავაზობთ ორ კლასს, რომელთაგან ერთი გამოიყენებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">generics </span><span style="background: white; mso-highlight: white;">ხოლო მეორე უბრალოდ იქნება მომხმარებლის მიერ განსაზღვრული მაგალითი, რომელსაც </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Item </span><span style="background: white; mso-highlight: white;">ეწოდება, და რომლის კოდიც ქვემოთაა მოცემული. წარმოიდგინეთ, რომ ეს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Item (</span><span style="background: white; mso-highlight: white;">ნივთი)</span><span style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">არის რაღაც კლასი, რომელსაც აქვს სახელი და მოკლე აღწერა. ეს კლასიც საკმაოდ ზოგადია, მაგრამ არა პროგრამირების მხრივ. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Item</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> _name;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Name<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> _name;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">if</span><span style="background: white; color: black; mso-highlight: white;"> (</span><span style="background: white; color: blue; mso-highlight: white;">value</span><span style="background: white; color: black; mso-highlight: white;"> != </span><span style="background: white; color: blue; mso-highlight: white;">null</span><span style="background: white; color: black; mso-highlight: white;">)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>_name = </span><span style="background: white; color: blue; mso-highlight: white;">value</span><span style="background: white; color: black; mso-highlight: white;">;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> _description;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Descr<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> _description;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">if</span><span style="background: white; color: black; mso-highlight: white;"> (</span><span style="background: white; color: blue; mso-highlight: white;">value</span><span style="background: white; color: black; mso-highlight: white;"> != </span><span style="background: white; color: blue; mso-highlight: white;">null</span><span style="background: white; color: black; mso-highlight: white;">)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>_description = </span><span style="background: white; color: blue; mso-highlight: white;">value</span><span style="background: white; color: black; mso-highlight: white;">;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> Item(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> itemName, </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> itemDescription)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>Name = itemName;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>Descr = itemDescription;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">override</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> ToString()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">.Format(</span><span style="background: white; color: #a31515; mso-highlight: white;">"{0} - {1}"</span><span style="background: white; color: black; mso-highlight: white;">, Name, Descr);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ახლა კი თამაშში შემოდის generic ები. ჩემს მიერ წარმოდგენილი კლასი არის უბრალოდ სია, რომელშიც შესაძლებელია მონაცემების დამატება, რომლის ტიპი მომხმარებლის სურვილზეა დამოკიდებული. ასევე შესაძლებელია მონაცემების წაშლა და მთლიანი სიის მიღება. იმის მაგივრად, რომ List<T> ს მაგალითზე მსგავსი კლასი შემექმნა, უბრალოდ List<T> ზე დაყრდნობით შევქმენი ზოგადი ტიპის კლასი, რაც, ჩემი აზრით უფრო გაუადვილებს დამწყებებს ზოგად ტიპებზე ფოკუსირებას და არ გაფანტავს თქვენს ყურადღებას List<T> ის კონსტრუქციაზე და ერთი შეხედვით რთულ კოდზე. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">GenericList</span><span style="background: white; color: black; mso-highlight: white;"><Type><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">List</span><span style="background: white; color: black; mso-highlight: white;"><Type> internalList = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">List</span><span style="background: white; color: black; mso-highlight: white;"><Type>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> AddItem(Type item)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>internalList.Add(item);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> RemoveItem(Type item)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">if</span><span style="background: white; color: black; mso-highlight: white;"> (internalList.Contains(item))<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>internalList.Remove(item);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">List</span><span style="background: white; color: black; mso-highlight: white;"><Type> GetList()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> internalList;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">საკმაოდ მარტივია List<T> ის გამოყენება, რომელიც იმავე ტიპს მიიღებს, რომელსაც GenericList<Ttpe> კლასის ჩემეული იმპლემენტაცია. ახლა კი ვნახოთ გამოყენების მაგალითი, რომელიც int და Item ტიპზე მაქვს გაკეთებული და საკმაოდ მარტივადაც გამოიყურება.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Main(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">[] args)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">GenericList</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">> integerList = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">GenericList</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>integerList.AddItem(2013);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>integerList.AddItem(2014);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">GenericList</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Item</span><span style="background: white; color: black; mso-highlight: white;">> list = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">GenericList</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Item</span><span style="background: white; color: black; mso-highlight: white;">>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>list.AddItem(</span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Item</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: #a31515; mso-highlight: white;">"C#"</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: #a31515; mso-highlight: white;">"programing language"</span><span style="background: white; color: black; mso-highlight: white;">));<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>list.AddItem(</span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Item</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: #a31515; mso-highlight: white;">"C#"</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: #a31515; mso-highlight: white;">"</span><span style="background: white; color: #a31515; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">პროგრამირების</span><span style="background: white; color: #a31515; mso-highlight: white;"> </span><span style="background: white; color: #a31515; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ენა</span><span style="background: white; color: #a31515; mso-highlight: white;">"</span><span style="background: white; color: black; mso-highlight: white;">));<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">მიუხედავად იმისა, რომ მაგალითი პრიმიტიული მოგეჩვენოთ, საკმაოდ კარგად ჩანს ზოგადი ტიპების ძალა. ამის შემდგომ თქვენ შეგიძლიათ ნებისმიერი ტიპისთვის შექმნათ სია, მიუხედავად იმისა, რომ ეს იმპლემენტაცია უკვე არსებობს, თქვენი იდეების განხორციელების საშუალებას მოგცემთ ზემოთ მოცემული მაგალითი. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">Generic ების თვისებები<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">როდესაც ვქმნით ზოგად კლასებს, საჭირო ხდება რაღაც თვისებების გამოყენება, რომელიც სიტუაციურია და საკმაოდ სასარგებლო სამუშაოსას ასრულებს რიგ შემთხვევებში. მაგალითისთვის ვიტყვი, რომ თუ გვსურს, რომ ცვლადი განვსაზღვროთ და არ მივანიჭოთ მას მნიშვნელობა ასე მოვიქცევით<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">string</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> variable = </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">null</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">;</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">რაც აბსოლუტურად </span><span style="background: white; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>ნებადართულია, ხოლო თუ ამას ზოგადი ტიპის კლასებისთვისაც გამოვიყენებთ ვნახავთ, რომ VS შეცდომას ამოგვიგდებს, რადგან ზემოთ მოცემული მაგალითი ზოგადი ტიპის კლასებისთვის ასე „გადაიწერება“<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">Type variable = </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">default</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">(Type);</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">რომელიც მოთავსებულია GenericList<Type> კლასში და წარმოადგენს ველს. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="color: #1f4d78;"><span style="background: white; mso-highlight: white;">შეზღუდვები</span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">თუ ზოგად კლასს სჭირდება, რომ გამოიძახოს მეთოდი ზოგადი ტიპის გავლით, ამ დროს საჭიროა შეზღუდვის დამატება. მოცემული მაქვს DocManager<T> კლასი, რომელსაც გააჩნია ViewAll() მეთოდი. ასევე არის Document კლასი, რომელიც უკეთებს IDoc ინტერფეისს იმპლემენტაციას თვისებებით Title და Content.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">interface</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">IDoc</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Title { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Content { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Document</span><span style="background: white; color: black; mso-highlight: white;">: </span><span style="background: white; color: #2b91af; mso-highlight: white;">IDoc</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> Document()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> Document(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> title, </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> content)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">.Title = title;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">.Content = content;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Title { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> Content { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">დოკუმენტების საჩვენებლად DocManager<T> ის გამოყენებით, შესაძლებელია T ტიპის ინტერფეისში გადაყვანა, რომ ვნახოთ დოკუმენტის სათაური. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> ViewAll()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">foreach</span><span style="background: white; color: black; mso-highlight: white;"> (T doc </span><span style="background: white; color: blue; mso-highlight: white;">in</span><span style="background: white; color: black; mso-highlight: white;"> docQueue)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(((</span><span style="background: white; color: #2b91af; mso-highlight: white;">IDoc</span><span style="background: white; color: black; mso-highlight: white;">)doc).Title);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">პირველადი კოდი დაახლოებით ასეთი სახის იქნება, რომელსაც T ტიპი გადაჰყავს ინტერფეისში და რადგან კომპილერმა იცის, რომ IDoc ინტერფეისს აქვს Title თვისება, თვლის, რომ ზემოთ დაწერილი კოდი სრულფასოვანია და ეს რეალურადაც ასეა. აქ არსებობს ერთი პრობლემა, რომლიც მაშინ წამოიჭრება, თუ DocManager<T> კლასში, ტიპი T არ უკეთებს IDoc ინტერფეისს იმპლემენტაციას. ამ პრობლემის თავიდან ასაცილებლად საჭიროა, რომ T ტიპს დავუწესოთ შეზღუდვა, რომელიც შეამოწმებს იმას მოცემული T ტიპი უკეთებს თუ არა IDoc ინტერფეისს იმპლემენტაციას. ამისთვის კი დაგვჭირდება where საკვანძო სიტყვა და ქვემოთ მოცემული კლასის იმპლემენტაცია.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">DocManager</span><span style="background: white; color: black; mso-highlight: white;"><T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">where</span><span style="background: white; color: black; mso-highlight: white;"> T: </span><span style="background: white; color: #2b91af; mso-highlight: white;">IDoc</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">private</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">readonly</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Queue</span><span style="background: white; color: black; mso-highlight: white;"><T> docQueue = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Queue</span><span style="background: white; color: black; mso-highlight: white;"><T>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> ViewAll()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">foreach</span><span style="background: white; color: black; mso-highlight: white;"> (T doc </span><span style="background: white; color: blue; mso-highlight: white;">in</span><span style="background: white; color: black; mso-highlight: white;"> docQueue)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(doc.Title);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> AddDoc(T doc)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">lock</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>docQueue.Enqueue(doc);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">bool</span><span style="background: white; color: black; mso-highlight: white;"> IsDocAvailable<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;"> { </span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> docQueue.Count > 0; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-bidi-font-family: Consolas; mso-highlight: white;">შესაბამისად რადგან შეზღუდვა მოხსნილია შეგიძლიათ, რომ ტიპის გადაყვანა არც გააკეთოთ და პირდაპირ გამოიტანოთ დოკუმენტის სახელი. ახლა კი ამ ყველაფრის მოქმედებაში მოსაყვანად უნდა განვიხილოთ main მეთოდის კოდი, სადაც ვიყენებ Document კლასის ტიპს DocManager<T> ისათვის, რომელიც იმპლემენტაციას უკეთებს IDoc ინტერფეისს. </span><span style="background: white; color: blue; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Main(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">[] args)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">var</span><span style="background: white; color: black; mso-highlight: white;"> dm = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">DocManager</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Document</span><span style="background: white; color: black; mso-highlight: white;">>();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>dm.AddDoc(</span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Document</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: #a31515; mso-highlight: white;">"Title 1"</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: #a31515; mso-highlight: white;">"Content 1"</span><span style="background: white; color: black; mso-highlight: white;">));<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>dm.AddDoc(</span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Document</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: #a31515; mso-highlight: white;">"Title 2"</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: #a31515; mso-highlight: white;">"Content 2"</span><span style="background: white; color: black; mso-highlight: white;">));<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>dm.ViewAll();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ახლა DocManager<T> მუშაობს ნებისმიერ კლასთან, რომელიც იმპლემენტაციას უკეთებს IDoc ინტერფეისს. არსებობს კიდევ რამდენიმე საშუალება შეზღუდვების დასაწესებლად.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpFirst" style="margin: 0cm 0cm 0pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; line-height: 107%; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">A.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">struct</span><span style="background: white; color: blue; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; line-height: 107%; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">B.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: blue; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; line-height: 107%; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">C.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">interface</span><span style="background: white; color: blue; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; line-height: 107%; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">D.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Document</span><span style="background: white; color: #2b91af; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; line-height: 107%; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">E.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">new</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> ()</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpLast" style="margin: 0cm 0cm 8pt 39.25pt; mso-add-space: auto; mso-list: l4 level1 lfo11; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">F.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">class</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Sample</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><T><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">where</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> T: M</span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">შეზღუდვის 6 ვარიანტი არსებობს და აქვე გავარჩევ თითოეულს<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpFirst" style="margin: 0cm 0cm 0pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">A.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">სტრუქტურული შეზღუდვა, სადაც </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">უნდა იყოს </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">value-type<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">B.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">კლასობრივი შეზღუდვა, სადაც </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">უნდა იყოს </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">reference-type<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">C.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Where T: interface </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ნიშნავს, რომ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ტიპი აუცილებლად უნდა უკეთებდეს </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">interface </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">(ნებისმიერი სხვა მითითებული ინტერფეისი) სს იმპლემენტაციას, როგორც ეს ზემოთ მოცემულ მაგალითში გავაკეთე</span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">D.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Where T: Document</span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">, სადაც </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Document </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">კლასი ჩემს მიერ სადემონსტრაციო კლასია (შეიძლება იყოს ნებისმიერი კლასი) და ეს შეზღუდვა ითვალისწინებს იმას, რომ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ტიპი აუცილებლად უნდა იყოს მემკვიდრე კლასი </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Document </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ისა</span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpMiddle" style="margin: 0cm 0cm 0pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">E.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Where T: new() </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">შეზღუდვა ნიშნავს იმას, რომ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ტიპს აუცილებლად უნდა ჰქონდეს სტანდარტული კონსტრუქტორი</span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoListParagraphCxSpLast" style="margin: 0cm 0cm 8pt 36pt; mso-list: l8 level1 lfo12; text-align: justify; text-indent: -18pt;"><!--[if !supportLists]--><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Sylfaen; mso-bidi-theme-font: minor-latin; mso-highlight: white;"><span style="mso-list: Ignore;">F.<span style="font-family: "Times New Roman"; font-size-adjust: none; font-stretch: normal; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"> </span></span></span><!--[endif]--><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ასეთი რამის გაკეთებაც არის შესაძლებელი. ეს შეზღუდვა ნიშნავს იმას, რომ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">T </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">უნდა იყოს </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">M </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ზოგადი ტიპის მემკვიდრე. ამას ეწოდება </span><i style="mso-bidi-font-style: normal;"><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">naked type constraint</span></i><i style="mso-bidi-font-style: normal;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">. </span></i><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ასევე არსებობს ისეთი შემთხვევები, როდესაც შეზღუდვების სია გვაქვს<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Sample</span><span style="background: white; color: black; mso-highlight: white;"><T> <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">where</span><span style="background: white; color: black; mso-highlight: white;"> T: </span><span style="background: white; color: #2b91af; mso-highlight: white;">IDoc</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;">()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">მემკვიდრეობითობა<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ამ ფენომენზე საკმაოდ მოკლედ მომიწევს საუბარი, რადგან ბევრი არც არის სათქმელი და გასაგები მათთვის ვინც კარგად ერკვევა მემკვიდრეობითობის მექანიზმში, ხოლო დამწყებთათვის, ალბათ, მოგვიანებით პოსტში მოუწევთ ამის გარჩევა ან სხვა რესურსის გამოყენება. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადმა ტიპმა შეიძლება გაუკეთოს ზოგად ინტერფეისს იმპლემენტაცია. იგივეა შესაძლებელი კლასის მემკვიდრეობისას. ზოგადი კლასი შეიძლება იყოს ზოგადი კლასის მემკვიდრე<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Base</span><span style="background: white; color: black; mso-highlight: white;"><T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Derived</span><span style="background: white; color: black; mso-highlight: white;"><T>: </span><span style="background: white; color: #2b91af; mso-highlight: white;">Base</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">decimal</span><span style="background: white; color: black; mso-highlight: white;">><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">მოთხოვნა ის არის, რომ ინტერფეისის ზოგადი ტიპი უნდა გამეორდეს, ან საბაზო კლასის ტიპი უნდა იქნას მითითებული. როგორც ზემოთაა გაკეთებული. სწორედ ასე შესაძლებელია, რომ მემკვიდრე კლასი შეიძლება იყოს ზოგადი ან არა. მაგალითად, რომ შევქმნა აბსტრაქტული ზოგადი საბაზო კლასი, ის იმპლემენტირებული უნდა რომელიმე კონკრეტული ტიპით მემკვიდრე კლასის განსაზღვრისას. ეს საშუალებას გაძლევთ შექმნათ კერძო ტიპისთვის სპეციალიზაცია, რაც იმას ნიშნავს, რომ ასეთი რამ იქნება<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">abstract</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Base</span><span style="background: white; color: black; mso-highlight: white;"><T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">abstract</span><span style="background: white; color: black; mso-highlight: white;"> T Add(T var1, T var2);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">abstract</span><span style="background: white; color: black; mso-highlight: white;"> T Sub(T var1, T var2);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Derived</span><span style="background: white; color: black; mso-highlight: white;"><T>: </span><span style="background: white; color: #2b91af; mso-highlight: white;">Base</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;">><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">override</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> Add(</span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> var1, </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> var2)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> var1 + var2;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">override</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> Sub(</span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> var1, </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> var2)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> var1 + var2;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">აბსტრაქტული Base კლასის გამოყენებით შექმნილია Derived კლასი, რომელიც სპეციალიზდება double ტიპისთვის. თქვენ სურვილისებრ შეგიძლიათ შექმნათ string ტიპისათვის და ასე შემდეგ.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">სტატიკური წევრები<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ტიპის კლასებისათვის სტატიკური წევრები მოითხოვენ ყურადღებას. სტატიკური წევრები ზიარდებიან კლასის მხოლოდ ერთ ობიექტში. მაგალითით იმედია ამას უკეთ გადმოვცემ, სადაც StaticDemo<T> კლასი შეიცავს სტატიკურ ველს sm<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">StaticDemo</span><span style="background: white; color: black; mso-highlight: white;"><T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> sm;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">რადგანაც ქვემოთ მოცემულია კლასის ორი სხვადასხვა ტიპის ობიექტი, ეს იმას ნიშნავს, რომ ამ კლასისთვის შეიქმნა ორი სხვა კლასი, სადაც ორივეს ცალკე სტატიკური წევრები აქვს<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Main(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">[] args)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">StaticDemo</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>.sm = 21;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">StaticDemo</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">decimal</span><span style="background: white; color: black; mso-highlight: white;">>.sm = 512;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(</span><span style="background: white; color: #2b91af; mso-highlight: white;">StaticDemo</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>.sm); </span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">წერს</span><span style="background: white; color: green; mso-highlight: white;"> 21 </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ს</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Console</span><span style="background: white; color: black; mso-highlight: white;">.WriteLine(</span><span style="background: white; color: #2b91af; mso-highlight: white;">StaticDemo</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">decimal</span><span style="background: white; color: black; mso-highlight: white;">>.sm = 512); </span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">წერს</span><span style="background: white; color: green; mso-highlight: white;"> 512 </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ს</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ზოგადი ტიპის ინტერფეისები<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ტიპების გამოყენება ისევე როგორც კლასებთან, შესაძლებელია ინტერფეისებთან. ამის გარდა, .NET ფლათფორმაც საკმაოდ მრავლად ზოგადი ტიპის შემცველ ინტერფეისს მოიცავს და გვთავაზობს. მაგალითისათვის შემიძლია დაგისახელოთ IComparable<T>, IExtensibleObject<T>, ICollection<T> და სხვა. ინტერფეისის განსაზღვრა საკმაოდ მარტივია, რომელიც იქნება ზოგადი ტიპის, ეს ნაწილი არ მოითხოვს დიდი განმარტებების გაკეთებას, ისედაც ყველაფერი გასაგებია. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ამ ნაწილში ყურადღება გასამახვილებელია იმაზე თუ რამდენად დაიხვეწა კოდი და შემცირდა ხაზები ახალ ვერსიაში. .NET ის წინა (1.0) ვერსიაში საჭირო იყო ქვემოთ მოცემული კოდის დაწერა, რომ IComparable ინტერფეისის იმპლემენტაცია მომხდარიყო. ზოგადად IComparable ინტერფეისის კოდი ასეთია, რომელიც არ იყენებს generic ებს<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">namespace</span><span style="background: white; color: black; mso-highlight: white;"> System<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">interface</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">IComparable</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> CompareTo(</span><span style="background: white; color: blue; mso-highlight: white;">object</span><span style="background: white; color: black; mso-highlight: white;"> obj);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; line-height: 107%; mso-highlight: white;">}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;">: </span><span style="background: white; color: #2b91af; mso-highlight: white;">IComparable</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">არა</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ზოგადი</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> LastName { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> CompareTo(</span><span style="background: white; color: blue; mso-highlight: white;">object</span><span style="background: white; color: black; mso-highlight: white;"> obj)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;"> other = obj </span><span style="background: white; color: blue; mso-highlight: white;">as</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;">;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">.LastName.CompareTo(other.LastName);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">როდესაც ვიყენებთ ზოგადი ტიპის ინტერფეისს, ამ დროს აღარ არის ტიპის გადაყვანა, როგორც მე გავაკეთე object -> Person<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;">: </span><span style="background: white; color: #2b91af; mso-highlight: white;">IComparable</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;">> </span><span style="background: white; color: green; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ზოგადი</span><span style="background: white; color: green; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ტიპი</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> LastName { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> CompareTo(</span><span style="background: white; color: #2b91af; mso-highlight: white;">Person</span><span style="background: white; color: black; mso-highlight: white;"> other)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">.LastName.CompareTo(other.LastName);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">კო და კონტრა ვარიანტულობა<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">.NET 4 მდე ყველა ინტერფეისი იყო ინვარიანტული. ხოლო ამ ვერსიაში C# ში დაამატეს ისეთი რამ რაც არის კო და კონტრა ვარიანტულობა, რომელმაც მოიცვა ინტერფეისები და დელეგატები. კო და კონტრა ვარიანტულობა არის კონვერტაცია არგუმენტის ტიპსა და დასაბრუნებელ ტიპებს შორის. მაგალითისათვის რომ ავიღოთ ასეთი რამ: არის თუ არა შესაძლებელი Rectangle ტიპის არგუმენტის გატარება იმ მეთოდში, რომლის პარამეტრი არის Shape ტიპის? ეს არის ხშირად გამოყენებადი მაგალითი და სწორედ ამ მაგალითს გავარჩევ.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">როგორც ცნობილია Rectangle კლასი არის Shape კლასის მემკვიდრე. ხოლო განვსაზღვრავ Show(Shape obj) { } მეთოდს, რომელიც გამოიყენება Shape ტიპის ობიექტის მისაღებად. ამის შემდეგ შეგიძლიათ ამ მეთოდში გაატაროთ იმ ტიპის არგუმენტი, რომელიც მემკვიდრეა Shape კლასისა, მაგალითად, Rectangle. ქვემოთ მოცემული სინტაქსი აბსოლუტურად აკმაყოფილებს ნორმებს და არ არის არანაირი შეცდომა. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> rec = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> { Width = 21, Height = 2 };<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; line-height: 107%; mso-highlight: white;">Show(rec);</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">მეთოდის დასაბრუნებელი ტიპები არიან კონტრა ვარიანტულები, რაც იმას ნიშნავს, რომ როდესაც მეთოდი აბრუნებს Shape ტიპს არ შეიძლება Rectangle ტიპის დაბრუნება, რადგან არ არის აუცილებელი Shape იყოს Rectangle ყოველთვის, ხოლო საპირისპირო რამ შესაძლებელია. თუ მეთოდი აბრუნებს Rectangle ტიპის ობიექტს, როგორც ქვემოთაა მოცემული<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">public</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> ShowRec();</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ამ მეთოდის მიერ დაბრუნებული ობიექტი შეიძლება ასე გამოვიყენოთ<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Shape</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> s = ShowRec();</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">.NET 4 მდე ზოგადი ტიპებისათვის მსგავსი რამ დაუშვებელი იყო. ხოლო გაფართოების შემდეგ ზოგადმა ტიპებმა შეძლეს კო და კონტრა ვარიანტულობის გამოყენება, კერძოდ დელეგატებსა და ინტერფეისებში. ახლა კი განვსაზღვრავ იმ კლასებს, რომლებიც საჭირო იქნება შემდეგი მაგალითების დემონსტრირებისათვის<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> W { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">double</span><span style="background: white; color: black; mso-highlight: white;"> H { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; </span><span style="background: white; color: blue; mso-highlight: white;">set</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">override</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> ToString()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">.Format(</span><span style="background: white; color: #a31515; mso-highlight: white;">"W = {0} || H = {1}"</span><span style="background: white; color: black; mso-highlight: white;">, W, H);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> : </span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">კო ვარიანტულობა Generic ინტერფეისებში<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ინტერფეისი არის კო ვარიანტული თუ ზოგადი ტიპი მონიშნულია out საკვანძო სიტყვის გამოყენებით. ეს მეორე მხრივ, იმასაც ნიშნავს, რომ T ტიპი დაშვებულია მხოლოდ დასაბრუნებელ ობიექტებზე. ჩემს მიერ განსაზღვრული ინტერფეისი IIndexed არის კო ვარიანტული T ტიპის და აბრუნებს ამ ტიპს მხოლოდ წაკითხვის უნარის მქონე ინდექსერის საშუალებით<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">interface</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">IIndexed</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">out</span><span style="background: white; color: black; mso-highlight: white;"> T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>T </span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">[</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> index] { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> Size { </span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;">; }<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-bidi-font-size: 9.5pt; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">მოცემული ინტერფეისი იმპლემეტირებულია RecLib კლასში. RecLib განსაზღვრავს Rectangle ს ზოგადი ტიპის T სთვის<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">RecLib</span><span style="background: white; color: black; mso-highlight: white;"> : </span><span style="background: white; color: #2b91af; mso-highlight: white;">IIndexed</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;">><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">private</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;">[] collection = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;">[3]<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> {W = 3, H = 5},<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> {W = 5, H = 3},<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> {W = 2, H = 2}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>};<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">RecLib</span><span style="background: white; color: black; mso-highlight: white;"> GetCollection()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">RecLib</span><span style="background: white; color: black; mso-highlight: white;">();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">this</span><span style="background: white; color: black; mso-highlight: white;">[</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> index]<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">if</span><span style="background: white; color: black; mso-highlight: white;"> (index < 0 || index > collection.Length)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">throw</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">ArgumentOutOfRangeException</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: #a31515; mso-highlight: white;">"index"</span><span style="background: white; color: black; mso-highlight: white;">);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> collection[index];<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> Size<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">get</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> collection.Length;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">RecLib.GetCollection() მეთოდი აბრუნებს Collection, რომელიც იმპლემენტაციას უკეთებს IIndexed<Rectangle> ინტერფეისს, ამიტომ შესაძლებელია რომ დაბრუნებული მნიშვნელობა დაენიშნოს rectangle ცვლადს ტიპით IIndexed<Rectangle>. რადგანაც ინტერფეისი არის კო ვარიანტული ისიც კი არის შესაძლებელი, რომ მიღებული ცვლადი დაენიშნოს ობიექტს ტიპით IIndexed<Shape>. Shape არაფერი არ სჭირდება მეტი, რაც შეიძლება Rectangle მა შესთავაზოს. ამ ყველაფრის უკეთ აღსაქმელად იხილეთ ქვემოთ მოცემული კოდი <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> MainWindow()<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>InitializeComponent();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">IIndexed</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; mso-highlight: white;">> rectangles = </span><span style="background: white; color: #2b91af; mso-highlight: white;">RecLib</span><span style="background: white; color: black; mso-highlight: white;">.GetCollection();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">IIndexed</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;">> shapes = rectangles;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">for</span><span style="background: white; color: black; mso-highlight: white;">(</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> i = 0; i < shapes.Size; i++)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">MessageBox</span><span style="background: white; color: black; mso-highlight: white;">.Show(shapes[i].ToString());<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">კონტრა ვარიანტულობა Generic ინტერფეისებში<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ტიპის ინტერფეისი კონტრა ვარიანტულია თუ ზოგადი ტიპი მონიშნულია in საკვანძო სიტყვით. ასეთ შემთხვევაში ინტერფეისს საშუალება ეძლევა ზოგადი ტიპი გამოიყენოს მხოლოდ „შესავალ“ ტიპად თავისი მეთოდებისათვის. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">interface</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">IShow</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">in</span><span style="background: white; color: black; mso-highlight: white;"> T><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Show(T obj);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">class</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">ShowShape</span><span style="background: white; color: black; mso-highlight: white;"> : </span><span style="background: white; color: #2b91af; mso-highlight: white;">IShow</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;">><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">public</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Show(</span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;"> obj)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; mso-highlight: white;">MessageBox</span><span style="background: white; color: black; mso-highlight: white;">.Show(</span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;">.Format(</span><span style="background: white; color: #a31515; mso-highlight: white;">"{0} , {1}, {2}"</span><span style="background: white; color: black; mso-highlight: white;">, obj.H, obj.W, obj.GetType().Name));<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ახალი ობიექტი შექმნისას, ტიპით, ShowShape აბრუნებს IShow<Shape>, რომელიც ენიშნება shapeDisplay ცვლადს. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: #2b91af; mso-highlight: white;">IShow</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; mso-highlight: white;">Shape</span><span style="background: white; color: black; mso-highlight: white;">> shapeDisplay = </span><span style="background: white; color: blue; mso-highlight: white;">new</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; mso-highlight: white;">ShowShape</span><span style="background: white; color: black; mso-highlight: white;">();<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">IShow</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><</span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">Rectangle</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">> rectangleDisplay = </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">new</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; line-height: 107%; mso-highlight: white;">ShowShape</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">();</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ზოგადი ტიპის სტრუქტურები<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">კლასების მსგავსად სტრუქტურებიც შესაძლებელია იყოს ზოგადი ტიპის. ისინი ძალიან გვანან ზოგად კლასებს, მხოლოდ მემკვიდრეობითობის გამოკლებით. მაგალითისათვის მოვიყვან სტრუქტურა Nullable<T>, რომელიც განსაზღვრულია .NET გარემოში. შესადარებლად ვიღოთ მონაცემთა ბაზებში არსებული რიცხვი და C# ში არსებული რიცხვი. მონაცემთა ბაზაში შეიძლება, რომ იყოს NULL, ხოლო C# ში ეს დაუშვებელია, რადგან Int32 არის სტრუქტურა და რადგან სტრუქტურები არიან value-type მათი ნულად წარმოდგენა შეუძლებელია. ეს პრობლემა იჭრება მაშინაც, როდესაც საქმე ეხება XML მონაცემების დაკავშირებას .NET მონაცემების ტიპებთან. ეს თავისტკივილი იწვევს ზედმეტი სამუშაოს შესრულებას, რომელიც სპეციალურად დაკავშირებას ეხება. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;">მეორე მხრივ სტრუქტურა </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Nullable<T> </span><span style="background: white; mso-highlight: white;">ის გამოყენების შემდეგ პრობლემას მარტივი გადაწყვეტა უჩნდება. <o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ზოგადი ტიპის მეთოდები<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;">ზოგადი ტიპის ექსპანსიამ მეთოდებიც მოიცვა და შესაძლებელია ზოგადი ტიპის გამოყენება მეთოდებში, რომელიც მეთოდის განსაზღვრისას ეთითება.</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><o:p></o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Swap<T>(</span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> T x, </span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> T y)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>T tempV;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>tempV = x;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>x = y;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>y = tempV;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">განსაზღვრა და მათი გამოყენება (ქვემოთ არის მოცემული) ძალზედ მარტივია. ხოლო ეს პოპულარული მეთოდი ზოგადი ტიპის გამოყენებით უფრო პოპულარული ხდება და საკმაოდ რუტინულ კოდის ეფექტური მომგვარებელია. ასევე შესაძლებელია ისეთი მეთოდის განსაზღვრა, რომელიც რაიმე ტიპზე შეასრულებს მოქმედებებს, ან ამ ტიპის მემკვიდრეზე - ანუ ზოგადი ტიპის მეთოდი ტიპობრივი შეზღუდვებით.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> </span><span style="background: white; color: blue; mso-highlight: white;">void</span><span style="background: white; color: black; mso-highlight: white;"> Swap<T>(</span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> T x, </span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> T y)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">where</span><span style="background: white; color: black; mso-highlight: white;"> T : </span><span style="background: white; color: #2b91af; mso-highlight: white;">Program</span><span style="background: white; color: black; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>T tempV;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>tempV = x;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>x = y;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>y = tempV;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span lang="EN-US" style="background: white; color: black; line-height: 107%; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Program </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ის მაგივრად შესაძლებელია ნებისმიერი კლასის მითითება, ეს უბრალოდ მაგალითია. </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Swap<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">მეთოდის გამოძახება, რომელიც მოცემულია შეზღუდვის გარეშე, შემდეგნაირად არის შესაძლებელი.<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt 35.4pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> a = 3;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;"> b = 32;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>Swap<</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>(</span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> a, </span><span style="background: white; color: blue; mso-highlight: white;">ref</span><span style="background: white; color: black; mso-highlight: white;"> b);<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Arial, Helvetica, sans-serif; mso-highlight: white;"><o:p> </o:p></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> fs = </span><span style="background: white; color: #a31515; mso-highlight: white;">"string N1"</span><span style="background: white; color: black; mso-highlight: white;">;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">string</span><span style="background: white; color: black; mso-highlight: white;"> ss = </span><span style="background: white; color: #a31515; mso-highlight: white;">"string N2"</span><span style="background: white; color: black; mso-highlight: white;">;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>Swap<</span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">string</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;">>(</span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">ref</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> fs, </span><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">ref</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> ss);</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">ზოგადი ტიპის მეთოდების გამოყენება ასევე შეიძლება დელეგატებთან<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><h3 style="margin: 2pt 0cm 0pt;"><span style="font-size: small;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; mso-highlight: white;"><span style="color: #1f4d78;">ზოგადი ტიპის მეთოდები დელეგატებთან<o:p></o:p></span></span></span></span></h3><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; mso-highlight: white;">static</span><span style="background: white; color: black; mso-highlight: white;"> T GetEqual<T>(T x, T y)<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>{<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="mso-spacerun: yes;"> </span>y = x;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; mso-highlight: white;">return</span><span style="background: white; color: black; mso-highlight: white;"> y;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span><span style="background: white; color: black; line-height: 107%; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Arial, Helvetica, sans-serif;">აზრს მოკლებული მეთოდია, მაგრამ მაგალითისათვის გამოდგება. მეთოდი იღებს ორ ზოგადი ტიპის ცვლადს და მეორეს უტოლებს პირველს, შემდეგ კი აბრუნებს მეორეს. Main ფუნქციაში ამის გამოძახება შემდეგნაირად მოხდება<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: #2b91af; mso-highlight: white;">Func</span><span style="background: white; color: black; mso-highlight: white;"><</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">, </span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">> MyDel = GetEqual<</span><span style="background: white; color: blue; mso-highlight: white;">int</span><span style="background: white; color: black; mso-highlight: white;">>;<o:p></o:p></span></span></div><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Arial, Helvetica, sans-serif;"><span style="background: white; color: blue; line-height: 107%; mso-highlight: white;">int</span><span style="background: white; color: black; line-height: 107%; mso-highlight: white;"> result = MyDel(2,3);</span></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><span style="font-family: Arial, Helvetica, sans-serif;"></span><br /><span style="font-family: Arial, Helvetica, sans-serif;">ინფორმაციის გამოყენების შემთხვევაში გთხოვთ </span><a href="http://tfmako.blogspot.com/search/label/ContactUs"><span style="font-family: Arial, Helvetica, sans-serif;">მომწეროთ</span></a></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-70880049931050458502014-02-09T11:30:00.000-08:002014-06-20T07:54:41.872-07:00პროექტი <-DVC-><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-R0CGKHoKQlI/UvfPMX6zsrI/AAAAAAAABw0/JBK3IJi4YEA/s1600/20140208_224110.jpg" imageanchor="1"><img alt="" border="0" src="http://3.bp.blogspot.com/-R0CGKHoKQlI/UvfPMX6zsrI/AAAAAAAABw0/JBK3IJi4YEA/s1600/20140208_224110.jpg" height="372" title="" width="400" /></a></div> გამარჯობათ, ეს არის ჩემს მიერ ბოლო დროს გაკეთებული პროექტი, რომელიც საკმაოდ სახალისო და ამავე დროს საინტერესოა ჩემთვის, რომელიც იყენებს ახალ AtMega32 ჩიპს, რომელსაც აქვს USB კომუნიკაციის მხარდაჭერა პირდაპირ კომპიუტერთან რაიმე FTDI ჩიპის გამოყენების გარეშე, რაც აქამდე ასე თუ ისე მოყვარულთათვის დიდი თავის სატკივარი იყო. <br /><br />პროექტის განვითარების ფარგლებში იდეების მოწოდება შეგიძლიათ ქვემოთ - კომენტარებში, ან მეილის გამოყენებით - <a href="mailto:Giorgi.jambazishvilI@gmail.com">Giorgi.jambazishvilI</a><a href="https://www.blogger.com/null">@gmail.com</a><br /><a name='more'></a><br />ამ ვერსიაში, რომელიც პირველია და ყველაზე ახალი, იმპლემენტირებულია თაგვის (მაგრამ მე მოვიხსენიებ როგორ მაუსს) თითქმის სრული ვარიანტი, თუ არ ჩათვლით შუა ღილაკს, რომელიც საჭიროა კონტექსტში ნავიგაციისთვის, მაგრამ ეს არ არის პრობლემა, რადგან უფრო დიდი გეგმები მაქვს განსახორციელებელი ამ მოწყობილობასთან დაკავშირებით.<br /><br />დავიწყებ აღწერით, რომელიც მთლიანად მოიცავს იმ ასორტიმენტს, რომელიც ძირითად როლს თამაშობს ამ მოწყობილობაში. <br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-4xMTgl_MS9Y/UvfWZOI2MpI/AAAAAAAABxE/jBYhEUGq5Hw/s1600/20140208_223512.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-4xMTgl_MS9Y/UvfWZOI2MpI/AAAAAAAABxE/jBYhEUGq5Hw/s1600/20140208_223512.jpg" height="320" width="240" /></a></div><br />1) ხელთათმანი, რომელზეც მოწყობილია ეს ყველაფერი. უფრო კარგი იქნება თუ მთლიან ხელს არ დაიკავებს და უბრალოდ ადვილად <br />დასამაგრებელ/მოსაშორებელი რამ იქნება მაგრამ მომავლისთვის<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-6Lkwbg0v5KQ/UvfWfqHA4cI/AAAAAAAABxM/e2jTA0uQaNA/s1600/20140208_223607.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-6Lkwbg0v5KQ/UvfWfqHA4cI/AAAAAAAABxM/e2jTA0uQaNA/s1600/20140208_223607.jpg" height="320" width="240" /></a></div><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-IgeZrsynTdY/UvfWl47H-1I/AAAAAAAABxw/DgX41Hy04zQ/s1600/adxl345-1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"></a> </div><br />2) იზოლაციის ლენტა, რომელიც ამ პროექტზე "ოხრად" არის გამოყენებული, ვიზუალური მხარის გაუთვალისწინებლად<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-LpWgN-k_7IU/UvfWlSWw7QI/AAAAAAAABxs/z0a_s12qsRc/s1600/20140208_224122.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-LpWgN-k_7IU/UvfWlSWw7QI/AAAAAAAABxs/z0a_s12qsRc/s1600/20140208_224122.jpg" height="240" width="320" /></a></div><br />3) ფოლგა, რომელიც ნებისმიერ მაღაზიაში უნდა იყიდებოდეს, საკმაოდ კარგი რაღაცაა და ბევრი რამის გაკეთებაა შესაძლებელი. ჩემს შემთხვევაში კი ეს ერთგვარ ღილაკად არის გაკეთებული<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-cHl90cxo5NM/UvfWlPBhnvI/AAAAAAAABxk/-wEVp-Y9j58/s1600/20140208_223910.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-cHl90cxo5NM/UvfWlPBhnvI/AAAAAAAABxk/-wEVp-Y9j58/s1600/20140208_223910.jpg" height="240" width="320" /></a></div><br />4) პროცესორი, რომელიც უფრო კომფორტულს ხდის მაუსის მოძრაობის პროცესს. ამას ყოველთვის იმიტომ ავღნიშნავ, რომ როდესაც სულ თავიდან აქსელერომეტრიდან აღებული სიგნალები გადავგზავნე კომპიუტერში მაუსის გასამოძრავებლად, რაღაც კორიდის ხარის მსგავსი დაუმორჩილებელი კურსორი მივიღე. ამის შემდეგ დავიწყე სიგნალის დამუშავება და ჟესტიკულაციის ამოცნობის ალგორითმის დამატება. ასევე პროცესორის "წყალობითაა", რომ კომპიუტერს ეს ხელსაწყო მაუსი ჰქონია<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-6BXjfa2Go8c/UvfWl-G3iEI/AAAAAAAABx0/skFUZO8Ho5Y/s1600/20140208_224257.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-6BXjfa2Go8c/UvfWl-G3iEI/AAAAAAAABx0/skFUZO8Ho5Y/s1600/20140208_224257.jpg" height="240" width="320" /></a></div><br />5) კარგი უნარი და ბაზა C/C++, მაგრამ მაინც უფრო C ში, რადგან C++ იდან კლასებს არ ვიყენებ და შეუძლებელიცაა ესეთ პატარა პროცესორში ამ ყველაფრის ჩადება<br /><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-3uclvTILsu8/UvfW3pZxuGI/AAAAAAAABx8/b-UIJZZ90Zo/s1600/20140208_223816.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-3uclvTILsu8/UvfW3pZxuGI/AAAAAAAABx8/b-UIJZZ90Zo/s1600/20140208_223816.jpg" height="320" width="240" /></a></div><br />მუშაობის მთავარი პრინციპი ის არის, რომ თუ დავიწყებთ ხელიდან და გავუყვებით USB შესაერთებლამდე ვნახავთ, რომ ყველაფერი საკმაოდ ჭკვიანურად არის მოწყობილი. ხელიდან გამოდის 5 ხაზი, რომელიდანაც 2 ემსახურება VCC სა და GND (+3.3V და 0V). კიდევ ორი - SDA და SCL <a href="http://tfmako.blogspot.com/2014/01/i2c.html">(TWI ინტერფეისი)</a> და ერთიც მაუსის ღილაკებისათვის. თავიდან შეიძლება უცნაურად მოგეჩვენოთ როგორ ხდება ორი ღილაკის ინფორმაციის გადაცემა ერთი ხაზით, მაგრამ უფრო უცნაურად ის მოგეჩვენებათ, რომ გითხრათ, რომ ამ ერთი ხაზის გამოყენებით შესაძლებელია ხელზე 50 დან 200 მდე ღილაკი მოვითავსო ხელზე და ისე გამოვიყენო ისინი, როგორც მომინდება. ეს ყველაფერი კი უბრალო ანალოგური პინის (მიკრო პროცესორზე), პროგრამისა და წინაღობების დამსახურებაა. <br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-IgeZrsynTdY/UvfWl47H-1I/AAAAAAAABx4/Nf_jzhh5_eo/s1600/adxl345-1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-IgeZrsynTdY/UvfWl47H-1I/AAAAAAAABx4/Nf_jzhh5_eo/s1600/adxl345-1.jpg" height="291" width="320" /></a></div><br />როდესაც ამ ხუთი ხაზის გავლით ინფორმაცია გადაიგზავნება მიკროპროცესორში, ამის შემდეგ იწყება ყველაზე მთავარი - მათი დამუშავება, რაც საკმაოდ "სატანჯველია", მაგრამ შედეგზე ფიქრი მეხმარებოდა. როდესაც ყველაფერი კარგად "გაიწმინდება" და ინფორმაცია გადამუშავდება ისე, რომ მზად იყოს კომპიუტერში გადასაგზავნად, ამის შემდეგ უკვე კომპიუტერის მოტყუებას აქვს ადგილი, როცა პროცესორი მას მაუსი ჰქონია, მაგრამ ეს ასეც არის. <br /><br />ბოლოს კი ვიდეო<br /><div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen='allowfullscreen' webkitallowfullscreen='webkitallowfullscreen' mozallowfullscreen='mozallowfullscreen' width='320' height='266' src='https://www.youtube.com/embed/7q-7RPvTsLk?feature=player_embedded' frameborder='0'></iframe></div><br /><br /><em>დროის გამოჩენის პარალელურად გავაგრძელებ განახლებებზე და დახვეწაზე მუშაობას, რასაც ამ ბლოგზე დავდებ...</em><br /><em></em><br /><em>გიორგი ჯამბაზიშვილი (G.J)</em><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-39854287001733307552014-01-31T06:33:00.000-08:002014-06-20T07:54:41.883-07:00I2C კომუნიკაციის პროტოკოლი<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/en/1/19/I2clogo.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://upload.wikimedia.org/wikipedia/en/1/19/I2clogo.jpg" /></a></div><div class="MsoNormal" style="text-align: justify;">I კვადრატ <span lang="EN-US">C, </span>არის მრავალ მაკონტროლებიანი სერიული დისტრიბუტორი. გამოგონებულ იქნა <span lang="EN-US">Phillips Semiconductor </span>დანაყოფის მიერ. მისი გამოყენება ძირითადად ხდება დედა დაფებისთვის დაბალი სიხშირის პერიფერიების მიერთებისთვის. ასევე გამოიყენება ჩაშენებულ სისტემებში, მობილურ ტელეფონებში და სხვა ციფრულ მოწყობილობებში. </div><a name='more'></a><br /><div class="MsoNormal" style="text-align: justify;"><o:p></o:p></div><div class="MsoNormal" style="text-align: justify;">ტექნოლოგიების განვითარებასთან ერთად 1982 წლიდან 2012 წლამდე კომუნიკაციის სიჩქარე 100 კილო ჰერციდან გაიზარდა 5 მეგა ჰერცამდე (შედარებისთვის 5000 კილო ჰერცი). საბოლოო ვერსია არის 5, რომელშიც გამოსწორებული წინა ვერსიის შეცდომები. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;">მთავარი აზრი ის არის, რომ <span lang="EN-US">I2C </span>იყენებს ორ უნივერსალურ (ორმაგი მიმართულების) ხაზს. <span lang="EN-US">Serial Data </span>და <span lang="EN-US">Serial Clock</span>, შესაბამისად - <span lang="EN-US">SDA </span>და <span lang="EN-US">SCL </span>ხაზს, რომელიც აწეულია წინაღობებით. გააჩნია 7 / 10 ბიტიანი მისამართის სივრცე, რომელიც გამოყენებულ მოწყობილობებზეა დამოკიდებული. სტანდარტული ინფორმაციის გაცვლის მდგომარეობა არის 100kbit/<span lang="EN-US">s. </span><o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><br /></span></div><div class="MsoNormal" style="text-align: justify;">კომუნიკაციის მხრივ არსებობს 4 გარემოება, რომელიც შესაძლებელია წარმოიშვას:<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoListParagraphCxSpFirst" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->1.<span style="font-size: 7pt;"> </span><!--[endif]-->მაკონტროლებელი<span lang="EN-US"> (master)</span><span lang="EN-US"> </span>კვანძი უგზავნის მონაცემს დაქვემდებარებულს (<span lang="EN-US">slave)</span><o:p></o:p></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->2.<span style="font-size: 7pt;"> </span><!--[endif]-->მაკონტროლებელი იღებს ინფორმაციას დაქვემდებარებულიაგან<o:p></o:p></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->3.<span style="font-size: 7pt;"> </span><!--[endif]-->დაქვემდებარებული კვანძი უგზავნის მაკონტროლებელს ინფორმაციას<o:p></o:p></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->4.<span style="font-size: 7pt;"> </span><!--[endif]-->დაქვემდებარებული კვანძი იღებს ინფორმაციას მაკონტროლებლისგან<o:p></o:p></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-Mped9y6d4zA/UuuzTYaOwlI/AAAAAAAABwM/GyZVWeTIMmE/s1600/gs.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-Mped9y6d4zA/UuuzTYaOwlI/AAAAAAAABwM/GyZVWeTIMmE/s1600/gs.PNG" height="178" width="400" /></a></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><br /></div><div class="MsoNormal" style="text-align: justify;"> <v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"> <v:stroke joinstyle="miter"> <v:formulas> <v:f eqn="if lineDrawn pixelLineWidth 0"> <v:f eqn="sum @0 1 0"> <v:f eqn="sum 0 0 @1"> <v:f eqn="prod @2 1 2"> <v:f eqn="prod @3 21600 pixelWidth"> <v:f eqn="prod @3 21600 pixelHeight"> <v:f eqn="sum @0 0 1"> <v:f eqn="prod @6 1 2"> <v:f eqn="prod @7 21600 pixelWidth"> <v:f eqn="sum @8 21600 0"> <v:f eqn="prod @7 21600 pixelHeight"> <v:f eqn="sum @10 21600 0"> </v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"> <o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="_x0000_i1025" style="height: 176.25pt; width: 376.5pt;" type="#_x0000_t75"> <v:imagedata o:title="Capture" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape><o:p></o:p></div><div class="MsoNormal" style="text-align: justify;">როგორც აღვნიშნე <span lang="EN-US">I2C </span>კომუნიკაცია საკმაოდ მარტივია და ძალუძს რამდენიმე მოწყობილობას შორის გაცვალოს ინფორმაცია მხოლოდ 2 ინფორმაციის მიმოცვლის ხაზის გამოყენებით. ყველაზე მარტივ ფორმაში არსებობს მაკონტროლებელი მოწყობილობა, რომელსაც შეუძლია აკონტროლოს დაქვემდებარებული რამდენიმე მოწყობილობა. აღსანიშნავია ის ფაქტი, რომ <span lang="EN-US">SCL, </span>ანუ რომ იმპულსების ხაზს აკონტროლებს მაკონტროლებელი მოწყობილობა. კომუნიკაციის დასამყარებლად მაკონტროლებელი მოწყობილობა აგზავნის 1 ბაიტ ინფორმაციას, რომელშიც შერეულია დაქვემდებარებული მოწყობილობის მისამართი (<span lang="EN-US">ID)</span><span lang="EN-US"> </span>და ჩაწერა/წაკითხვის 1 ბიტიანი მანიშნებელი. თუ განსაზღვრულია ჩაწერის ოპერაცია, მაშინ მაკონტროლებელი მოწყობილობა დაიწყებს ინფორმაციის გაგზავნას იმავე მისამართზე. ხოლო თუ 1 ბიტი მიუთითებს იმაზე, რომ წაკითხვა უნდა შესრულდეს, მაშინ დაქვემდებარებული მოწყობილობა გაგზავნის ინფორმაციას, რომელსაც წაიკითხავს მთავარი მოწყობილობა (მაკონტროლებელი). ტრანზაქციების გასაკონტროლებლად მთავარი და დაქვემდებარებული მოწყობილობები აკონტროლებენ <span lang="EN-US">SCL </span>და <span lang="EN-US">SDA </span>ხაზებს, რომელმაც შეიძლება შემდეგი მნიშვნელობები მიიღოს: <span lang="EN-US">START, STOP, ACK, NAK. </span>ბოლო ორი შესაბამისად <span lang="EN-US">acknowledged </span>და <span lang="EN-US">no acknowledge. </span>მდგომარეობის დეტალები უკვე იმართება სპეციალური დრაივერების დახმარებით. <span lang="EN-US"><v:shape id="_x0000_i1026" style="height: 53.25pt; width: 159pt;" type="#_x0000_t75"> <v:imagedata o:title="Capture1" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image002.png"></v:imagedata></v:shape><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-ymaFk-oiF1E/UuuzZNtlZxI/AAAAAAAABwY/MEgHE0nMk9Q/s1600/bm.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-ymaFk-oiF1E/UuuzZNtlZxI/AAAAAAAABwY/MEgHE0nMk9Q/s1600/bm.PNG" height="117" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US">R/W - </span>წაკითხვა/ჩაწერა, <span lang="EN-US">Slave Address </span>- დაქვემდებარებულის მისამართი.<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">ელექტრონულად გამართულობის მხრივ, მოთხოვნები საკმაოდ მარტივია. მთავარმა და დაქვემდებარებულმა უნდა გამოიყენონ ერთი და იმავე დონის ძაბვა (შენიშვნა 1)<span lang="EN-US">. Pull-up </span>წინაღობების მნიშვნელობა დაახლოებით გამოითვლება კავშირის სრულ ტევადობაზე დაყრდნობით, მაგრამ 1.8<span lang="EN-US">K </span>დან 10K მდე, პრაქტიკულად, შესაძლებელია ნებისმიერი წინაღობის გამოყენება (შენიშვნა 2).<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">სხვადასხვა მიკრო პროცესორი ამ კომუნიკაციის იმპლემენტაციას სხვადასხვაგვარად ახორციელებს. ზოგიერთმა შეიძლება გამოიყენოს <span lang="EN-US">USI </span>(<span lang="EN-US">Universal Serial Interface)</span>, რომელიც ასევე გამოდგება <span lang="EN-US">SPI </span>კომუნიკაციებისათვის, ხოლო ზოგიერთს გააჩნია სპეციალურად ჩაშენებული <span lang="EN-US">TWI </span>(<span lang="EN-US">Two Wire Interface)</span><span lang="EN-US"> </span>კერძოდ <span lang="EN-US">I2C </span>კომუნიკაციებისათვის. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">როგორც აღვნიშნე <span lang="EN-US">I2C </span>მოწყობილობების მისამართი არის 7 ბიტიანი +1 ბიტი ჩაწერა/წაკითხვა. ამიტომ აქედან გამომდინარე 127 მოწყობილობის დაკავშირებაა შესაძლებელი მხოლოდ ორი ხაზის გამოყენებით. როგორც ზემოთ არის ნაჩვენები (მისამართის სურათი) 7 ბიტი წანაცვლებულია 1 ბიტით და ბოლო პირველი ბიტი გამოყენებულია, როგორც ჩაწერა/წაკითხვის მანიშნებელი. ზოგჯერ არის ისეთი შემთხვევები, როდესაც საჭირო ხდება დაქვემდებარებული მოწყობილობის მისამართის განსაზღვრა ფიზიკურად - დაფაზე. ხშირად ბოლოდან 4 ბიტი განსაზღვრულია წინასწარ და მომხმარებელს უწევს 3 ბიტის ფიზიკურად კონფიგურაცია. მსგავსი რამ შეიძლება შეგხვდეთ გარე მახსოვრობის მიკრო სქემების სარგებლობისას. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">არსებობს ასევე ისეთი გამონაკლისი შემთხვევები, როდესაც 1 მოწყობილობა იყენებს რამდენიმე მისამართს. ასეთი სიტუაცია შეიძლება შეგექმნათ <span lang="EN-US">EEPROM </span>ებთან მუშაობისას, რომლებიც გარე მახსოვრობას წარმოადგენენ. დავუშვათ, რომ ავიღოთ, <span lang="EN-US">24C16 </span>ჩიპი, რომლის მახსოვრობა 16<span lang="EN-US">K</span><span lang="EN-US"> </span>ბაიტია, ამ დროს მონაცემთა ოდენობის გაზრდის პარალელურად (როგორც აღვნიშნეთ მისამართის ბოლოდან პირველი 4 ბიტი განსაზღვრულია, კერძოდ - 1010) აღარ არის საჭირო 2-4 (ჩათვლით) ბიტების ფიზიკური კონფიგურაცია, რადგან აზრი არ აქვს. ამიტომ მთელი მოწყობილობა იყენებს 50-57 მისამართს, რომ მთავარმა მოწყობილობამ შეძლოს მთელი 16<span lang="EN-US">K </span>ბაიტი ინფორმაციის აღქმა და შესაბამისად მისი მანიპულირება მოახდინოს. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoListParagraphCxSpFirst" style="margin-left: 21.0pt; mso-add-space: auto; mso-list: l1 level1 lfo2; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->1.<span style="font-size: 7pt;"> </span><!--[endif]-->ზოგჯერ დაქვემდებარებულ მოწყობილობას აქვს შეზღუდვა ძაბვაზე, მაგალითად მუშაობს მხოლოდ 2.5 – 3.3 ვოლტამდე. ეს შეზღუდვა უნდა შესრულდეს, რომ არ გაფუჭდეს მოწყობილობა. ამასთან ერთად უნდა გაითვალისწინოთ ისიც, რომ მთავარმა მოწყობილობამაც უნდა იმუშაოს ამ დიაპაზონში. <o:p></o:p></div><div class="MsoListParagraphCxSpLast" style="margin-left: 21.0pt; mso-add-space: auto; mso-list: l1 level1 lfo2; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]-->2.<span style="font-size: 7pt;"> </span><!--[endif]-->სრული ტევადობის პრობლემა მანამდე არ იჩენს თავს, სანამ არ იქნება გრძელი ხაზები და დაქვემდებარებული მოწყობილობების გრძელი ჩამონათვალი. <o:p></o:p></div><h3><span style="color: windowtext; font-size: 11.0pt; line-height: 107%;">პრაქტიკული გამოყენება<o:p></o:p></span></h3><div class="MsoNormal" style="text-align: justify;">ამდენი თეორიის შემდეგ საინტერესო იქნება თუ როგორ შეგვიძლია ეს ყველაფერი გადავიტანოთ რეალურ ცხოვრებაში და ვნახოთ ამ კომუნიკაციის საშუალების რეალური შედეგები. მაგალითში გამოვიყენებ დღესდღეობით საკმაოდ პოპულარულ დაფას - <span lang="EN-US">Arduino </span><span lang="EN-US"> </span>და მის <span lang="EN-US">IDE </span>ს. აქსელერომეტრის ვარიანტში კი გამოვიყენებ უბრალოდ <span lang="EN-US">Atmega32 </span>ჩიპს, რომელსაც <span lang="EN-US">USB </span>კომუნიკაციის მხარდაჭერა აქვს.<span lang="EN-US"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">მე პირადად კომუნიკაციის ეს ტიპი გამომიყენებია გარე მახსოვრობებისათვის, ტემპერატურისა და ტენიანობის გაზომვისათვის და აქსელერომეტრის მონაცემების წასაკითხად. აქსელერომეტრთან და გარე მახსოვრობასთან მუშაობა ერთის მხრივ უფრო რთული იმ მხრივ არის, რომ ორმხრივი კომუნიკაციაა საჭირო, მონაცემების ჩასაწერად და შემდეგ წასაკითხად (სასურველ ფორმატში აქსელერომეტრის შემთხვევაში). პირველი მაგალითი დავიწყოთ გარე მახსოვრობასთან კომუნიკაციით, რომელიც ამ მაგალითის შემთხვევაში არის <span lang="EN-US">24LC256 (</span>256<span lang="EN-US">K </span>ბიტიანი = 32<span lang="EN-US">K </span>ბაიტი გარე მახსოვრობა)<span lang="EN-US">. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-jh9Vk90YYlo/UuuzZOstB3I/AAAAAAAABwc/ZdWD1U7s6n8/s1600/Capture.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-jh9Vk90YYlo/UuuzZOstB3I/AAAAAAAABwc/ZdWD1U7s6n8/s1600/Capture.PNG" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><v:shape id="_x0000_i1027" style="height: 135pt; width: 183pt;" type="#_x0000_t75"> <v:imagedata o:title="Capture" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image003.png"></v:imagedata></v:shape><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US">A1 A2 </span>და <span lang="EN-US">A3 </span>პინების მდგომარეობის მიხედვით შესაძლებელია მისამართის ამ მოწყობილობის მისამართის განსაზღვრა. მაგალითისთვის ავიღოთ, თუ სამივე ფეხს მივაერთებთ ნულთან, მაშინ მოწყობილობის მისამართი გახდება <span lang="EN-US">0x50, </span>ხოლო თუ ყველა ფეხს + ზე მივაერთებთ მისამართი შეიცვლება 0<span lang="EN-US">x57 </span>ით. ყველა კომბინაციისას მისამართი იცვლება, რომლის მნიშვნელობა შესაძლებელია მონაცემთა ფურცელის ან <span lang="EN-US">google </span>ის დახმარებით გაიგოთ. სიმარტივისთვის ყველა ფეხს შევაერთებ ნულთან. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US">Arduono </span>სთვის კოდი კი ქვემოთ იქნება მოცემული. პირველ რიგში <span lang="EN-US">setup </span>ში საჭიროა ინტერფეისის დაწყება, მხოლოდ იმის შემდეგ, რაც გლობალურ ბლოკში შემოვიტანთ სპეციალურად ამ ინტერფეისისთვის დაწერილ ბიბლიოთეკას - <span lang="EN-US">Wire.h. </span>საბოლოოდ კოდი გამოდის შემდეგნაირი, რომელსაც დაწვრილებით გავარჩევ<span lang="EN-US"> (</span>კოდი წარმოდგენილია, როგორც გრაფიკული ფაილი, მისი რედაქტირება შესაძლებელია სტატიის ბოლოს არსებული ფაილის საშუალებით <span lang="EN-US">Arduino IDE </span>ს გამოყენებით). <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-xV5Ptqz6hLs/UuuzZUziFtI/AAAAAAAABwo/pkbflVuaJEk/s1600/Capture1.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-xV5Ptqz6hLs/UuuzZUziFtI/AAAAAAAABwo/pkbflVuaJEk/s1600/Capture1.PNG" /></a></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><v:shape id="_x0000_i1028" style="height: 594pt; width: 378.75pt;" type="#_x0000_t75"> <v:imagedata o:title="Capture1" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image004.png"></v:imagedata></v:shape><o:p></o:p></div><div class="MsoNormal" style="text-align: justify;">თავიდან შეიძლება <span lang="EN-US">writeEEPROM </span>და <span lang="EN-US">readEEPROM </span>ფუნქციები ძნელი აღსაქმელი გახდეს, მაგრამ ახსნილი ვფიქრობ გაცილებით მარტივი იქნება. კოდში მაქვს სტანდარტული <span lang="EN-US">loop </span>და <span lang="EN-US">setup </span>ფუნქციები (მეთოდი - <span lang="EN-US">C# </span>ში). ამჯერად მეორე ფუნქცია ცარიელია, რადგან მანიპულირება სურვილისებრ შეგიძლიათ მოახდინოთ. პირველად <span lang="EN-US">setup</span><span lang="EN-US"> </span>ფუნქციაში ვახდენ <span lang="EN-US">Serial </span>პორტის ინიციალიზებას, რომლის პარამეტრი კომუნიკაციის სიჩქარეა (სერიული პორტი კომპიუტერთან კომუნიკაციის საშუალებაა <span lang="EN-US">Arduino</span><span lang="EN-US"> </span>სთვის). სერიული მონიტორისა და პროცესორის კომუნიკაციის სიჩქარე უნდა დაემთხვეს, რომ კომუნიკაცია წარმატებით შედგეს, მონაცემების გამოსატანად. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">ამის შემდეგ ხდება <span lang="EN-US">I2C </span>კომუნიკაციის დაწყება, რაც (სტანდარტულად) მიკროპროცესორის ანალოგიურ მეხუთე და მეოთხე პინს გამოიყენებს კომუნიკაციისთვის. ამის შემდეგ იქმნება ცვლადი, მისმართი, რომელიც მიუთითებს ადგილს მახსოვრობაში ინფორმაციის ჩაწერის მისამართს. <b>ყოველ ჯერზე უნდა გაიგზავნოს 1 ბაიტი. </b>როგორც აღვნიშნეთ ჩემს შემთხვევაში მოწყობილობის მოცულობაა 32<span lang="EN-US">K </span>ბაიტი. თუ მისამართს მივუთითებ ნულს, მაშინ ინფორმაციის ჩაწერა დაიწყება ნულიდან, ხოლო თუ 321, 321 დან. ასევე მაქვს ორი ძირითადი ფუნქცია <span lang="EN-US">writeEEPROM </span>და <span lang="EN-US">readEEPROM, </span>რომლებიც მთელ შავ სამუშაოს ასრულებენ. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">გარჩევა დავიწყოთ ჩაწერის ფუნქციით, რომელიც სამ არგუმენტს იღებს: მოწყობილობის მისამართს, მეხსიერებაში ჩაწერის დაწყების მისამართსა და 1 ბაიტ ინფორმაციას, რომელიც უნდა გაიგზავნოს გარე მახსოვრობაში <span lang="EN-US">TWI </span>ის გამოყენებით. <span lang="EN-US">Setup </span>ფუნქციაში ვიძახებ ჩაწერის ფუნქციას და ვუთითებ მასში, რომ ჩემს გარე მოწყობილობაში ჩაწეროს 123. ახლა კი დროა უფრო ღრმად ვნახოთ რას შვრება ჩემი კოდი რელურად და როგორ უმკლავდება მონაცემთა გაანალიზებას. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><i>ინფორმაციისთვის : </i><span lang="EN-US">Arduino IDE </span>ში <span lang="EN-US">int </span>ცვლადი იკავებს 2 ბაიტს, ხოლო <span lang="EN-US">char </span>ცვლადი 1 ბაიტს. <span lang="EN-US">I2C </span>კომუნიკაციის გამოყენებისას შეზღუდვა ის არის, რომ ყოველი გაგზავნილი პაკეტი უნდა იყოს 1 ბაიტის ტოლი. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">პირველ რიგში, ჩაწერის ფუნქცია იწყება <span lang="EN-US">Wire.beginTransmission() </span>ით, რაც მოწყობილობას ამცნობს იმას, რომ კომუნიკაციის დამყარება გვსურს მასთან. შემდეგ ვგზავნით მეხსიერების იმ მისამართს, სადაც ჩაწერის განხორციელება გვსურს. რადგან გარე მეხსიერებაში 32000 სხვადასხვა მისამართი არსებობს, რისთვისაც 16 ბიტიანი ცვლადის გამოყენებაა საჭირო, უნდა მოვახერხო და ეს 16 ბიტი, ორ 8 ბიტიან ცვლადად დავშალო და მისამართი ისე გავაგზავნო. მეორე ხაზზე, ხდება 8 ბიტის გადატანა მარჯვნივ და ამ 8 ბიტის გაგზავნა. ამის შემდეგ დარჩენილი 8 ბიტის გაგზავნა. განვიხილავ მაგალითს:<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><i>ინფორმაციისთვის : </i><span lang="EN-US">MSB – Most Significant Bit. LSB – Less Significant Bit. MSB </span>ით აღინიშნება პირველი 8 ბიტი (მარცხნიდან), ხოლო <span lang="EN-US">LSB </span>ით პირველი 8 ბიტი (მარჯვნიდან).<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">საჭიროა გავგზავნოთ მისამართი 20 000, რომელიც ორობით სისტემაში არის 0100 1110 0010 0000. ჯერ უნდა გავგზავნოთ <span lang="EN-US">MSB </span>და შემდეგ <span lang="EN-US">LSB. </span>16 ბიტიდან ჯერ უნდა მივიღოთ <span lang="EN-US">MSB </span>ის ბიტები, ამიტომ ხდება მათი 8 პოზიციით გადატანა. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">0100 1110 0010 0000 -> 8 ბიტის გადაწევისას -> 0100 1110<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">მესამე ხაზზე კი სრულდება შემდეგი ინსტრუქცია (დაპროგრამებაში ეგრეთწოდებული შენიღბვა (<span lang="EN-US">masking)) </span>ლოგიკური <span lang="EN-US">‘</span>და’ ს გამოყენებით.<o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">0100 1110 0010 0000 -> შენიღბვა -> <span lang="EN-US">0010 0000<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US"><br /></span></div><div class="MsoNormal" style="text-align: justify;">ეს იმას ნიშნავს, რომ <span lang="EN-US">24LC256 </span>ჩიპი მონაცემებს იღებს შემდეგნაირად, ჯერ 0100 1110 და შემდეგ <span lang="EN-US">0010 0000, </span>რომლითაც ის ხვდება, რომ ინფორმაციის მოთავსება იწყება 20 000 დან. ამით ჩვენ მას ვამცნობთ, რომ გვინდა მასში ინფორმაციის ჩაწერა გადაცემულ მისამართზე. და ვაგზავნი კიდევაც ინფორმაციას. ამის შემდეგ უკვე ხდება კომუნიკაციის დასრულება იმით, რომ ჩიპი თავის თავში წერს მიღებულ ინფორმაციას. ასევე არ უნდა დაგავიწყდეთ 5 მილი წამის ოდენობის შეყოვნება, რადგან მოწყობილობამ მოასწროს ინფორმაციის შენახვა. როდესაც არის მომენტები, რომლებშიც მიმდევრობით ხდება ინფორმაციის ჩაწერა, ამ დროს შეყოვნების გარეშე შეიძლება ყველაფერი ცუდად წავიდეს და უცნაური რამე მოხდეს. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">ამის შემდეგ მეორე, წაკითხვის ფუნქცია, მისამართის კონვერტირებას 2 ბაიტიდან იგივე გზით ახდენს 2 ცალ 1 ბაიტში. უგზავნის მოწყობილობას ამ მისამართს და ასრულებს კომუნიკაციას. შემდეგ ითხოვს მოწყობილობისგან ინფორმაციას. <span lang="EN-US">Wire.requestFrom() </span>ფუნქციის მეორე პარამეტრი აღნიშნავს თუ რამდენი ბაიტის წაკითხვა არის საჭირო (ჩვენს შემთხვევაში 1 ის). შემდეგ ვამოწმებ არის თუ არა ინფორმაცია <span lang="EN-US">I2C</span><span lang="EN-US"> </span>ს ხაზზე და ვკითხულობ მას. ამის შემდეგ ფუნქცია აბრუნებს 1 ბაიტ ინფორმაციას. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"></div><div class="MsoNormal" style="text-align: justify;">ვფიქრობ, ამით ამოვწურე <span lang="EN-US">I2C </span>კომუნიკაციის პროტოკოლის გამოყენება <span lang="EN-US">AVR </span>ის მიკრო პროცესორებში საწყისი ეტაპისათვის. მომავალში უფრო მეტ მაგალითს განვიხილავ, როგორც კი მექნება საშუალება. <a href="https://docs.google.com/file/d/0B8INmvEfFu2zdFNEWldFclNNZ1U/edit">ამ ლინკზე</a> შეგიძლიათ ნახოთ პროგრამის კოდი და გამოიყენოთ სურვილისებრ. <o:p></o:p></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-64373169592438625882014-01-10T08:10:00.000-08:002014-06-20T07:54:41.925-07:00მოვლენები (2/3) - მოვლენის მსმენელი<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">ამ პოსტში მინდა ვისაუბრო იმ მოვლენისა და კლასების გამოყენებაზე, რომელიც განვსაზღვრე წინა პოსტში და მოვახდინო მათი ინტეგრირება მხოლოდ ერთი მარრტივი კლასის დახმარებით, რაც მთლიანობაში აზრობრივად დაასრულებს მოვლენებს, ხოლო მესამე ნაწილი დაეთმობა სუსტ მოვლენებს (Weak Events).</div><div class="MsoNormal" style="text-align: justify;"><a name='more'></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">კლასი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">User.cs </span><span style="background: white; mso-highlight: white;">გამოიყენება, როგორც მოვლენის მსმენელი. ეს კლასი იწერს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobDealer.cs</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ის მოვლენას და განსაზღვრავს ახალ მეთოდს, </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NewJobIsAvaiilable, </span><span style="background: white; mso-highlight: white;">რომელიც აკმაყოფილებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventHandler<JobInfoEventArgs> </span><span style="background: white; mso-highlight: white;">ტიპის დელეგატის ყველა მოთხოვნას, კერძოდ, აქვს ორი პარამეტრი: ობიექტი და </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobInfoEventArgs<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">User</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; font-family: Consolas;">name;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; font-family: Consolas;">User(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; font-family: Consolas;"> Name)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; font-family: Consolas;">.name = Name;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; font-family: Consolas;">NewJobIsAvailable(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">object</span><span style="background-color: white; font-family: Consolas;"> sender, </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobInfoEventArgs</span><span style="background-color: white; font-family: Consolas;">e)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"{0}: job {1} is new and available"</span><span style="background-color: white; font-family: Consolas;">, name, e.Job);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"> }</span><span style="background-color: white;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;">ახლა მოვლენის გამომქვეყნებელი და მისი გამომწერი უნდა დაუკავშირდნენ ერთმანეთს რამენაირად. ამის გაკეთება კი შესაძლებელია </span><span lang="EN-US" style="background-color: white;">NewJobInfo </span><span style="background-color: white;">მოვლენის გამოყენებით, რომელიც განსაზღვრულია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobDealer.cs</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ში. გამოვიყენებ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">+= </span><span style="background: white; mso-highlight: white;">ოპერატორს გამოწერის შესასრულებლად. მოცემულია სანიმუშო კოდი, ქვემოთ<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; font-family: Consolas;">Main(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; font-family: Consolas;">[] args)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">var</span><span style="background-color: white; font-family: Consolas;">dealer = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobDealer</span><span style="background-color: white; font-family: Consolas;">();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">var</span><span style="background-color: white; font-family: Consolas;">Misha = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">User</span><span style="background-color: white; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"MISHA"</span><span style="background-color: white; font-family: Consolas;">);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> dealer.NewJobInfo += Misha.NewJobIsAvailable;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> dealer.NewJob(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Manager"</span><span style="background-color: white; font-family: Consolas;">);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">var</span><span style="background-color: white; font-family: Consolas;">Giorgi = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">User</span><span style="background-color: white; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"GIORGI"</span><span style="background-color: white; font-family: Consolas;">);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> dealer.NewJobInfo += Giorgi.NewJobIsAvailable;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> dealer.NewJob(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Developer"</span><span style="background-color: white; font-family: Consolas;">);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; font-family: Consolas;">.ReadKey();<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"> }</span><span style="background-color: white;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;">პროგრამის გაშვების შემთხვევაში გვექნება<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-MBD3UcFrwPo/UtAbOYcrKMI/AAAAAAAABtA/afl63sirjPg/s1600/Capture.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-MBD3UcFrwPo/UtAbOYcrKMI/AAAAAAAABtA/afl63sirjPg/s1600/Capture.PNG" height="201" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white;"><v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"> <v:stroke joinstyle="miter"> <v:formulas> <v:f eqn="if lineDrawn pixelLineWidth 0"> <v:f eqn="sum @0 1 0"> <v:f eqn="sum 0 0 @1"> <v:f eqn="prod @2 1 2"> <v:f eqn="prod @3 21600 pixelWidth"> <v:f eqn="prod @3 21600 pixelHeight"> <v:f eqn="sum @0 0 1"> <v:f eqn="prod @6 1 2"> <v:f eqn="prod @7 21600 pixelWidth"> <v:f eqn="sum @8 21600 0"> <v:f eqn="prod @7 21600 pixelHeight"> <v:f eqn="sum @10 21600 0"> </v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"> <o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="_x0000_i1025" style="height: 227.25pt; width: 450.75pt;" type="#_x0000_t75"> <v:imagedata o:title="Capture" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">ყოველი ახალი სამსახურის დამატებისას, ის მომხმარებელი, რომელსაც გამოწერილი აქვს მოვლენა, მისდის შეტყობინება ახალი სამსახურის შესახებ, როდესაც ხდება მოვლენის გააქტიურება. <o:p></o:p></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-25537331659770554532014-01-06T08:28:00.000-08:002014-06-20T07:54:41.977-07:00მოვლენები (1/3) - მოვლენის განმსაზღვრელი<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">მოვლენები მთლიანად დაფუძნებულები არიან დელეგატებზე და რახან მოვრჩი დელეგატების განხილვას, ლოგიკური იქნება თუ ჩემი პოსტების გაგრძელება შეეხება ისეთ ელემენტებს, როგორიცაა მოვლენები. მოვლენები გვთავაზობს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">publish/subscribe </span><span style="background: white; mso-highlight: white;">მექანიზმს. ყველაფრის გადათარგმნა არ იქნება მოხერხებული და ამიტომ, ჩემი აზრით, სჯობს რამდენიმე ტერმინოლოგია ასე დავტოვო. მაგალითისათვის, რომ ავიღოთ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Windows Forms </span><span style="background: white; mso-highlight: white;">ში </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Button </span><span style="background: white; mso-highlight: white;">კონტროლს აქვს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Click </span><span style="background: white; mso-highlight: white;">მოვლენა. მოვლენის ეს ტიპი არის დელეგატი</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">, </span><span style="background: white; mso-highlight: white;">ხოლო მომგვარებელი (</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">handler) </span><span style="background: white; mso-highlight: white;">მეთოდის გამოძახება ხდება მაშინ, როდესაც აქტიურდება </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Click</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">მოვლენა. მომგვარებელი ანუ მოპასუხე მეთოდის განსაზღვრა ხდება მომხმარებლის მიერ უმეტეს შემთხვევაში.</span></div><a name='more'></a><br /><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">ჩემი აზრით მხოლოდ თეორიას ჯობს მაგალითებიც შევურიო მასში და ასეც მოვიქცევი. შევქმნი ახალ კლასს - </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobDealer.cs</span><span style="background: white; mso-highlight: white;">, რომელიც სთავაზობს „მომხმარებელს“ მოვლენებზე დაფუძნებულ „გამოწერას“. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobDealer.cs </span><span style="background: white; mso-highlight: white;">განსაზღვრავს ახალ მოვლენას </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NewJobInfo, </span><span style="background: white; mso-highlight: white;">რომლის ტიპია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventHandler<JobInfoEventArgs> event </span><span style="background: white; mso-highlight: white;">საკვანძო სიტყვის გამოყენებით. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NewJob() </span><span style="background: white; mso-highlight: white;">მეთოდის შიგნით ხდება </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NewJobInfo </span><span style="background: white; mso-highlight: white;">მოვლენის გააქტიურება. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobInfoEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">: </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">EventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">JobInfoEventArgs(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> job)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Job = job;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Job { </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">get</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">set</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobDealer</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">event</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">EventHandler</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobInfoEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> NewJobInfo;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">NewJob(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> job)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"JobDealer, new job {0}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, job);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(NewJobInfo != </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">null</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> NewJobInfo(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobInfoEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(job));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">JobDealer.cs </span><span style="background: white; mso-highlight: white;">კლასი მომხმარებელს სთავაზობს ახალ მოვლენას </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">NewJobInfo</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">რომლის ტიპია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><JobInfoEventArgs>. </span><span style="background: white; mso-highlight: white;">კონვენციის თანახმად მოვლენები იყენებენ მეთოდებს, რომლებსაც გააჩნიათ ორი პარამეტრი. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Sender </span><span style="background: white; mso-highlight: white;">ობიექტი, რომელიც ააქტიურებს მოვლენას და მეორე პარამეტრი აგზავნის მოვლენის შესახებ დამატებით ინფორმაციას. მეორე პარამეტრი სხვადასხვაა სხვადასხვა ტიპის მოვლენებისათვის. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">.NET 1.0 </span><span style="background: white; mso-highlight: white;">ში უკვე რამდენიმე ასეული დელეგატი იყო განსაზღვრული სხვადასხვა ტიპის მოვლენებისათვის. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventHandler<TEventArgs> </span><span style="background: white; mso-highlight: white;">განსაზღვრავს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">handler</span><span style="background: white; mso-highlight: white;">ს რომელიც აბრუნებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void </span><span style="background: white; mso-highlight: white;">ს და იღებს ორ არგუმენტს. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventHandler<TEventArgs> </span><span style="background: white; mso-highlight: white;">ის პირველი პარამეტრი უნდა იყოს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">object </span><span style="background: white; mso-highlight: white;">ტიპის, ხოლო მეორე პარამეტრის ტიპი არის </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T. EventHandler<TEventArgs> </span><span style="background: white; mso-highlight: white;">ასევე განსაზღვრავს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T </span><span style="background: white; mso-highlight: white;">ტიპზე შეზღუდვას, რაც იმას ნიშნავს, რომ მიუხედავად იმისა, რომ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T </span><span style="background: white; mso-highlight: white;">ტიპში ნებისმიერი ტიპი შეიძლება იგულისხმებოდეს, მაინც არსებობს გამონაკლისები და ყველა ტიპი არ შეიძლება ჩაჯდეს <> ფრჩხილებში. ეს შეზღუდვა კი მდებარეობს შემდეგში: </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">T </span><span style="background: white; mso-highlight: white;">ს მაგივრად გამოყენებული კლასი აუცილებელია, რომ იყოს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventArgs </span><span style="background: white; mso-highlight: white;">ის მემკვიდრე. სწორედ ამიტომ არის გამოყენებული ჩემს მიერ შემოთავაზებულ მაგალითში განსაზღვრული კლასისთვის წინაპარი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">EventArgs </span><span style="background: white; mso-highlight: white;">კლასი. </span><span lang="EN-US"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">delegate</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">EventHandler</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><TEventArgs> (</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">object</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> sender, TEventArgs e)<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">where</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">TEventArgs : </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">EventArgs</span><span style="background: white; color: #2b91af; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">კლასი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">JobDealer.cs </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ააქტიურებს მოვლენას </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">NewJob </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">მეთოდში. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">NewJobInfo</span><span lang="EN-US" style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ს () ით გამოყენებით, იძახებთ ყველა იმ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">handler </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ს რომელსაც „გამოწერილი“ აქვს მოვლენა. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Multicast </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">დელეგატების მსგავსად </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">handler </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ების გამოძახების თანმიმდევრობა არ არის დაცული, ამიტომ ესეც უნდა გაითვალისწინოთ თქვენს მიერ დაწერილ კოდში, რადგან ერთხელ შეიძლება იმუშაოს ყველაფერმა, ხოლო მეორეჯერ კი რაიმე შეცდომა ამოაგდოს და თავის ტკივილი გაგიჩინოთ. <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ასევე ყურადღებაა იმ ფაქტზე გასამახვილებელი, რომ აუცილებლად უნდა შემოწმდეს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">NewJobInfo </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">დელეგატის არსებობა, რადგან თუ ის არავის არ აქვს გამოწერილი მაშინ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">null </span><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;">ის ტოლია. <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; mso-bidi-font-family: Consolas; mso-highlight: white;"><br /></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">NewJob(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> job)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"JobDealer, new job {0}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, job);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(NewJobInfo != </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">null</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> NewJobInfo(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">JobInfoEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(job));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-81580813870158095952014-01-04T04:54:00.000-08:002014-06-20T07:54:42.018-07:00დელეგატები (5/5) - Multicast Delegates <div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">აქამდე ვიყენებდი დელეგატებს, რომლებიც იძახებდნენ მხოლოდ ერთ მეთოდს. ერთზე მეტი მეთოდის გამოსაძახებელად ერთი დელეგატის გამოყენებით საჭიროა ცხადად შეუცვალოთ დელეგატს შემცველი მეთოდის მისამართი. მაგრამ არსებობს უფრო მარტივი გზაც, რომელიც განსხვავდება პირველი პრიმიტიული გზისაგან და საშუალებას გვაძლევს ერთი დელეგატის გამოყენებით გამოვიძახოთ ერთზე მეტი მეთოდი. მსგავსი დელეგატი ცნობილია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Multicast </span><span style="background: white; mso-highlight: white;">დელეგატის სახელით. თავისუფლად შეიძლება მას ეწოდოს მრავალი მეთოდის შემცველი დელეგატი. ამისთვის საჭიროა რომ ყველა მეთოდი, რომელსაც იძახებს დელეგატი, არ უნდა აბრუნებდეს არანაირ მნიშვნელობას, ანუ უნდა იყოს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void </span><span style="background: white; mso-highlight: white;">ტიპის. წინააღმდეგ შემთხვევაში დელეგატი დააბრუნებს იმ მეთოდის დაბრუნებულ მნიშვნელობას რომელიც გამოიძახა ბოლოს.</span><br /><a name='more'></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">მეთოდის გამოსაძახებლად, რომელიც აბრუნებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void </span><span style="background: white; mso-highlight: white;">ტიპს, გამოვიყენებ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Action<T></span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ტიპის დელეგატს. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Main(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">[] args)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> Ops = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.MultiplyByFour;<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> Ops += </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Square;</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ძველ მაგალითებში შეიძლება შეგხვდეთ ისეთი სიტუაცია, რომელშიც საჭიროა სხვადასხვა დელეგატის გამოყენება სხვადასხვა მეთოდის გამოძახებისთვის. აქ კი შესაძლებელია უბრალოდ ოპერაციების მიმატება და მრავალი მეთოდის შემცველ დელეგატად „გადაქცევა“ ერთი შეხედვით ჩვეულებრივი დელეგატის. დელეგატებთან მუშაობისას, ისინი ცნობენ ისეთ ოპერატორებს როგორებიც არიან + და +=. ასევე დასაშვებია ქვემოთ მოცემული კოდის გამოყენებაც<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> op1 = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.MultiplyByFour;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> op2 = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Square;<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> op3 = op1 + op2;</span><span style="background: white; mso-highlight: white;"> <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">მრავალი მეთოდის შემცველი დელეგატები შესაძლებელს ხდიან გამოიყენოთ - და -= ოპერატორები. ქვემოთ მოცემულია კიდევ ერთი მარტივი გამოყენება მრავალი მეთოდის შემცველი დელეგატებისა და </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">MathOps.cs </span><span style="background: white; mso-highlight: white;">კლასის განსაზღვრის გზა.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">MultiplyByFour(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> num)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">result = num * 4;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Multiply by 4 {0} = {1}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, num, result);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Square(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> num)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">result = num * num;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Square of {0} = {1}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, num, result);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">შესამჩნევია, რომ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">MathOps.cs </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">კლასში მოთავსებული მეთოდები სტატიკურია და ისინი მნიშვნელობის დაბრუნების მაგივრად ავტომატურად წერენ პასუხს, რადგან მრავალი მეთოდის შემცველ დელეგატებთან მუშაობისას სასურველია </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">void </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">დაბრუნების ტიპის მეთოდების გამოყენება. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">შესაძლებელია ასევე შემდეგი ინტერპრეტაციის გამოყენებაც:<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">CallAndDisplay(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> action, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> num)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Called with val = {0}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, num);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> action(num);<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ხოლო </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Main</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ის კოდი გადაკეთდება შესაბამისად<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Main(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">[] args)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> ops = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.MultiplyByFour;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> ops += </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">MathOps</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Square;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> CallAndDisplay(ops, 2.0);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> CallAndDisplay(ops, 5.21);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> CallAndDisplay(ops, 12.322);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.ReadKey();<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">კოდის გაშვების შემდეგ გექნებათ შემდეგი შედეგი, თუ რა თქმა უნდა არ შეცვალეთ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">num </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ცვლადის მნიშვნელობები.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-gF1nkaQWPUg/UsgEauv02QI/AAAAAAAABsk/7f-U8iS5Mcw/s1600/MulticastDelegates.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="201" src="http://2.bp.blogspot.com/-gF1nkaQWPUg/UsgEauv02QI/AAAAAAAABsk/7f-U8iS5Mcw/s400/MulticastDelegates.PNG" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"> <v:stroke joinstyle="miter"> <v:formulas> <v:f eqn="if lineDrawn pixelLineWidth 0"> <v:f eqn="sum @0 1 0"> <v:f eqn="sum 0 0 @1"> <v:f eqn="prod @2 1 2"> <v:f eqn="prod @3 21600 pixelWidth"> <v:f eqn="prod @3 21600 pixelHeight"> <v:f eqn="sum @0 0 1"> <v:f eqn="prod @6 1 2"> <v:f eqn="prod @7 21600 pixelWidth"> <v:f eqn="sum @8 21600 0"> <v:f eqn="prod @7 21600 pixelHeight"> <v:f eqn="sum @10 21600 0"> </v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"> <o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="_x0000_i1025" style="height: 227.25pt; width: 450.75pt;" type="#_x0000_t75"> <v:imagedata o:title="MulticastDelegates" src="file:///C:\Users\Giorgi\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">ასევე გასათვალისწინებელია ის ფაქტიც, რომ როდესაც იყენებთ მრავალი მეთოდის შემცველ დელეგატებს ფორმალურად არ არის განსაზღვრული მეთოდების გამოძახების მიმდევრობა. სასურველია თავიდან აირიდოთ ისეთი მეთოდების გამოძახება მსგავსი დელეგატით, რომელთა გამოძახების მიმდევრობის არევა რაიმე რისკის გამომწვევია, რადგან თუ ერთი დელეგატის გამოძახებისას რაიმე პრობლემა შეიქმნა და კომპილერმა </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Exception </span><span style="background: white; mso-highlight: white;">დაიჭირა, მაშინ ამ მეთოდის შემდგომი მეთოდების გამოძახება აღარ გაგრძელდება. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><o:p></o:p></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-30440525518509451092014-01-03T05:05:00.000-08:002014-06-20T07:54:42.036-07:00დელეგატები (3/5) - BubbleSorter ალგორითმი<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">დღეს მე მინდა ყურადღება გავამახვილო ერთ-ერთ ძლიერ და პოპულარულ ალგორითმზე, რომელიც ჩემი აზრით საჭიროა, რომ ყველამ იცოდეს და ესმოდეს მისი მუშაობის პრინციპი ამ სფეროში. ამ ალგორითმს ეწოდება </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">BubbleSorter </span><span style="background: white; mso-highlight: white;">ალგორითმი და ვაპირებ მის გარჩევას და შემდეგ უკვე მოდიფიცირებას დელეგატებისა და ზოგადი ტიპის გამოყენებით. ვფიქრობ, რომ საკმაოდ საინტერესო გაკვეთილი უნდა გამოვიდეს და მაშინ დავიწყებ.</span><br /><a name='more'></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">მე შევქმენი კლასი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">BubbleSorter.cs</span><span style="background: white; mso-highlight: white;">, რომელიც შეიცავს ორ ძირითად მეთოდს, </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Sort </span><span style="background: white; mso-highlight: white;">და </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Sort<T></span><span style="background: white; mso-highlight: white;">. ამ ორიდან პირველი თავისი ყველაზე პრიმიტიული გაგებით ალაგებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">int </span><span style="background: white; mso-highlight: white;">ტიპის მასივს. მაგალითისთვის, რომ ავიღოთ ამ ტიპის მნიშვნელობები და მივაწოდოთ ალგორითმს - </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">0, 5, 6, 2, 1, </span><span style="background: white; mso-highlight: white;">ჩემს მიერ დაწერილი ეს ალგორითმი გადაალაგებს წევრებს და მოგვცემს მასივს, რომელშიც წევრების მიმდევრობა იქნება - { 0, 1, 2, 5, 6 }. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">როგორც აღვნიშნე, ეს ალგორითმი ფართოდ გამოყენებადი, ცნობადი და საკმაოდ მარტივია მასივებთან სამუშაოდ. მხოლოდ მასივებთან, რომლებიც დაახლოებით ათ წევრზე ნაკლებს შეიცავენ, ხოლო უფრო მეტისთვის არსებობს უფრო ეფექტური ალგორითმებიც. მთავარი იდეა იმაშია, რომ ციკლი მანამდე არ ჩერდება სანამ გადანაცვლება არ მოხდება იმ წევრებისა, რომლებსაც ადარებს ციკლში ეს ალგორითმი და ანაცვლებს მათ მასივში. ახლა კი კარგი იქნება თუ კოდსაც შევხედავთ:<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Sort(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> sortArray)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">true</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">do</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">false</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">for</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> i = 0; i < sortArray.Count - 1; i++)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(sortArray[i] < sortArray[i+1]) <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">temp = sortArray[i];<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> sortArray[i] = sortArray[i + 1];<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> sortArray[i + 1] = temp;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">true</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">while</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(swapped);<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ეს მეთოდი არის კლას </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">BubbleSorter </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ის წევრი. ამ მეთოდის გამოყენებით საკმაოდ მარტივია ციფრების დალაგება. მაგრამ რა ვქმნათ, როდესაც გვაქვს ისეთი მასივი, რომელშიც თავმოყრილია არა მარტო </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">int </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპი, არამედ მომხმარებლის მიერ განსაზღვრული არასტანდარტული ტიპი. მაშინ ჩემს მიერ შემოთავაზებული ალგორითმი თავის ძალას პირველივე გაშვებაზე დაკარგავს და შეცდომასაც ამოაგდებს. ამისთვის არსებობს, გამოსავალი და ეს გამოსავალი დევს დელეგატისა და ზოგადი</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;"> (Generic Type) </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპის გამოყენებაზე. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მე შემიძლია შევქმნა მეთოდი </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Sort<T></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">, რომლისთვისაც მისაღები იქნება </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპი. მათთვის ვინც ვერ ხვდება ამჟამად რა არის </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპი, ვიტყვი, რომ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპი არის ისეთივე ცვლადი, როგორიც </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">int x </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">დან </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">x. </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ანუ <</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ასეთ ფრჩხილებში ნიშნავს, რომ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ს მაგივრად შეიძლება „ჩაჯდეს“ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">int, string, bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">, </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Person (</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">რომელსაც ქვემოთ განვსაზღვრავ) და ნებისმიერი სტანდარტული თ მომხმარებლის მიერ შექმნილი ტიპი. ეს თვისება </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">C# </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ძალიან მოქნილს ხდის. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">შედარებისთვის საჭიროა ისეთი მეთოდი, რომელიც იღებს ორ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპის არგუმენტს და აბრუნებს </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">bool </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპის ცვლადს. ამისთვის კი გამოვიყენებ დელეგატს, რომელიც რაღაც მნიშვნელობას აბრუნებს -> </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Func<T</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">1</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">, T</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">2</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">, bool></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">. რახან </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T1 = T2, </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მათ ერთი და იმავე ასოთი აღვნიშნავ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">(</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ს ნაცვლად შეიძლება გამოვიყენოთ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">A, B, C, D </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">და ასე შემდეგ).<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ჩემი ზოგადი ტიპის მეთოდის სახე კი ასეთი იქნება <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Sort<T>(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><T> SortArray, </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><T, T, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> comparison)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">true</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">do</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">false</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">for</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> i = 0; i < SortArray.Count - 1; i++)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(comparison(SortArray[i + 1], SortArray[i]))<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> T temp = SortArray[i];<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> SortArray[i] = SortArray[i + 1];<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> SortArray[i + 1] = temp;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> swapped = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">true</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> } </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">while</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(swapped);<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ამ მეთოდის გამოსაყენებლად საჭიროა განვსაზღვროთ სხვა კლასი, რომელიც საშუალებას მოგვცემს დავასახლოთ მასივი ამ კლასის ტიპის ობიექტებით და შემდეგ დავალაგოთ ისინი რაიმე პარამეტრის მიხედვით.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Name { </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">get</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">set</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Wage { </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">get</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">set</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Person(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> pName, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">pWage)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Name = pName;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Wage = pWage;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">override</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">ToString()<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Format(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"{0}, {1}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, Name, Wage);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">WageComparison(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> p1, </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">p2)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">p1.Wage < p2.Wage;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ეს არის კლასი </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Person, </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">რომელსაც გააჩნია სახელი და ანაზღაურება. მასში ვაკეთებ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ToString() </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მეთოდის ოვერრაიდინგს, რაც იმას ნიშნავს, რომ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ToString() </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მეთოდის გამოძახებისას, ნებისმიერ მის ობიექტზე, ის დააბრუნებს სახელს + ანაზღაურებას. ასევე მაქვს სტატიკური მეთოდი, რომელიც ანაზღაურებას ადარებს, თავისივე ტიპის ობიექტებისათვის. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Main(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">[] args)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> persons = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">>();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Bugs Bunny"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 20000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Elmer Fudd"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 10000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Daffy Duck"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 25000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Wile Coyote"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 1000000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Foghorn Leghorn"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 23000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> persons.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"RoadRunner"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 50000));<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">BubbleSorter</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Sort(persons, </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WageComparison);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">foreach</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">var</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> person </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">persons)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(person.ToString());<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.ReadKey();<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ამ კოდის საშუალებით კი პირველ ნაწილში ვქმნით სიას, რომელიც არის </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Person </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპის და შემდეგ ამ სიას ვატარებთ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Sort </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მეთოდის არგუმენტად. დაყოფის შემდეგ გამოგვაქვს შედეგები. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Sort<T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ალგორითმს კიდევ ერთი მოდიფიკაცია აქვს, რაც იმაში მდგომარეობს, რომ შეგვიძლია </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">List<T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ის ნაცვლად რეალური მასივი გავატაროთ არგუმენტად, როგორიცაა <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">[] persons =<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Bugs Bunny"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 20000),<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Elmer Fudd"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 10000),<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Daffy Duck"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 25000),<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Wile Coyote"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 1000000),<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Foghorn Leghorn"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 23000),<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Person</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"RoadRunner"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, 50000)<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> };</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მხოლოდ უნდა შევცვალოთ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Sort</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ალგორითმის განსაზღვრის ფორმაც შემდეგნაირად<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Sort<T>(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">IList</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><T> SortArray, </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><T, T, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> comparison)</span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">სადაც </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">List<T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">კლასის ნაცვლად გამოვიყენებ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">IList<T> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ინტერფეისს.</span><span style="background: white; mso-highlight: white;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;">ჩემს მიერ განსაზღვრული <a href="https://docs.google.com/file/d/0B8INmvEfFu2zZDNrTkV2Ym5qQkU/edit" target="_blank">დამხმარე კლასები</a>.</div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-56028274405122556282013-12-31T08:27:00.000-08:002014-06-20T07:54:42.077-07:00დელეგატები (2/5) - გამოყენება<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">ქვემოთ მოცემული მაგალითი იყენებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">toString() </span><span style="background: white; mso-highlight: white;">მეთოდს. მაგალითი საკმაოდ გრძელი გზაა ამ მეთოდი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">int </span><span style="background: white; mso-highlight: white;">ტიპისთვის გამოსაყენებლად. <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Program</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">delegate</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">GetString</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">();</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Main()<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">num = 40;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">GetString</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Fmethod = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">GetString</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(num.ToString);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.Write(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"String -> {0}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">, Fmethod());<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span></div><a name='more'></a><br /><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; mso-highlight: white;">ამ კოდში ჩვენ ვქმნით დელეგატს, რომლის ტიპია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">GetString </span><span style="background: white; mso-highlight: white;">და ვსაზღვრავთ მის „ობიექტს“, რომლის პარამეტრიცაა </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">ToString() </span><span style="background: white; mso-highlight: white;">მეთოდი, რომელიც ოპერაციას ატარებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">num </span><span style="background: white; mso-highlight: white;">ცვლადზე. სინტაქსურად დელეგატები პარამეტრად იღებენ ერთ მეთოდს, რომელსაც უკავშირდებიან და საჭიროების შემთხვევაში იძახებენ. გასათვალისწინებელია ის ფაქტი, რომ მეთოდისა და დელეგატის ხელწერა უნდა დაემთხვეს ერთმანეთს. შემდეგ ხდება დელეგატის გამოძახება, რომელიც იძახებს და ასრულებს შემცველ მეთოდს (ებს). დელეგატისთვის ბოლოს ფრჩხილების () დაწერა იმავეს ნიშნავს, რომ დაგეწერათ </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Fmethod.Invoke()</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">; </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ეს ყველაფერი უფრო მარტივდება შემოკლებული სინტაქსის გამოყენებისას. მაგალითისთვის, ყველგან რომ არ შექმნათ დელეგატის ახალი „ობიექტები“ და ბევრიც, რომ არ წეროთ, აქედან გამოსავალი სი არის, რომ დელეგატს პირდაპირ გაუტოლოთ მეთოდი, რომლის გამოძახებაც მას ევალება.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">GetString</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Fmethod = num.ToString;</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">კომპილატორი ხვდება, რომ ამ შემთხვევაში ვიყენებთ დელეგატს და ის ჩვენთვის ქმნის დელეგატის ახალ „ობიექტს“ და მისამართით ატარებს იმ მეთოდს, რომელსაც ვუტოლებთ მას. ასევე ზემოთ მოცემულ სინტაქსში ყურადღებაა გასამახვილებელი იმ ფაქტზე, რომ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">num.ToString </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მეთოდი წერია () ის გარეშე, რადგან ეს წარმოადგენს ამ მეთოდის მისამართს, ხოლო თუ მას ფრჩხილებსაც მივამატებდით - </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">num.ToString(), </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">წარმოიშვებოდა პრობლემა, რადგან ეს უკვე ნიშნავს იმას, რომ ხდება მეთოდის გამოძახება და ეს მეთოდი აბრუნებს </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">string </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ტიპის ობიექტს, რომელიც მიუღებელია დელეგატისთვის. სწორედ ამიტომ ვუტოლებთ დელეგატს მეთოდის მისამართს და არა თვით მეთოდის გამოძახების შედეგად მიღებულ ობიექტს. დელეგატისთვის მეთოდის პირდაპირ გატოლებას ეწოდება </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">inference. </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">დელეგატების ეს თვისება აქტიურად გამოიყენება </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">event </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ებში, რომელის განხილვასაც დავიწყებ დელეგატების შემდგომ.</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"> <span lang="EN-US"><o:p></o:p></span></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">უკვე ალბათ ბევრჯერ გავიმეორე, რომ დელეგატები არიან ტიპობრივად უსაფრთხო იმის გამო, რომ მათი განსაზღვრისთანავე ხდება ყველა დეტალის დაზუსტება, რამაც შეიძლება რაიმე კონფლიქტური სიტუაცია გამოიწვიოს ტიპებს შორის. საინტერესოა ასევე ის ფაქტიც, რომ მათ არ ანაღვლებთ რა ტიპის ობიექტის გავლით ხდება მოცემული მეთოდის გამოძახება და ეს მეთოდი სტატიკურია თუ მოითხოვს ობიექტის გავლით გამოძახებას. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მე წარმოგიდგენთ ორ კლასს</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">: Car </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">და </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">VirualDB, </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">რომელიც წარმოადგენს მანქანების ვირტუალურ მონაცემთა ბაზას. პროგრამის მიხედვით, მთავარ ტანში ჩვენ გვაქვს მოცემული დელეგატის ტიპი, რომლის გამოყენებითაც განისაზღვრება პარამეტრის და არგუმენტი. ეს უკანასკნელი იყენებს </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">Car </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">კლასში მოთავსებულ სტატიკურ მეთოდ </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">GetModel</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">-</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ს, რომელიც მომხმარებელს აცდის მოდელის შეყვანას, როგორც ტექსტურ ცვლადს. ამის შემდეგ განისაზღვრება ვირტუალური მონაცემთა ბაზის (</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">VirtualDB) </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ახალი ობიექტი - </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">VDB.</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ამ ობიექტის გამოყენებით ვიძახებ </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">AddCar </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მეთოდს, რომელიც არასტატიკურია და არგუმენტად ვატარებ დელეგატს. </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">AddCar </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ის ბლოკში რომ შევიდეთ, ეს მეთოდი აკეთებს შემდეგ რამეს: <o:p></o:p></span></div><div class="MsoListParagraphCxSpFirst" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Symbol;">¨<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">შიდა სიაში ამატებს იმ მანქანას, რომლის მოდელიც არის იმ მეთოდის დაბრუნებული ტექსტური ცვლადი, რომლის მისამართსაც შეიცავს დელეგატი. <o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Symbol;">¨<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">გამოაქვს წარმატების ნიშანი <o:p></o:p></span></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -18.0pt;"><!--[if !supportLists]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Symbol;">¨<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">აბრუნებს </span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;">true </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">მნიშვნელობას, შემდგომი გამოყენებისათვის<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;">ქვემოთ წარმოგიდგენთ კოდს<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-o2FSqtxLrUU/UsLxmwt5TYI/AAAAAAAABi4/ZJTaC6lpiYY/s1600/Capture.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="267" src="http://3.bp.blogspot.com/-o2FSqtxLrUU/UsLxmwt5TYI/AAAAAAAABi4/ZJTaC6lpiYY/s400/Capture.PNG" width="400" /></a></div><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><br /></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">namespace</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">BlogSpotAppConsole<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">{<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Program</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">delegate</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Mydel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">Main()<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">დაწყების</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">მესიჯი</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Enter Car Model"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Mydel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">ArgumentDelegate = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Car</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.GetModel;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ვქმნით</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ვირტუალური</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">მონაცემთა</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ბაზის</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ობიექტს</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">VirtualDB</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">VDB = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">VirtualDB</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> VDB.AddCar(ArgumentDelegate);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ვიცდით</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.ReadKey();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">VirtualDB</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Car</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">> carList = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">List</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Car</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">>();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">bool</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">AddCar(</span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Mydel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> ParameterDelegate)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(ParameterDelegate == </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">null</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">false</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">else</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> carList.Add(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Car</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">{ ModelName = ParameterDelegate() });<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//carList.Add(new Car { ModelName = delegateParam.Invoke() });</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">იმავეს</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">აკეთებს</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">რასაც</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">პირველი</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">მეთოდი</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ამ</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ბლოკში</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//</span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">წარმატების</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">მესიჯი</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ინგლისურად</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">ობიექტური</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">მიზეზების</span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: green; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Sylfaen; mso-hansi-font-family: Sylfaen; mso-highlight: white;">გამო</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"Car {0} added successfully"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">,</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"> this</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.carList[carList.Count - 1].ModelName);<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">true</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Car</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">_modelName = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">null</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">ModelName<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">get</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">_modelName;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">set</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">if</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">value</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> != </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">null</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">)<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> _modelName = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">value</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">GetModel()<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> {<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">string</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">modelN = </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">.ReadLine();<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">modelN;<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0.0001pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"> }</span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">}</span><span lang="EN-US" style="background-color: white; background-position: initial initial; background-repeat: initial initial;"><o:p></o:p></span><br /><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;">ესეც <a href="https://docs.google.com/file/d/0B8INmvEfFu2zdV8zNkVyNElHNlU/edit" target="_blank">Program.cs ფაილი</a>, რომლის გამოყენებაც შეგეძლებათ VisualStudio ს გამოყენებით </span><br /><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; font-family: Consolas;"><br /></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-22964075657317208252013-12-28T11:31:00.000-08:002014-06-20T07:54:42.098-07:00დელეგატები (1/5) - შესავალი<div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABis/8iCikgugn7k/s1600/untitled.png" /></a></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">მიუხედავად იმისა, რომ ჩემი წინა პოსტები </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C#</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">შეიცავდა დელეგატის გამოყენების ინსტრუქციებს, ახლა გადავწყვიტე ის რაც შეიძლება ზოგმა არ იცოდეს ავხსნა და ამით უფრო გასაგები გავხადო ჩემს მიერ დაწერილი წინა პოსტები, რომლებიც იყენებდნენ დელეგატებს, როგორც მეორეხარისხოვან ობიექტებს.</span><span style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ერთი სიტყვით, ეს პოსტი არის დასაწყისი დელეგატების და შევეცდები რაც შეიძლება ღრმად მოვიცვა ისინი.</span></span><br /><a name='more'></a><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Sylfaen;">დელეგატების გამოყენება მაშინ ხდება საჭირო, როდესაც გვსურს მეთოდის სხვა მეთოდისათვის გადაცემა. უკეთ გასაგებად ვნახოთ ქვემოთ მოცემული ფრაგმენტი კოდიდან:</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Int i = int.Parse(“</span><span style="background: white; mso-highlight: white;">2013</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">”);</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">ზემოთ მოცემულ კოდში არაფერია უჩვეულო, რადგან პროგრამირების ენის ათვისების დაწყებისთანავე ვსაზღვრავთ მეთოდებს, კოდის მაქსიმალურად შესაკუმშად და მათში ვაგზავნით არგუმენტს (ებს), ისე რომ ამაზე არც ვფიქრობთ. ამ ყველაფრის შემდეგ შესაძლებელი ხდება მეთოდის არგუმენტი გახდეს სხვა მეთოდი, რაც თავდაპირველად ცოტა უჩვეულოდ შეიძლება მოგეჩვენოთ, მაგრამ არაფერია. </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C </span><span style="background: white; mso-highlight: white;">ში და </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C++ </span><span style="background: white; mso-highlight: white;">შესაძლებელია უბრალოდ ფუნქციის (იგივე მეთოდი) მისამართის აღება და მისი უბრალოდ მეორე ფუნქციის არგუმენტად გატარება. აღსანიშნავია, რომ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C </span><span style="background: white; mso-highlight: white;">ში არ არსებობს ტიპობრივი უსაფრთხოება. შესაძლებელია ნებისმიერი ფუნქციის გატარება მისამართით სადაც პოინტერიანი (</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">pointer)</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">პარამეტრია მითითებული. სამწუხაროდ ეს პრაქტიკა არც ისე უსაფრთხოა და ბევრ პრობლემას იწვევს. ამიტომ არის, რომ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">.NET </span><span style="background: white; mso-highlight: white;">გარემო ამის საშუალებას არ იძლევა, უფრო სწორედ არ რთავს მომხმარებელს ამის გაკეთების ნებას. თუ გსურთ, რომ მეთოდი გაატაროთ როგორც არგუმენტად საჭირო ხდება მეთოდის დეტალების მითითება ახალი ტიპისთვის - დელეგატისთვის. მარტივად რომ ვთქვათ, დელეგატები განსაკუთრებული ტიპის ობიექტებია. განსაკუთრებული იმ მხრივ, რომ აქამდე რა ტიპის ობიექტიც არ უნდა შეგექმნათ ის შეიცავდა ინფორმაციას, ხოლო დელეგატი არ შეიცავს მეთოდის (ების) მისამართს (ებს). </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C# </span><span style="background: white; mso-highlight: white;">ში კლასის განსასაზღვრად საჭიროა ორი ნაბიჯი. სასურველი კლასის განსაზღვრა და ამ კლასის ობიექტის შექმნა შიდა წევრებთან წვდომისთვის, <span style="mso-spacerun: yes;"> </span>თუ რა თქმა უნდა კლასი არ არის სტატიკური. დელეგატების შემთხვევაშიც იმავე პროცესის გამეორებაა საჭირო. პირველ რიგში საჭიროა დელეგატის განსაზღვრა, რაც იმას ნიშნავს, რომ კომპილატორს მიუთითოთ რა ტიპის მეთოდი უნდა წარმოადგინოს დელეგატმა. ამის შედეგ საჭიროა ამ დელეგატის ერთი ან ორი ინსტანციის შექმნა. სცენას მიღმა კი კომპილატორი ქმნის კლასს, რომელიც წარმოადგენს დელეგატს. ქვემოთ მოცემულია დელეგატის განსაზღვრის სინტაქსი:</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;">delegate void <span lang="EN-US" style="mso-ansi-language: EN-US;">double</span>MethodInvoker(<span lang="EN-US" style="mso-ansi-language: EN-US;">double</span> x);<span style="background: white; mso-highlight: white;"> <span style="mso-spacerun: yes;"> </span></span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">ამ შემთხვევაში განვსაზღვრე დელეგატი სახელად </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">doubleMethodInvoker</span><span style="background: white; mso-highlight: white;">. როგორც აღვნიშნე, ამ დელეგატს შეუძლია იმ მეთოდების მისამართის გამოყენება, რომელის დაბრუნების ტიპია </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void </span><span style="background: white; mso-highlight: white;">და იღებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">double </span><span style="background: white; mso-highlight: white;">ტიპის ერთ პარამეტრს. მთავარი აზრი იმისა, თუ რატომ ვიყენებთ დელეგატს და არა </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C++ </span><span style="background: white; mso-highlight: white;">სავით </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">pointer </span><span style="background: white; mso-highlight: white;">ებს, მდგომარეობს იმაში, რომ დელეგატები ტიპობრივად უსაფრთხოა. რაც იმას ნიშნავს, რომ დელეგატის განსაზღვრისას ხდება გამოსაძახებელი მეთოდის მაქსიმალურად დაწვრილებით აღწერა (დაბრუნების ტიპი, პარამეტრების ტიპები და ოდენობა...). </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">მაგალითისთვის ვნახოთ კიდევ ერთი კოდის ფრაგმენტი, სადაც ვსაზღვრავ ერთ დელეგატს, რომელიც პარამეტრად იღებს ორ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">double </span><span style="background: white; mso-highlight: white;">ტიპის პარამეტრს და აბრუნებს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">string</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ტიპის მნიშვნელობას. </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;"><span style="font-family: Sylfaen;">Delegate string twoDoubleOps(double F, double S);</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">დელეგატის განსაზღვრის სინტაქსი ერთის მხრივ მეთოდის განსაზღვრის სინტაქსს ჰგავს, იმ გამონაკლისებით, რომ წინ საჭიროა </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">delegate </span><span style="background: white; mso-highlight: white;">საკვანძო სიტყვის გამოყენება და ეს „მეთოდის“ აღწერა არ შეიცავს მეთოდის ტანს. დელეგატის განსაზღვრა რადგან ჰგავს კლასის განსაზღვრას და სინამდვილეში ტექნიკურად ეს ასეც არის, მისი განსაზღვრა შესაძლებელია ნებისმიერ ადგილას, სადაც დასაშვებია კლასის გამოყენება. ასევე დელეგატს შეიძლება დაენიშნოს წვდომის ნებისმიერი მოდიფიკატორი: </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">public, private, protected </span><span style="background: white; mso-highlight: white;">და ასე შემდეგ. </span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; mso-highlight: white;"><span style="font-family: Sylfaen;">შემდეგ პოსტში უკვე დელეგატებს გამოვიყენებ, ხოლო მოგვიანებით რამდენიმე კერძო მაგალითს განვიხილავ.<o:p></o:p></span></span></div></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-3401000491515125372013-12-14T08:00:00.000-08:002014-06-20T07:54:42.140-07:00დელეგატები (4/5) - Func და Action<br /><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" /></a></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;"></span></span> </div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">ეს ორი ტიპის დელეგატი ძალიან აადვილებს დელეგატების გამოყენებას ზოგადად და ზუსტად ჯდება </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">lambda Expression </span><span style="background: white; mso-highlight: white;">ების მოთხოვნილებაში, რომელიც წინა პოსტში მიმოვიხილე. ჩემი აზრით, ისინი ავსებენ ერთმანეთს და უფრო კომფორტულად ხდება მათი ერთობლივად გამოყენება. ასევე ყველა სხვდასხვა ტიპის მეთოდისათვის რომ არ მოგიწიოთ სხვადასხვა დელეგატის განსაზღვრა სხვადასხვა პარამეტრისა და დასაბრუნებელი ტიპით, უბრალოდ საჭიროა ამ ორი ხელსაყრელი დელეგატის ტიპის გამოყენება. იმის გასაგებად თუ რატომ შემოგვთავაზეს </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">C# </span><span style="background: white; mso-highlight: white;">ორი სახის დელეგატი, უნდა ვნახოთ რომელიც დელეგატი რა სპეციალიზაციით გამოიყენება.</span></span><br /><a name='more'></a><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; mso-highlight: white;">ზოგადი (</span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">generic) Action<T></span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">დელეგატი, რომელშიც შეიძლება შევიდეს ის მეთოდები, რომლებიც </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">ტიპის მეთოდს წარმოადგენენ, არსებობს რამდენიმე სახის, რაც იმას ნიშნავს, რომ შესაძლებელია ამ ტიპის დელეგატში გაატაროთ 16 მდე სხვადასხვა პარამეტრი. </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Action</span><span lang="EN-US" style="background: white; mso-highlight: white;"> </span><span style="background: white; mso-highlight: white;">კლასი პარამეტრების გარეშე გამოიყენება იმ </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">void </span><span style="background: white; mso-highlight: white;">ტიპის მეთოდებისათვის, რომლებსაც არ გააჩნიათ პარამეტრი. ერთ პარამეტრიანი </span><span lang="EN-US" style="background: white; mso-ansi-language: EN-US; mso-highlight: white;">Action </span><span style="background: white; mso-highlight: white;">ტიპის დელეგატის განსასაზღვრად შემდეგი კოდი სრულყოფილად იმუშავებს პროგრამაში.</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T> </span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Sylfaen;">თუ საჭიროა მეთოდის გამოძახება, რომელიც 8 პარამეტრს შეიცავს მაშინ შესაბამისი კოდს ასეთი სახე ექნება</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Action</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T1, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T2, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T3, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T4, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T5, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T6, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T7, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T8></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Funk<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">დელეგატიც შესაბამისად შეიძლება გამოყენებულ იქნას. მაგრამ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Action<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">სა და </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Func<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ს შორის განსხვავება ის არის, რომ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Func<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ის გამოყენებით შესაძლებელია ისეთი მეთოდის გამოძახება, რომელსაც გააჩნია დასაბრუნებელი ტიპი, ანუ აბრუნებს მნიშვნელობას. ასევე არსებობს </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Func<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ს სხვადასხვა ვარიაცია, რომლებშიც შესაძლებელია 16 მდე პარამეტრის გატარება და ბოლოს შედეგის დაბრუნება.</span></span> </div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">Func<</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T1, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T2, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">T3, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">in</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> T4, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">out</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">TResult></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Sylfaen;">ზემოთ მოცემული დელეგატი არის 4 პარამეტრიანი მეთოდისათვის. ჩვეულებრივი დელეგატი, რომ გამოგეყენებინათ ასეთი რამ გექნებოდათ:</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">delegate</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">mydel(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> x, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">y);</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">სტანდარტული დელეგატის განსაზღვრის მაგივრად შესაძლებელია განვსაზღვროთ </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">Func<T> </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ტიპის დელეგატი, რომლის მუშაობის პრინციპსაც ახლა ვნახავთ და ვნახეთ წინა პოსტში - პოსტის სახელი.</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Collections.Generic;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Linq;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Text;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Threading.Tasks;<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">namespace</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">BlogSpotAppConsole</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">{<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Program</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">Main()<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">>[] Del = </span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>method1,</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>method2</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>};</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"></span> </div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"val = 4"</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">);</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.WriteLine(</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">"new val = {0}"</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, Del[0](Del[1](4)));</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt 35.4pt; mso-layout-grid-align: none; text-indent: 35.4pt;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;"> Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.ReadKey();</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">method1(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> val)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> r</span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">eturn</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">val * val;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">method2(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">double</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> val)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">2 * val;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"></span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><o:p><span style="font-family: Consolas;">}</span></o:p></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Sylfaen;">ზემოთ შეიძლება თავიდან გაუგებრობა იყოს, მაგრამ ერთი რაც რეალურად ბუნდოვანი შეიძლება იყოს, ჩემი აზრით არის ეს -> <span style="mso-spacerun: yes;"> </span></span></span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">Del[0](Del[1](4))</span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Sylfaen;">, რაც იგივეა, რომ დაგეწერათ</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;"><span style="font-family: Sylfaen;">method1 ( method2 ( 4 ) )</span></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ჯერ შესრულდებოდა </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">method2</span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">(4), რომელიც დააბრუნებდა 8ს, ხოლო შემდეგ 8 იქნებოდა </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas; mso-highlight: white;">method1 (8) </span><span style="background: white; color: black; mso-bidi-font-family: Consolas; mso-highlight: white;">ს პარამეტრი და ის დააბრუნებდა 64, ხოლო პროგრამა მთლიანობაში დააბრუნებს 64, როგორ ნახეთ.<o:p></o:p></span></span></div></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-75161845678811562112013-12-13T03:04:00.000-08:002014-06-20T07:54:42.154-07:00Lambda Expressions<div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" /></a></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="mso-ansi-language: EN-US;">Lambda expressions </span>არის ძალიან კარგი თვისებაა <span lang="EN-US" style="mso-ansi-language: EN-US;">C#</span> 3.0<span style="mso-ansi-language: EN-US;"> </span>ისა, ხოლო ასევე ის შეიძლება იყოს დიდი საფრთხის შემცველი იმისათვის, ვინც არ იცი როგორ გამოიყენოს შესაბამისად ისინი. ეს პოსტი იმათთვის იქნება გასაგები ვინც იცის თუ რა არის დელეგატი და როგორ გამოიყენება ის. <span lang="EN-US" style="mso-ansi-language: EN-US;">C# </span>იყენებს ახალ სინტაქსს<span lang="EN-US" style="mso-ansi-language: EN-US;">, </span>რომლითაც კოდის წერა უფრო დახვეწილი, ლამაზი და ერთგვარად ძლიერი ხდება. ჩვენ გვქონდა მაგალითი წინა პოტიდან, სადაც გამოვიყენე ანონიმური მეთოდი, ახლა ცოტა შევცვალოთ ეს ყველაფერი. </span><br /><a name='more'></a><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Collections.Generic;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Linq;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using </span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Text;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Threading.Tasks;<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">namespace</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">BlogSpotAppConsole</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Program</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">Main()</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> {</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">num1 = 10;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//Func<int, int> anonDel = delegate(int param)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//<span style="mso-spacerun: yes;"> </span>param += 12;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//<span style="mso-spacerun: yes;"> </span>param += 32;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//<span style="mso-spacerun: yes;"> </span>return param;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//};</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//Console.WriteLine(anonDel(num1));</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: green; font-family: Consolas; mso-highlight: white;">//Console.ReadKey();</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">> lambdaEx = param =></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> {</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>param = num1;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>param += 12;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>param += 32;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">param;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>};</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"></span> </div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.WriteLine(lambdaEx(num1));</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.ReadKey();</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">}</span><span style="color: black; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">მოცემულ კოდში ანონიმური მეთოდის გამოყენება დაკომენტარებულია და მის მაგივრად ვიყენებ </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambda expressions </span><span style="color: black; mso-bidi-font-family: Consolas;">ს. „ =>“ ოპერატორს ეწოდება </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambda </span><span style="color: black; mso-bidi-font-family: Consolas;">ოპერატორი, რომლის მარცხნივ თავს იყრის ის პარამეტრები, რომლებიც საჭიროა</span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">, </span><span style="color: black; mso-bidi-font-family: Consolas;">ხოლო მარჯვენა მხარე განკუთვნილია მეთოდის იმპლემენტაციისთვის, რომელიც ენიშნება </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambdaEx </span><span style="color: black; mso-bidi-font-family: Consolas;">ცვლადს, ჩემს შემთხვევაში. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">აქ რამდენიმე საკითხია, რომელზეც მინდა ყურადღების გამახვილება<span style="mso-spacerun: yes;"> </span>და მათი ცოტა უფრო დაწვრილებით განხილვა, მათ შორისაა <b style="mso-bidi-font-weight: normal;">პარამეტრები, </b>და <b style="mso-bidi-font-weight: normal;">ცვლადები </b></span><b style="mso-bidi-font-weight: normal;"><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambda Expression </span></b><b style="mso-bidi-font-weight: normal;"><span style="color: black; mso-bidi-font-family: Consolas;">ის გარეთ. </span></b><b style="mso-bidi-font-weight: normal;"><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;"><o:p></o:p></span></b></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">დავიწყოთ პირველით - <b style="mso-bidi-font-weight: normal;">პარამეტრები<o:p></o:p></b></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">თუ მეთოდი შეიცავს მხოლოდ ერთ ხაზს, მაშინ ფიგურული ფრჩხილების გამოყენება აღარ წარმოადგენს საჭიროებას, ასევე არ არის საჭირო </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">return</span><span lang="EN-US" style="color: black; mso-bidi-font-family: Consolas;"> </span><span style="color: black; mso-bidi-font-family: Consolas;">ის მითითებაც, რადგან ერთ ხაზიანი მეთოდის დაწერისას </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">return </span><span style="color: black; mso-bidi-font-family: Consolas;">არაცხადად ჯდება კოდში კომპილატორის მიერ.</span><span style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;"> </span><span style="color: black; mso-bidi-font-family: Consolas;">მაგალითისათვის, გვაქვს კვადრატში აყვანის მეთოდი<o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">> square = x => x * x;</span><span style="color: black; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">რა თქმა უნდა შეიძლება თავის ატკიება და ზემოთ მოცემული დელეგატის გადატვირთვა, რაც იმას ნიშნავს, რომ გვექნება ფიგურული ფრჩხილებიც და დაბრუნების განაცხადიც<o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">> Lsquare = x =></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">temp = x * x;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">temp;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>};</span><span style="color: black; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">მაგრამ უნდა დაიმახსოვროთ, რომ ფიგურული ფრჩხილებისა და დაბრუნების განაცხადის გამოყენება ვალდებულებაა ისეთი „მეთოდის“ იმპლემენტაციისთვის, რომელიც ერთზე მეტ ხაზს შეიცავს.<o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">გავაგრძელოთ მეორე საკითხით - <b style="mso-bidi-font-weight: normal;">ცვლადები </b></span><b style="mso-bidi-font-weight: normal;"><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambda expression </span></b><b style="mso-bidi-font-weight: normal;"><span style="color: black; mso-bidi-font-family: Consolas;">ის გარეთ<o:p></o:p></span></b></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Lambda expression </span><span style="color: black; mso-bidi-font-family: Consolas;">ების გამოყენებით შესაძლებელია იმ ცვლადებზე წვდომა, რომლებიც განსაზღვრულია </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Lambda expression<b style="mso-bidi-font-weight: normal;"></b></span><span style="color: black; mso-bidi-font-family: Consolas;">ის ბლოკის გარეთ. ეს ძალიან მაგარი თვისებაა, მაგრამ უნდა გამოიყენოთ სწორედ. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">მაგალითში </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Lambda expression</span><b style="mso-bidi-font-weight: normal;"><span style="color: black; mso-bidi-font-family: Consolas;">, </span></b><span style="color: black; mso-bidi-font-family: Consolas;">რომლის ტიპია </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Func<int, int> </span><span style="color: black; mso-bidi-font-family: Consolas;">მოითხოვს ერთ </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">int </span><span style="color: black; mso-bidi-font-family: Consolas;">ტიპის პარამეტრს და აბრუნებს იმავე ტიპისას. </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Lambda expression</span><b style="mso-bidi-font-weight: normal;"><span lang="EN-US" style="color: black; mso-bidi-font-family: Consolas;"> </span></b><span style="color: black; mso-bidi-font-family: Consolas;">ისთვის პარამეტრი განსაზღვრულია როგორც </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">x. </span><span style="color: black; mso-bidi-font-family: Consolas;">ასევე </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Lambda expression</span><b style="mso-bidi-font-weight: normal;"><span lang="EN-US" style="color: black; mso-bidi-font-family: Consolas;"> </span></b><span style="color: black; mso-bidi-font-family: Consolas;">ის კოდი იყენებს გარე ცვლადს </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">num</span><span style="color: black; mso-bidi-font-family: Consolas;">1 ს. კოდს, რომ შეხედოთ დაბრუნებული რიცხვი უნდა იყოს 5 + </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">x</span><span style="color: black; mso-bidi-font-family: Consolas;">.</span></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;"></span></span> </div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt 35.4pt; mso-layout-grid-align: none; text-indent: 35.4pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"> int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">num1 = 5;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">> f = x => x + num1;</span><span style="color: black; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">მოდით ვნახოთ რა ხდება სინამდვილეში და რას აკეთებს კომპილატორი, რომ ჩვენთვის საქმის გამარტივებით შეასრულოს ასეთი ერთი შეხედვით მარტივი და კომფორტული სამუშაო. ამის გასაგებად </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">x => x + num1, </span><span style="color: black; mso-bidi-font-family: Consolas;">კომპილატორი ქმნის ანონიმურ კლასს, რომელსაც აქვს კონსტრუქტორი, რომელიც არგუმენტად იღებს გარე ცვლადებს, რომელიც </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">lambda Expression </span><span style="color: black; mso-bidi-font-family: Consolas;">ის გარეთ არის განსაზღვრული, ამ შემთხვევაში </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">int </span><span style="color: black; mso-bidi-font-family: Consolas;">ტიპის. კონსტრუქტორი გვარობა გამოკიდებულია იმაზე, თუ რამდენ ცვლადს იღებს დელეგატი. შექმნილი კლასი კი ასე გამოიყურება<o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">AnonymousClass</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">private</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">num1;<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">AnonymousClass(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> num1)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">this</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.num1 = num1;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"></span> </div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">public</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">AnonymousMethod(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> x)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">x + num1;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">}</span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><span style="font-family: Sylfaen;"><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: Consolas; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-highlight: white;">Lambda expression </span><span style="background: white; color: black; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: Consolas; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-highlight: white;">ების გამოყენება ასევე შესაძლებელია </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: Consolas; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-highlight: white;">LINQ </span><span style="background: white; color: black; mso-ascii-font-family: Sylfaen; mso-ascii-theme-font: major-latin; mso-bidi-font-family: Consolas; mso-hansi-font-family: Sylfaen; mso-hansi-theme-font: major-latin; mso-highlight: white;">ში, დელეგატების გარდა.</span><span lang="EN-US" style="background: white; color: black; font-family: Consolas; mso-ansi-language: EN-US; mso-highlight: white;"><o:p></o:p></span></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-50935710212111849252013-12-12T10:51:00.000-08:002014-06-20T07:54:42.196-07:00ანონიმური მეთოდები<br /><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-Uqy_lRixFGM/UqoFZz4V6AI/AAAAAAAABio/2e0gbxQigY0/s1600/untitled.png" /></a></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;">თუ არაფერი გსმენიათ ანონიმურ მეთოდებზე, ეს იმას ნიშნავს, რომ დელეგატის გამოსაყენებლად საჭირო იყო ისეთი მეთოდების გამოყენება, რომელსაც უნდა ჰქონოდა მკაფიოდ განსაზღვრული ხელწერა (დასაბრუნებელი ტიპი, პარამეტრების ტიპები და ოდენობა). სინამდვილეში კი დელეგატის გამოსაყენებლად არსებობს მეორე ალტერნატიული გზაც - ანონიმური მეთოდი. ანონიმური მეთოდი არის კოდის ბლოკი, რომელსაც უფრო არგუმენტი ეთქმის თავის თავზე და როგორც არგუმენტი ისე გადის დელეგატში.<o:p></o:p></span></div><a name='more'></a><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt; text-align: justify;"><span style="font-family: Sylfaen;">დელეგატის განსაზღვრის სინტაქსი რა თქმა უნდა უცვლელია, უბრალოდ იცვლება პატარა დეტალები. ქვემოთ მოცემულია ძალიან მარტივი, კოდი, მაგრამ მეორე მხრივ კარგად ასახავს ანონიმური მეთოდისა და დელეგატის ერთად გამოყენებას და მათ სიმძლავრეს. <span lang="EN-US" style="mso-ansi-language: EN-US;"><o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Collections.Generic;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Linq;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Text;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">using</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">System.Threading.Tasks;<o:p></o:p></span></div><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><o:p></o:p></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">namespace</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">BlogSpotAppConsole<o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">class</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Program</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">static</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">void</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">Main()</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">num1 = 10;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><o:p> </o:p></span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Func</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">, </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">> anonDel = </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">delegate</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">(</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">int</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">param)</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>{</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>param += </span><span lang="EN-US" style="background: white; color: black; mso-ansi-language: EN-US; mso-ascii-font-family: Sylfaen; mso-bidi-font-family: Consolas; mso-hansi-font-family: Sylfaen; mso-highlight: white;"><span style="font-family: Sylfaen;">num1</span></span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>param += 32;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">return</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">param;</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>};<o:p></o:p></span></div><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><o:p></o:p></span><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.WriteLine(anonDel(num1));</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span></span><span style="background: white; color: #2b91af; font-family: Consolas; mso-highlight: white;">Console</span><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">.ReadKey();</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;"><span style="mso-spacerun: yes;"> </span>}</span></div><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none;"><span style="background: white; color: black; font-family: Consolas; mso-highlight: white;">}</span><span style="color: black; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">ზემოთ მოცემული სინტაქსი შეიძლება ძალიან უცნაური მოგეჩვენოთ, მაგრამ, ჩემი აზრით მეტად მოხერხებულია. პირველად შეიძლება ეს მარტივი ოპერაცია იყოს, მაგრამ შემდეგ მიხვდებით, რომ ამ ძლიერი იარაღით ბევრი რამის გაკეთებაა შესაძლებელი. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">დელეგატი </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Func<int, int> </span><span style="color: black; mso-bidi-font-family: Consolas;">იღებს ერთ მთელ რიცხვს და აბრუნებს იმავე ტიპის შედეგს. </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">anonDel</span><span lang="EN-US" style="color: black; mso-bidi-font-family: Consolas;"> </span><span style="color: black; mso-bidi-font-family: Consolas;">არის </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">Func </span><span style="color: black; mso-bidi-font-family: Consolas;">ტიპის დელეგატის ცვლადი. ჩვეულებრივ დელეგატს პირდაპირ მეთოდის სახელს მივუთითებდით, რომლიც უნდა გამოიძახოს, ამის მაგივრად კი მარტივი კოდის ბლოკი გამოვიყენე - პრეფიქსით </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">delegate </span><span style="color: black; mso-bidi-font-family: Consolas;">და პარამეტრით, რომლიც მინდოდა გადამეცა. როგორც ხედავთ შიდა კოდი იყენებს იმ ცვლადს, რომლიც განსაზღვრულია ანონიმური მეთოდის გარეთ, ბლოკში, რომელშიც წესით სხვა სტანდარტულ მეთოდს წვდომა არ უნდა ჰქონდეს. ეს იმას ნიშნავს, რომ ის ჩაენაცვლა პარამეტრს და ჩვეულებრივ პარამეტრად გატარდა მეთოდის გამოძახების დროს. როდესაც დელეგატი გამოიძახეთ, მთელი რიცხვი გადის პარამეტრად და ბრუნდება იგივე ტიპის ცვლადი. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">ძირითადი პლიუსი ის არის, რომ მცირდება კოდის სიგრძე. აღარ არის საჭირო მეთოდის განსაზღვრა, რომელიც უნდა მიეთითოს დელეგატს. ეს უფრო მაშინ ხდება გასაგები, როდესაც საჭიროა მოვლენისათვის დელეგატის გამოყენება. ასევე მცირდება კოდის სირთულე, როდესაც რამდენიმე მოვლენაა ერთად თავმოყრილი. ამ ყველაფრიდან, შეიძლება იფიქროთ, რომ ანონიმური მეთოდები უფრო სწრაფიც უნდა იყოს, მაგრამ ეს ასე არ არის. კომპილატორი კვლავ განსაზღვრავს მეთოდს პროგრამის შესრულებისას, რომელსაც ენიშნება სახელი, რომლის ცოდნაც ჩვენთვის უკვე აღარ არის საინტერესო, რადგან ყველაფერი უკვე ავტომატიკაში გადადის. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">რამდენიმე წესია დასამახსოვრებელი, რომ რაიმე გაუგებრობა არ გამოიწვიოს ანონიმურმა მეთოდმა. მასში არ არის დაშვებული გადახტომის ოპერატორების გამოყენება, როგორებიცაა </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">goto, continue </span><span style="color: black; mso-bidi-font-family: Consolas;">და </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">break</span><span style="color: black; mso-bidi-font-family: Consolas;">, რომლებსაც აქვთ სამიზნე ანონიმური მეთოდის გარეთ და პირიქით, არ შეიძლება ამ ოპერატორების ანონიმური მეთოდის გარეთ განსაზღვრა, რომელთა სამიზნე ანონიმური მეთოდის შიგნით მდებარეობს. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="font-family: Sylfaen;"><span style="color: black; mso-bidi-font-family: Consolas;">ასევე ანონიმური მეთოდის შიგნით არ შეიძლება დაიწეროს </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">unsafe </span><span style="color: black; mso-bidi-font-family: Consolas;">კოდი. არ შეიძლება </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">ref </span><span style="color: black; mso-bidi-font-family: Consolas;">და </span><span lang="EN-US" style="color: black; mso-ansi-language: EN-US; mso-bidi-font-family: Consolas;">out </span><span style="color: black; mso-bidi-font-family: Consolas;">პარამეტრების გამოყენებაც, რომლებიც ანონიმური მეთოდის გარეთ არის ხელმისაწვდომი. <o:p></o:p></span></span></div><br /><div class="MsoNormal" style="line-height: normal; margin: 0cm 0cm 0pt; mso-layout-grid-align: none; text-align: justify;"><span style="color: black; mso-bidi-font-family: Consolas;"><span style="font-family: Sylfaen;">ერთის მხრივ, თუ გაქვთ ისეთი კოდი, რომელიც რამდენჯერმე უნდა გამოიყენოთ, მაშინ უმჯობესია დაწეროთ ეს ერთ მეთოდში და მოათავსოთ მასში, რადგან ანონიმური მეთოდების გამოყენებით უბრალოდ კოდის გაბერვა გამოვა და მეტი არაფერი, როდესაც ანონიმური მეთოდები შექმნილია სპეციალურად კოდის შესაკუმშად და სილამაზისთვის. <o:p></o:p></span></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-69091586696281408772013-12-09T07:38:00.000-08:002014-06-20T07:54:42.214-07:00WPF - 7 (სტილები და რესურსები)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" height="53" width="320" /></a></div><div class="MsoNormal"><span style="font-family: "Sylfaen","serif";"><br /></span></div><div class="MsoNormal"><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში შესაძლებელია თითოეულ ელემენტს შევუცვალოთ თვისება, როგორიცაა სიმაღლე, ფონტის ფორმა, ტიპი, მოცულობა და სხვა. მაგალითისთვის, რომ ავიღოთ ღილაკი მისი დიზაინის გაკეთება შესაძლებელია შემდეგი კოდით, რომელიც ყველაფერს მაინც ბოლომდე ვერ ფარავს. <o:p></o:p></span></div><div class="MsoNormal"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="25"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="120"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Blue"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">დამაჭირე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">"/></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ეს ყველაფერი მართლაც ძლიერი იარაღია, მაგრამ როდესაც აპლიკაციაში სულ მცირე ხუთი ღილაკია და ყველა ღილაკისთვის დახვეწილი დიზაინის გაკეთება გვინდა, რომელშიც საკმაოდ ბევრი რამ მეორდება, თითოეულის ხელით გაწერა უხერხულობასა და კოდის გადიდებას იწვევს, რის შემდეგაც იწყება თავის ტკივილები და ერთი ხაზის შეცვლას მოსდევს მთლიანი დიზაინის შეცვლის მოთხოვნა, რაც არც ისე მარტივია ასეთ დაქსაქსულ კოდში, ამიტომ გთავაზობთ გზას, რომელიც მოახდენს დაწერილი სტილების ლოკალიზებას და რაც შეიძლება შემოკლებას, რაც კოდის ხელახლა გამოყენებასაც უზრუნველყოფს და უფრო მოქნილს ხდის მთლიანად სისტემას. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"></span><br /></div><a name='more'></a><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">სტილები, ვფიქრობ, რომ საკმაოდ მოცულობითი უნდა გამომივიდეს და წინასწარ განვსაზღვრავ, რომ </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> ამ ნაწილში ვისაუბრებ ზოგადად სტილის განსაზღვრაზე.</span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სტილის განსაზღვრისას ვიყენებთ </span><span style="font-family: "Sylfaen","serif";"><style</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">> საკვანძო სიტყვას, რომლის შიგნით მას გააჩნია </span><span style="font-family: "Sylfaen","serif";">Setter </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისება, რომელსაც ორი თვისება აქვს თავის მხრივ - </span><span style="font-family: "Sylfaen","serif";">property </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">value. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">იმის მიხედვით თუ რა ელემენტს ენიშნება ეს სტილი, რომელის მითითებაც ხდება </span><span style="font-family: "Sylfaen","serif";">Style </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის თვისების </span><span style="font-family: "Sylfaen","serif";">TargetType </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის გამოყენებით, </span><span style="font-family: "Sylfaen","serif";">property </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ველში ჩნდება ის თვისებები, რომელიც დამახასიათებელია ამ ელემენტისათვის,</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"> </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ხოლო </span><span style="font-family: "Sylfaen","serif";">Value </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისებაში ის მნიშვნელობები, რომელებიც შესაბამის თვისებაზე შეიძლება დაენიშნოს. <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt; text-indent: 0.5in;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">დამაჭირე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button.Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">TargetType</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Button"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Height"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="25"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Width"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="120"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Background"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="YellowGreen"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button.Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ეს არის იგივე ღილაკი, რომელსაც მხოლოდ ფერი შევუცვალე და გამოვიყენე სტილები. მაგრამ სტილის ღილაკშივე გამოყენება არ არის მოსახერხებელი, რადგან ისევ იმის გაკეთება მოგვიწევს, რაც ზემოთ აღვნიშნე - ყველა კონტროლისთვის ხელოვნურად სტილის გაწერა. საჭიროა, რომ კოდის განზოგადება მოვახდინოთ და უფრო ნაკლები რესურსი გამოვიყენოთ. <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window.Resources</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Key</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="ButtonStyle"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">TargetType</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Button"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Height"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="25"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Width"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="120"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Background"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="YellowGreen"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window.Resources</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">დამაჭირე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="{</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StaticResource</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">ButtonStyle</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">}"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">მეორე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">ღილაკი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="{</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StaticResource</span><span style="background-color: white; color: #a31515;"><span style="font-family: Sylfaen, serif;"> </span></span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">ButtonStyle</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">}"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">როგორც ვხედავთ მხოლოდ სტილის მითითება გახდა საჭირო, რომ ერთსა და იმავე ღილაკს იგივე ფერის უკანა ფერი ჰქონოდა და სიმაღლე და სიგანე დაყენებულიყო, შესაბამისად 25 და 120. ახლა კი მინდა თქვენი ყურადღება გავამახვილო ერთ რამეზე, შეხედეთ ქვემოთ მოცემულ კოდს<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Key</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="ButtonStyle"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">TargetType</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Button"></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">რომელსაც თუ ჩამოვაცილებთ </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">x:Key </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ს და გადავაკეთებთ ასე<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> TargetType</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Button"></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ეს იმას ნიშნავს, რომ ამის ქვეშ განსაზღვრული სტილი დაენიშნება ყველა ღილაკს. ანუ ღილაკებისათვის შეიქმნება გლობალური სტილი და აღარც იქნება საჭირო <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">მეორე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">ღილაკი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="{</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StaticResource</span><span style="background: white; color: red; font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">ButtonStyle</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">}"/></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Style</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="{</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StaticResource</span><span style="background: white; color: red; font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">ButtonStyle</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">}"</span><span style="color: blue; font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"> </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ის მითითება, რაც ერთის მხრივ შეიძლება გამოსადეგი მოგეჩვენოთ, მაგრამ არც ისე. რა თქმა უნდა ეს ყველაფერი გამოსადეგია თუ ისეთ ზოგად სტილს ააწყობთ, რომ ყველა ღილაკს უნდა ჰქონდეს ეს თვისება ამ მნიშვნელობაზე დაყენებული, მაგალითად როგორიცაა </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">FontFamily </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">და მსგავსი.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">შედარებით რომ გავართულოთ შემდეგი ხაზი შევცვლოთ და უკანა ფონი დავაყენოთ წრფივი გრადაცია, ერთი ფერის მაგივრად, რომელიც უფრო მიმზიდველი და დახვეწილია ჩემი აზრით<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Background"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="YellowGreen"/></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin: 0in 0in 0pt 0.5in; text-indent: 0.5in;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Property</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Background"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter.Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">LinearGradientBrush</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">StartPoint</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0,0"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">EndPoint</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0,1"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">GradientStop</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Offset</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0.0"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Color</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="LightCyan" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">GradientStop</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Offset</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0.14"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Color</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Cyan" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">GradientStop</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Offset</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0.7"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Color</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="DarkCyan" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">LinearGradientBrush</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter.Value</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Setter</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">და ჩვენი მიღებული შედეგი ასე გამოიყურება <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-GEmEo4LVVAI/UqXjfQB3PqI/AAAAAAAABiY/3MEjhhZga38/s1600/styles0.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://3.bp.blogspot.com/-GEmEo4LVVAI/UqXjfQB3PqI/AAAAAAAABiY/3MEjhhZga38/s400/styles0.PNG" height="265" width="400" /></a></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Window</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Title</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="MainWindow"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Height</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="350"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Width</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Window.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Style</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Key</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="ButtonStyle"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> TargetType</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Button"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Setter</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Property</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Height"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Value</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="25"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Setter</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Property</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Width"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Value</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="120"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Style</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Window.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Name</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="myContainer"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">LinearGradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Key</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="MyGradientBrush"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> StartPoint</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0,0"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> EndPoint</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.3,1"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.0"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="LightCyan"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.14"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Cyan"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.7"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="DarkCyan"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">LinearGradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Style</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="{</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StaticResource</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> ButtonStyle</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Background</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="{</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StaticResource</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> MyGradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">}"/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Window</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">მოცემულ მაგალითში რესურსების განსაზღვრა ხდება კონტეინერ </span><span style="font-family: "Sylfaen","serif";">stackpanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ში, ხოლო წინა მაგალითში მე ისინი განვსაზღვრე </span><span style="font-family: "Sylfaen","serif";">window </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ში, რომელსაც ასევე გააჩნია </span><span style="font-family: "Sylfaen","serif";">resources </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">მახასიათებელი. </span><span style="font-family: "Sylfaen","serif";">FrameworkElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">განსაზღვრავს თვისება </span><span style="font-family: "Sylfaen","serif";">Resources</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">, რომლის ტიპი არის </span><span style="font-family: "Sylfaen","serif";">ResourceDictionary. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">სწორედ ამის წყალობით არის შესაძლებელი ყველა კლასში რესურსის განსაზღვრა, თუ ის მემკვიდრეა </span><span style="font-family: "Sylfaen","serif";">FramworkElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">რესურსები ხელმისაწვდომია იერარქიულად, რაც იმას ნიშნავს, რომ მე თუ </span><span style="font-family: "Sylfaen","serif";">window </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ში განვსაზღვრე რაღაც რესურსი, ის ხელმისაწვდომი იქნება მთლიანად იმ ელემენტებისთვის, რომელიც ამ კონტეინერს ეკუთვნის, ხოლო თუ ამ რესურსს მე </span><span style="font-family: "Sylfaen","serif";">stackpanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ში განვსაზღვრავდი ეს რესურსი მხოლოდ </span><span style="font-family: "Sylfaen","serif";">stackpanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის შიგნით იქნებოდა ხელმისაწვდომი.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">თუ საჭიროა ერთი და იმავე სტილი დაენიშნოს ერთზე მეტ ფანჯარას, მაშინ ლოგიკურია დავსვათ კითხვა:<o:p></o:p></span></div><div class="MsoListParagraph" style="text-align: justify; text-indent: -0.25in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">-<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">როგორ დავუნიშნოთ </span><span style="font-family: "Sylfaen","serif";">window </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ს სტილი, რომელიც არაფერშია მოთავსებული?!<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">აქ პრობლემა გადის იმ </span><span style="font-family: "Sylfaen","serif";">xaml </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ფაილიდან, რომელშიც ხშირად ვმუშაობდი ხოლმე, და მიდის </span><span style="font-family: "Sylfaen","serif";">App.xaml </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ფაილთან, რომელიც ამ შემთხვევაში იმისთვის გვჭირდება, რომ განვსაზღვროთ გლობალური რესურსი. აპლიკაციის სტილები ხელმისაწვდომია ყველა ფანჯრისათვის, უკეთ რომ წარმოიდგინოთ თქვენი </span><span style="font-family: "Sylfaen","serif";">window </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ვირტუალურად ჩასვათ </span><span style="font-family: "Sylfaen","serif";">App.xaml </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ში, რომელიც კონტეინერის როლს ითამაშებს ყველა </span><span style="font-family: "Sylfaen","serif";">window </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ელემენტისათვის.<o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="App_for_blogpost_tutorials.App"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> StartupUri</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="MainWindow.xaml"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> <o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">როდესაც ფაილს გახსნით მსგავსი კოდი დაგხვდებათ. შემდეგში გავარჩევთ, როგორ მოვახდინოთ ამ ფაილით მანიპულირება და როგორ შევძლოთ დასახული მიზნების განხორციელება.</span><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"><br /></span><span style="font-family: "Sylfaen","serif";">არსებობს რამდენიმე სისტემური რესურსი, რომელიც წარმოადგენს ფერებს და ისინი ხელმისაწვდომია მთელი აპლიკაციის გამოყენებისას და შექმნისას. ეს რესურსები განსაზღვრულია </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">SystemColors, SystetemFonts</span><span lang="EN-US" style="font-family: "Sylfaen","serif";"> </span><span style="font-family: "Sylfaen","serif";">და </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">SystemParameters </span><span style="font-family: "Sylfaen","serif";">კლასებში. შესაბამისად რომ მოვყვეთ თავიდან პირველ კლასში არის ფერის მოდიფიკაციები საზღვრებისთვის, კონტროლებისთვის და ფანჯრებისთვის, რომელიც ხელმისაწვდომია მთელს აპლიკაციაში. მეორე კლასი შეიცავს რესურსებს ფონტებისათვის, და მესამე კლასი კი ზომებს კონტროლებისთვის.</span><br /><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><b><span style="font-family: "Sylfaen","serif";">რესურსებზე წვდომა კოდის გამოყენებით<o:p></o:p></span></b></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">რესურსებზე ხელმისაწვდომად პირდაპირ კოდიდან შესაძლებელია </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">FrameworkElement </span><span style="font-family: "Sylfaen","serif";">ის მიერ იმპლემენტირებული მეთოდი </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">FindResource(). შესაძლებელია FindResource() </span><span style="font-family: "Sylfaen","serif";">გამოძახება ნებისმიერი </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">WPF </span><span style="font-family: "Sylfaen","serif";">ობიექტთან.</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">ამ ღილაკს არ აქვს მითითებული უკანა ფონი, მაგრამ გააჩნია </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">Click </span><span style="font-family: "Sylfaen","serif";">მოვლენა</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Name</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button1"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Width</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="220"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Height</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="50"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Margin</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="5"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Click</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button1_Click"></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: "Sylfaen","serif";">რესურსის</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: "Sylfaen","serif";">პროგრამულად</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: "Sylfaen","serif";">მინიჭება</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"> ></span><span style="color: blue; font-family: "Sylfaen","serif";"><o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">ამ მოვლენის იმპლემენტაციისას ზემოთ ხსენებული მეთოდი გამოიყენება, რომელიც დაგეხმარებათ მითითებული რესურსის მოძებნაში. ფუნჯის სახელი არის </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">GradientBrush</span><span style="font-family: "Sylfaen","serif";">, რომელიც შეგიძლიათ სურვილისებრ შეცვალოთ. ხოლო, რაც შეეხება ძებნას, ის ხდება იერარქიულად, და ნაპოვნი ფუნჯი ენიშნება </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">Background </span><span style="font-family: "Sylfaen","serif";">თვისებას, რომელიც </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">button </span><span style="font-family: "Sylfaen","serif";">კონტროლისაა. ეს ფუნჯი შესრულებულია </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">stackpanel </span><span style="font-family: "Sylfaen","serif";">ში.</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Name</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="myContainer"></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">LinearGradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Key</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="GradientBrush"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> StartPoint</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0,0"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> EndPoint</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.3,1"></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.0"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="LightCyan" /></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.14"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Cyan" /></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Offset</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="0.7"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Color</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="DarkCyan" /></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">LinearGradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Name</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button1"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Width</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="220"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Height</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="50"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Margin</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="5"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Click</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button1_Click" ></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> Apply Resource Programmatically</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"><o:p></o:p></span></div><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">StackPanel</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="color: blue; font-family: "Sylfaen","serif";"><o:p></o:p></span><br /><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">მოვლენის კოდი კი იქნება შემდეგი</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">public</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> button1_Click(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">object</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> sender, </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">RoutedEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> e)</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> {</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Control</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> ctrl = sender </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">as</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Control</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">;</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> ctrl.Background = ctrl.FindResource(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">"GradientBrush"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">) </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">as</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Brush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">;</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> }</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><b><span style="color: black; font-family: "Sylfaen","serif";">დინამიური რესურსები<o:p></o:p></span></b></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="color: black; font-family: "Sylfaen","serif";">სტატიკური რესურსების გამოყენებისას, რომელსაც აქამდე ვიყენებდი, ისინი იძებნებიან ჩატვირთვის დროს. თუ რესურსი შეიცვლება პროგრამის გაშვების განმავლობაში მაშინ უნდა გამოიყენოთ </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">DynamicResource </span><span style="color: black; font-family: "Sylfaen","serif";">მონიშვნის გაფართოება.</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Button</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Name</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button2"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Width</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="200"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Height</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="50"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Foreground</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="White"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Margin</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="5"</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt 96pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Background</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="{</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">DynamicResource</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> GradientBrush</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">}"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Content</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="ChangeResource"</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Click</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="button2_Click" /></span><span style="color: blue; font-family: "Sylfaen","serif";"><o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">ზემოთ მოცემული მაგალითი იყენებს იმავე რესურსს, რომელიც მე უკვე დიდი ხანია განსაზღვრული მაქვს. წინა მაგალითი იყენებდა </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">StaticResource </span><span style="font-family: "Sylfaen","serif";">ს, ხოლო ამ მაგალითში კი ვიყენებთ დინამიურ რესურსს. მოვლენის კოდი კი პროგრამულად ცვლის რესურსს. მოვლენის კოდი წმენდს </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">StackPanel </span><span style="font-family: "Sylfaen","serif";">ის რესურსებს და ამატებს ახალ რესურსს იმავე </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">DGradientBrush</span><span style="font-family: "Sylfaen","serif";">, ეს რესურსი ჰგავს წინა რესურს. უბრალოდ იყენებს სხვა ფერებს.</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">private</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">void</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> button2_Click(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">object</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> sender, </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">RoutedEventArgs</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> e)</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> {</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> myContainer.Resources.Clear();</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">var</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> brush = </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">LinearGradientBrush</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> {</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> StartPoint = </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Point</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">(0, 0),</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> EndPoint = </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Point</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">(0, 1)</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> };<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> brush.GradientStops = </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">GradientStopCollection</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">()</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> {</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Colors</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">.White, 0.0),</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Colors</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">.Yellow, 0.14),</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">new</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">GradientStop</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #2b91af; font-family: Consolas;">Colors</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">.YellowGreen, 0.7)</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> };</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> myContainer.Resources.Add(</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">"DGradientBrush"</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;">, brush);</span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> }</span><span style="color: black; font-family: "Sylfaen","serif";"><o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="color: black; font-family: "Sylfaen","serif";">როდესაც პროგრამას გაუშვებთ რესურსი იცვლება დინამიურად ღილაკზე დაჭერისას. ხოლო ღილაკი სტატიკური რესურსით გამოიყურება იგივენაირად.<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><b><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">Resource Dictionaries<o:p></o:p></span></b></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="color: black; font-family: "Sylfaen","serif";">თუ ერთი და იმავე რესურსს იყენებს სხვადასხვა აპლიკაცია, მაშინ უფრო ჭკვიანურია მათი ცალკე ფაილში მოთავსება, რომელსაც ეწოდება </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">resource Dictionary. </span><span style="color: black; font-family: "Sylfaen","serif";">ის შეიძლება დარეგისტრირდეს ასამბლეაში და გაზიარდეს რამდენიმე აპლიკაციაში.<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="color: black; font-family: "Sylfaen","serif";">ამისთვის პროექტს უნდა დავუმატოთ </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">Resource Dictionary. Visual Studio </span><span style="color: black; font-family: "Sylfaen","serif";">ს მენიუს გამოყენებით შემდეგნაირად ხდება </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">Resource Dictionary</span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";"> </span><span style="color: black; font-family: "Sylfaen","serif";">ის დამატება - </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">Project -> Add New Item -> Resource Dictionary(WPF)</span><span style="color: black; font-family: "Sylfaen","serif";">.</span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">მე გამოყენებული მაქვს Dictionary1.xaml</span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";"> </span><span style="color: black; font-family: "Sylfaen","serif";">რომელში ჩვენ შეგვიძლია სტილები განვსაზღვროთ და ამ ფაილის გამოყენებით უკვე აპლიკაციის მასშტაბით გამოვიყენოთ ისინი.<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="color: black; font-family: "Sylfaen","serif";">დავუშვათ განვსაზღვრეთ ამ ფაილში რამდენიმე სტილი. ახლა საჭიროა, რომ ისინი ჩანდეს მთელი აპლიკაციის მასშტაბით, ამიტომ საჭიროა მისი რეგისტრაცია. ამისთვის უნდა შევიდეთ </span><span lang="EN-US" style="color: black; font-family: "Sylfaen","serif";">app.xaml </span><span style="color: black; font-family: "Sylfaen","serif";">ში, სადაც შემდეგი ცვლილებები უნდა შევიტანოთ<o:p></o:p></span></div><br /><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">Class</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="StylesAndResources.App"</span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">=<a href="http://schemas.microsoft.com/winfx/2006/xaml/presentation">http://schemas.microsoft.com/winfx/2006/xaml/presentation</a></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">xmlns</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">:</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">x</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">=<a href="http://schemas.microsoft.com/winfx/2006/xaml">http://schemas.microsoft.com/winfx/2006/xaml</a></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;">StartupUri</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="MainWindow.xaml"></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">ResourceDictionary</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">ResourceDictionary.MergedDictionaries</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"> ></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: "Sylfaen","serif";"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"><</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">ResourceDictionary</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: red; font-family: Consolas;"> Source</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">="Dictionary1.xaml"/></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">ResourceDictionary.MergedDictionaries</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">ResourceDictionary</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 0pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: black; font-family: Consolas;"> </span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application.Resources</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span></div><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;"></</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: #a31515; font-family: Consolas;">Application</span><span style="background-color: white; background-position: initial initial; background-repeat: initial initial; color: blue; font-family: Consolas;">></span><span style="color: blue; font-family: "Sylfaen","serif";"><o:p></o:p></span></div><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"></span><br /><div class="MsoNormal" style="margin: 0cm 0cm 8pt;"><span style="font-family: "Sylfaen","serif";">სადაც </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">Dictionary1.xaml </span><span style="font-family: "Sylfaen","serif";">პირდაპირ პროექტის </span><span lang="EN-US" style="font-family: "Sylfaen","serif";">solution </span><span style="font-family: "Sylfaen","serif";">შია მოთავსებული.</span></div></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><br /></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-88843155601384583222013-12-07T11:09:00.000-08:002014-06-20T07:54:42.255-07:00WPF - 6 (Layout)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="53" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">აპლიკაციის განლაგების განსაზღვრისთვის შეგიძლიათ გამოიყენოთ კლასი, რომლიც მემკვიდრეა </span><span style="font-family: "Sylfaen","serif";">Panel</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">კლასისა. რამდენიმე განლაგების კონტეინერებია ხელმისაწვდომი, რომლებსაც მე განვიხილავ. განლაგების კონტეინერს ესაჭიროება ჩაატაროს ორი დავალება: გაზომოს და დაალაგოს</span></span><span style="font-family: "Sylfaen","serif";"> (measure </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">arrange)</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">. გაზომვით კონტეინერი „ეკითხება“ შვილ კონტროლებს თუ რამდენი ადგილი ესაჭიროებათ მათ. რადგან შვილის მიერ შეთავაზებული ადგილი შეიძლება არ იყოს კონტეინერში მოთავსებადი (ჩატევადი), ამის შემდეგ კონტეინერი წყვეტს, თუ როგორ დაალაგოს შვილეული კონტროლები ოპტიმალურად.</span><br /><a name='more'></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შვილეულ / შვილ კონტროლებში ვგულისხმობ იმათ, რომლებიც მოთავსებულები არიან კონტეინერში. რომ წარმოვიდგინოთ ყუთი და ამ ყუთში მოთავსებული ღილაკი, იარლიყი და კიდევ სხვა. მოცემული გვაქვს 5 სახის განლაგების კონტეინერი, რომლების უნიკალურები არიან თავიანთი თვისებებით.<o:p></o:p></span></div><div class="MsoListParagraphCxSpFirst" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;"> Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">StackPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;"> Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">WrapPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;"> Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">Canvas</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;"> Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">DockPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;"> Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">Grid</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">დავიწყოთ თავიდან.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">StackPanel<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ფანჯარა შეიძლება შეიცავდეს ერთ კონტროლს როგორც შვილ კონტროლს. თუ საჭიროა, რომ ფანჯარაში ერთზე მეტი კონტროლი იყოს, მაშინ ერთ-ერთი გზაა გამოიყენოთ </span><span style="font-family: "Sylfaen","serif";">StackPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, როგორც ფანჯრის შვილეული და შემდეგ მასში ჩასვათ სხვა კონტროლები. ეს კონტეინერი საკმაოდ მარტივია, რომელიც ერთ ელემენტს აჩვენებს მეორეს გვერდით. </span><span style="font-family: "Sylfaen","serif";">StackPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ორიენტაცია შეიძლება იყოს ჰორიზონტალური და ვერტიკალური. ინფორმაციისთვის </span><span style="font-family: "Sylfaen","serif";">ToolBarPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი არის </span><span style="font-family: "Sylfaen","serif";">StackPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მემკვიდრე. <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-qKi52T82blM/UqNxsiXIgDI/AAAAAAAABiM/8THLWDNWQck/s1600/stackpanel.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://1.bp.blogspot.com/-qKi52T82blM/UqNxsiXIgDI/AAAAAAAABiM/8THLWDNWQck/s1600/stackpanel.PNG" width="608" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"> <v:stroke joinstyle="miter"> <v:formulas> <v:f eqn="if lineDrawn pixelLineWidth 0"> <v:f eqn="sum @0 1 0"> <v:f eqn="sum 0 0 @1"> <v:f eqn="prod @2 1 2"> <v:f eqn="prod @3 21600 pixelWidth"> <v:f eqn="prod @3 21600 pixelHeight"> <v:f eqn="sum @0 0 1"> <v:f eqn="prod @6 1 2"> <v:f eqn="prod @7 21600 pixelWidth"> <v:f eqn="sum @8 21600 0"> <v:f eqn="prod @7 21600 pixelHeight"> <v:f eqn="sum @10 21600 0"> </v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"> <o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="Picture_x0020_21" o:spid="_x0000_i1029" style="height: 492pt; mso-wrap-style: square; visibility: visible; width: 468pt;" type="#_x0000_t75"> <v:imagedata o:title="stackpanel" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ზემოთ მოცემულია </span><span style="font-family: "Sylfaen","serif";">StackPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის როგორც ჰორიზონტალური ისე ვერტიკალური ვერსია.</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"> </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ქვემოთ კი </span><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კოდი</span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Orientation</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Vertical"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0,0,0,20"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">ListBoxItem One</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">ListBoxItem Two</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Orientation</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Horizontal"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">CheckBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">ListBoxItem One</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;">ListBoxItem Two</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBoxItem</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ListBox</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">StackPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">WrapPanel<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს განლაგება ელემენტებს ათავსებს მარცხნიდან მარჯვნივ თითოეულის მიმდევრობით. ამ განლაგებასაც შეიძლება ჰქონდეს როგორც ვერტიკალური, ისე ჰორიზონტალური ორიენტაცია<o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-1H1R70QteJw/UqNxst2H6rI/AAAAAAAABiE/iSgNXjSxJto/s1600/wrapPanel.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="270" src="http://2.bp.blogspot.com/-1H1R70QteJw/UqNxst2H6rI/AAAAAAAABiE/iSgNXjSxJto/s1600/wrapPanel.PNG" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_22" o:spid="_x0000_i1028" style="height: 276pt; mso-wrap-style: square; visibility: visible; width: 407.25pt;" type="#_x0000_t75"> <v:imagedata o:title="wrapPanel" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image002.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">WrapPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button1</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button2</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button3</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button4</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button5</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button6</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button7</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5"></span><span style="background-color: white; font-family: Consolas;">Button8</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">WrapPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">აპლიკაციის ზომის შეცვლის ზემოთ გვექნება მსგავსი რამ<o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-OLw-C2Ip5rc/UqNxlzkj-3I/AAAAAAAABhY/kSFlUsnoLW0/s1600/wrappanel2.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="320" src="http://2.bp.blogspot.com/-OLw-C2Ip5rc/UqNxlzkj-3I/AAAAAAAABhY/kSFlUsnoLW0/s1600/wrappanel2.PNG" width="245" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_23" o:spid="_x0000_i1027" style="height: 262.5pt; mso-wrap-style: square; visibility: visible; width: 201pt;" type="#_x0000_t75"> <v:imagedata o:title="wrappanel2" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image003.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Canvas<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის პანელი, რომელიც საშუალებას გაძლევთ მკაფიოდ განათავსოთ ელემენტები. </span><span style="font-family: "Sylfaen","serif";">Canvas </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში განსაზღვრულია მიბმული თვისებები: </span><span style="font-family: "Sylfaen","serif";">Left, Right, Top, Bottom</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, რომლებიც შეიძლება გამოყენებულ იქნას პანელში პოზიციის განსასაზღვრად<o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-eaYWEIzr9dQ/UqNxsKEvKHI/AAAAAAAABhw/1Lc0dWFZJ1M/s1600/Canvas.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="273" src="http://2.bp.blogspot.com/-eaYWEIzr9dQ/UqNxsKEvKHI/AAAAAAAABhw/1Lc0dWFZJ1M/s1600/Canvas.PNG" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_24" o:spid="_x0000_i1026" style="height: 287.25pt; mso-wrap-style: square; visibility: visible; width: 419.25pt;" type="#_x0000_t75"> <v:imagedata o:title="Canvas" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image004.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Canvas</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="LightBlue"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Canvas.Top</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="30"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Canvas.Left</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="20"></span><span style="background-color: white; font-family: Sylfaen, serif;">დაბეჭდე</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; font-family: Sylfaen, serif;">აქ</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Canvas.Top</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="30"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Canvas.Left</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="120"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Button</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Canvas.Top</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="70"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Canvas.Left</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="130"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">დამაჭირე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">!"</span><span lang="GEO/KAT" style="background: white; color: red; font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas; mso-highlight: white;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Padding</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="5" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Canvas</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="color: blue; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: Consolas;">DockPanel<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">DockPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ძალიან გავს </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Windows Forms </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ში </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">dock </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ფუნქციას (მათთვის იქნება ნაცნობი ვისაც შეხება ჰქონია ამ ტექნოლოგიასთან). აქ შესაძლებელია იმ ფართის მითითება, სადაც შვილეული კონტროლები უნდა დალაგდეს. </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">DockPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ს გააჩნია თვისება </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Dock, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">რომელთა დაყენებაც შესაძლებელია შვილეულ ელემენტებში დაკონფიგურდეს: </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Left, Right, Top, Bottom.</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"> <span lang="GEO/KAT">მოცემულია მაგალითი, სხვადასხვა ფერების გამოყენებით, რაც უფრო აადვილებს გარჩევას<o:p></o:p></span></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-tzHW4w8bkY8/UqNxsB01TxI/AAAAAAAABh0/_TPZG_OGagU/s1600/dockpanel.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="268" src="http://1.bp.blogspot.com/-tzHW4w8bkY8/UqNxsB01TxI/AAAAAAAABh0/_TPZG_OGagU/s1600/dockpanel.PNG" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><span lang="GEO/KAT"><br /></span></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">DockPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="25"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="red"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">DockPanel.Dock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Top"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Sylfaen, serif;">მენიუ</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="25"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Blue"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">DockPanel.Dock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Top"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Sylfaen, serif;">სამუშაო</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; font-family: Sylfaen, serif;">ხაზი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="30"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Green"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">DockPanel.Dock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Bottom"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Sylfaen, serif;">სტატუსი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="80"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Yellow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">DockPanel.Dock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Left"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Sylfaen, serif;">მარცხენა</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; font-family: Sylfaen, serif;">მხარე</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Background</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Azure"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Sylfaen, serif;">კონტექსტის</span><span style="background-color: white; font-family: Consolas;"> </span><span style="background-color: white; font-family: Sylfaen, serif;">ადგილი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBlock</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Border</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">DockPanel</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Grid<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Grid</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"> <span lang="GEO/KAT">ის გამოყენებით შესაძლებელია კონტროლების დალაგება რიგებისა და სვეტების მიხედვით. ყველა სვეტისთვის შესაძლებელია </span></span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">ColumnDefinition </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ის განსაზღვრა. ყველა რიგისთვის შესაძლებელია </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">RowDefinition </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ის განსაზღვრა. ყველა სვეტისათვის და რიგისთვის შესაძლებელია სიმაღლისა და სიგანის განსაზღვრა. </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">ColumnDefinition </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ს გააჩნია </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Width </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">თვისება, ხოლო </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">RowDefinition </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ს გააჩნია </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Height </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">თვისება. სიგანისა და სიმაღლის განსაზღვრა შესაძლებელია პიქსელებში, ინჩებში, სანტიმეტრებში ან წერტილებში, ან უბრალოდ </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Auto, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">რომ განისაზღვროს ზომები, კონტექსტის მიხედვით. ამ კონტეინერს ასევე შეუძლია „ვარსკვლავური“ ზომების იმპლემენტაცია. მაგალითისათვის ავიღოთ სამ სვეტიანი </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Grid </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">კონტეინერი, რომლის პირველი სვეტის </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Width = “100”, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">მესამე სვეტის </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Width = “120”, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ხოლო შუა სვეტის ზომა შეგვიძლია ასეც მივუთითოთ - </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Width = “<b>*</b>”, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ვარსკვლავი იმას ნიშნავს, რომ რაც კი ადგილი დარჩა შეუძლია დაიკავოს ამ სვეტმა. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-QEXtwRFfRF4/UqNxsDnsXxI/AAAAAAAABho/PtxMo9SNYss/s1600/grid.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="260" src="http://4.bp.blogspot.com/-QEXtwRFfRF4/UqNxsDnsXxI/AAAAAAAABho/PtxMo9SNYss/s1600/grid.PNG" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas; mso-no-proof: yes;"><v:shape id="Picture_x0020_25" o:spid="_x0000_i1025" style="height: 271.5pt; mso-wrap-style: square; visibility: visible; width: 416.25pt;" type="#_x0000_t75"> <v:imagedata o:title="grid" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image005.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Class</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="App_for_blogpost_tutorials.MainWindow"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml/presentation"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> xmlns</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">x</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="http://schemas.microsoft.com/winfx/2006/xaml"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Title</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="MainWindow"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="350"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="525"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">ShowGridLines</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="True"></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid.ColumnDefinitions</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ColumnDefinition</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">ColumnDefinition</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid.ColumnDefinitions</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid.RowDefinitions</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">RowDefinition</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">RowDefinition</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">RowDefinition</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">/></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid.RowDefinitions</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Column</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Grid.ColumnSpan</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="2"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Row</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> VerticalAlignment</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Center"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">HorizontalAlignment</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Center"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">სათაური</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Column</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Grid.Row</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="1"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">VerticalAlignment</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Center"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">სახელი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="10" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Column</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="1"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Grid.Row</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="1"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="30" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Label</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Column</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="0"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Grid.Row</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="2"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">VerticalAlignment</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="Center"</span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Content</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="</span><span style="background: white; color: blue; font-family: "Sylfaen","serif"; mso-bidi-font-family: Sylfaen; mso-highlight: white;">გვარი</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">:"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Margin</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="10" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"><</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">TextBox</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Grid.Column</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="1"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Grid.Row</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="2"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;">Width</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="100"</span><span style="background: white; color: red; font-family: Consolas; mso-highlight: white;"> Height</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">="30" /></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="margin-bottom: 0pt;"><span style="background-color: white; font-family: Consolas;"> </span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Grid</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span style="background-color: white; font-family: Consolas;"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;"></</span><span style="background: white; color: #a31515; font-family: Consolas; mso-highlight: white;">Window</span><span style="background: white; color: blue; font-family: Consolas; mso-highlight: white;">></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;"><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">კოდში </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-family: Consolas;">Grid </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Consolas;">ის უკეთ დასანახად გავლებულია ხაზები, რომლებიც ჩვეულებრივ არ ჩანს ხოლმე. <o:p></o:p></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-87973349096271804702013-12-05T09:38:00.000-08:002014-06-20T07:54:42.280-07:00WPF - 5 (კონტროლები)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" height="53" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">WPF</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ში შესაძლებელია ასობით კონტროლის გამოყენება. ყველა მათგანი რაღაცით გამოირჩევა და აქვს რაღაც დანიშნულება, რაც მათ ხდის უნიკალურს, მაგრამ ძირითადად მაინც ხდება ერთი სიის ჩამოყალიბება, სადაც ყველა კონტროლი არ შედის და ამ სიის წევრები ყველაზე ხშირად გამოყენებული კონტროლებია. უკეთესად გასაგებად, შეგვიძლია განვიხილოთ კონტროლები, რომლებიც დაყოფილია შემდეგ ჯგუფებად.</span></span></div><a name='more'></a><br /><div class="MsoListParagraphCxSpFirst" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">Simple</span><span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">Content</span><span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]--><span style="font-family: "Sylfaen","serif";">Headered content</span><span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]-->Items<span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoListParagraphCxSpMiddle" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]-->Headered items<span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoListParagraphCxSpLast" style="mso-list: l0 level1 lfo1; text-align: justify; text-indent: -0.25in;"><!--[if !supportLists]--><span lang="GEO/KAT" style="font-family: Wingdings; mso-ansi-language: "GEO/KAT"; mso-bidi-font-family: Wingdings; mso-fareast-font-family: Wingdings;">Ø<span style="font-family: 'Times New Roman'; font-size: 7pt;"> </span></span><!--[endif]-->Decoration<span lang="GEO/KAT"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ ნაწილში განვიხილავ პირველ ორ ნაწილს, ხოლო შემდეგში დანარჩენს. დავიწყოთ </span><b><span style="font-family: "Sylfaen","serif";">Simple </span></b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლის ჯგუფით, რომელშიც ის კონტროლები შედიან, რომელთაც არ გააჩნიათ </span><span style="font-family: "Sylfaen","serif";">Content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისება. ღილაკის კლასში თქვენ ნახეთ, რომ მას შეუძლია მიიღოს ნებისმიერი ფორმა, ან ჩაიშენოს თავის თავში კიდევ სხვა კონტროლები. შემდეგი რამ არ არის შესაძლებელი მარტივი კონტროლებისთვის. ქვემოთ გავაკეთე ცხრილი, სადაც მოყვანილია მარტივი კონტროლების მაგალითები და მათი მოკლე აღწერა, რომელიც საკმარისი უნდა იყოს ამ ეტაპზე.<o:p></o:p></span></div><table border="0" cellpadding="0" cellspacing="0" class="MsoTable15Plain4" style="border-collapse: collapse; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Slider<o:p></o:p></span></b></div></td> <td style="padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ამ კონტროლის დახმარებით შესაძლებელია </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">ScrollBar</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">, </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">ProgressBar, Slider </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ის გაკეთება, რომლებიც </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">RangeBsae</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;"> <span lang="GEO/KAT">ის მემკვიდრეები არიან, და მთავარი აზრი ის არის, რომ მაუსის ან თითის მოძრაობით შესაძლებელია ამ კონტროლის (რიცხვითი) მნიშვნელობის შეცვლა რაღაც მოცემულ დიაპაზონში.<o:p></o:p></span></span></div></td> </tr><tr> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ScrollBar<o:p></o:p></span></b></div></td> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">Slider</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის მსგავსად მომხმარებელს შეუძლია მაუსის მარტივი მოძრაობით გაუმკლავდეს ისეთ სიტუაციას, როდესაც დოკუმენტი მოცემულ ზომებში ბოლომდე ვერ ეტევა. კონტროლის გამოყენებით კი შესაძლებელია დოკუმენტის დამალული ნაწილების ჩვენება. თუ დოკუმენტი ძალიან დიდია, მაშინ ეს კონტროლი, სტანდარტულ შემთხვევაში, ავტომატურად ჩნდება.<o:p></o:p></span></span></div></td> </tr><tr> <td style="padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ProgeressBar<o:p></o:p></span></b></div></td> <td style="padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ კონტროლით შესაძლებელია ოპერაციის პროგრესის ჩვენება. მაგალითად როცა რაიმე იტვირთება.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">PasswordBox</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div></td> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლი გამოიყენება პაროლის შესაყვანად და აქვს სპეციალური თვისებები შემოსული პაროლისთვის. მაგალითად, </span><span style="font-family: "Sylfaen","serif";">PasswordChar</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">იმ სიმბოლოს განსასაზღვრად, რომელიც უნდა გამოჩნდეს მომხმარებლის მიერ შემოყვანილი პაროლის ნაცვლად (ხშირად ეს ვარსკვლავები ან წერტილებია), ან </span></span><span style="font-family: "Sylfaen","serif";">Password</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, რომ ვნახოთ პაროლი, რომელიც შემოიყვანა მომხმარებელმა. </span><span style="font-family: "Sylfaen","serif";">PasswordChanged </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მოვლენა გააქტიურდება მაშინ, როდესაც პაროლი შეიცვლება.<o:p></o:p></span></div></td> </tr><tr> <td style="padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Calendar<o:p></o:p></span></b></div></td> <td style="padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს კონტროლი ახალია და შემოვიდა </span><span style="font-family: "Sylfaen","serif";">.NET </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">4 თან ერთად. აჩვენებს თვეს, წელს და შესაძლებელია თარიღის(ების) არჩევა.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">DatePicker</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div></td> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის კონტროლი, რომელიც ხსნის ლოკალურ კალენდარს, იმისთვის, რომ მომხმარებელმა აირჩიოს სასურველი თარიღი.<o:p></o:p></span></div></td> </tr><tr> <td style="padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">TextBox<o:p></o:p></span></b></div></td> <td style="padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არაფორმატირებული ტექსტის საჩვენებლად გამოყენებადი კონტროლი<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 94.5pt;" valign="top" width="126"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">RichTextBox<o:p></o:p></span></b></div></td> <td style="background: rgb(242, 242, 242); mso-background-themecolor: background1; mso-background-themeshade: 242; padding: 0in 5.4pt; width: 373pt;" valign="top" width="497"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შესაძლებელია ტექსტის ჩვენება </span><span style="font-family: "Sylfaen","serif";">FlowDocument </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასის დახმარებით. <o:p></o:p></span></div></td> </tr></tbody></table><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Content </span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლები<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">Content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლებს, სახელიდან გამომდინარე, გააჩნია </span><span style="font-family: "Sylfaen","serif";">content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისება, რომლის დახმარებითაც შესაძლებელია </span><span style="font-family: "Sylfaen","serif";">content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის დამატება კონტროლში. </span><span style="font-family: "Sylfaen","serif";">Button </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი არის </span><span style="font-family: "Sylfaen","serif";">ContentControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის მემკვიდრე და სწორედ ამიტომ არის შესაძლებელი მასში შიგთავსის დამატება. წინა მაგალითებში თქვენ ნახეთ </span></span><span style="font-family: "Sylfaen","serif";">StackPanel </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Grid </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ღილაკში მოთავსების მაგალითიც. <o:p></o:p></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Grid2Accent2" style="border-collapse: collapse; border: currentColor; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Button<o:p></o:p></span></b></div></td> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">კონტროლის წინაპარი კლასია </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">ButtonBase</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">, რომელსაც </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">Button </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">კლასთან ერთად ჰყავს </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">ReapeatButton, ToggleButton, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">მემკვიდრეები. ყველა ზემოთ ჩამოთვლილი რეაგირებს </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">Click </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">მოვლენაზე. </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">ToggleButton </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">არის საბაზო კლასი </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">RadioButton </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">და </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">CheckBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ისთვის, რომლებსაც ორი მდგომარეობა გააჩნიათ - ჩართული და გამორთული ან, შესაბამისად, მონიშნული და ცარიელი. </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">CheckBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ის მონიშვნა და გაწმენდა შესაძლებელია მომხმარებლის მიერ, მაგრამ </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">RadioButton</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;"> <span lang="GEO/KAT">ის გაწმენდა უკვე პროგრამული მანიპულატორის საქმეა.</span></span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;"><o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(251, 228, 213); border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Frame<o:p></o:p></span></b></div></td> <td style="background: rgb(251, 228, 213); border: currentColor; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლი გამოიყენება ნავიგაციისთვის, რომლის ძირითადი მეთოდია </span><span style="font-family: "Sylfaen","serif";">Navigate()</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, და ამით ხდება გვერდებს შორის ნავიგაცია.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Label<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი წარმოადგენს კონტროლისთვის უბრალო ტექსტს.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(251, 228, 213); border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ListBoxItem<o:p></o:p></span></b></div></td> <td style="background: rgb(251, 228, 213); border: currentColor; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის </span><span style="font-family: "Sylfaen","serif";">ListBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში მოთავსებული წევრი.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">StatusBarItem<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">StatusBar </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლის შიდა წევრი</span><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(251, 228, 213); border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ScrollViewer<o:p></o:p></span></b></div></td> <td style="background: rgb(251, 228, 213); border: currentColor; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის კონტექსტური კონტროლი, რომელიც შეიცავს </span><span style="font-family: "Sylfaen","serif";">ScrollBar </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ებს. ამ კონტროლში შესაძლებელია ნებისმიერი ინფორმაციის მოთავსება, ხოლო </span><span style="font-family: "Sylfaen","serif";">ScrollBar </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ები გამოჩნდებიან საჭიროების შემთხვევაში.</span><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ToolTip<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი აკეთებს </span><span style="font-family: "Sylfaen","serif";">pop-up </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ფანჯარას, რომელიც დაწვრილებით ინფორმაციას იძლევა კონტროლისთვის. მაგალითისთვის შეიძლება აიღოთ: სამუშაო მაგიდაზე მოთავსებულ ფაილზე თუ კურსორს მიიტანთ და გააჩერებთ, მაშინ </span><span style="font-family: "Sylfaen","serif";">pop-up </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ფანჯარა გაჩნდება და დაინახავთ მეტ ინფორმაციას ამ ფაილის-კონტროლის შესახებ.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(251, 228, 213); border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">NavigateionWindow<o:p></o:p></span></b></div></td> <td style="background: rgb(251, 228, 213); border: currentColor; mso-background-themecolor: accent2; mso-background-themetint: 51; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი არის </span><span style="font-family: "Sylfaen","serif";">Window</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">კლასის მემკვიდრე და არის კონტექსტური ნავიგატორი.<o:p></o:p></span></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(244, 176, 131) rgb(244, 176, 131) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #F4B083 .25pt; mso-border-right-themecolor: accent2; mso-border-right-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Window<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #F4B083 .25pt; mso-border-bottom-themecolor: accent2; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #F4B083 .25pt; mso-border-left-themecolor: accent2; mso-border-left-themetint: 153; mso-border-top-alt: solid #F4B083 .25pt; mso-border-top-themecolor: accent2; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი საშუალებას გვაძლევს შევქმნათ </span><span style="font-family: "Sylfaen","serif";">dialog Box </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ები და ფანჯრები. სტანდარტული სახე არის ფანჯარა, რომელსაც გააჩნია მაქსიმიზაცია/მინიმიზაცია/დახურვა ღილაკები და სისტემური მენიუ. </span><span style="font-family: "Sylfaen","serif";">dialogBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის და ფანჯრის საჩვენებლად ვიყენებთ შესაბამისად შემდეგ მეთოდებს - </span><span style="font-family: "Sylfaen","serif";">ShowDialog() </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Show()</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div></td> </tr></tbody></table><br /><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Headered Content Controls</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">Content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლები </span><span style="font-family: "Sylfaen","serif";">Header</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ით მემკვიდრეობენ</span></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"> </span><span style="font-family: "Sylfaen","serif";">HeaderedContentControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ისაგან, რომლის წინაპარიცაა </span></span><span style="font-family: "Sylfaen","serif";">ContentControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">კლასი. </span></span><span style="font-family: "Sylfaen","serif";">HeaderedContentControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ებს გააჩნიათ თვისება </span></span><span style="font-family: "Sylfaen","serif";">Header</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, რომლითაც შესაძლებელია კონტექსტის განსაზღვრა, მეორეს მხრივ კი შესაძლებელია მათი სრული დიზაინის შექმნა </span><span style="font-family: "Sylfaen","serif";">HeaderTemplate </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის გამოყენებით. ქვემოთ მოცემულია ის კონტროლები, რომელთათვის საბაზო კლასი არის </span><span style="font-family: "Sylfaen","serif";">HeaderedContentControl </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი. <o:p></o:p></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Grid2Accent1" style="border-collapse: collapse; border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"><tbody><tr><td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 67.5pt;" valign="top" width="90"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Expander<o:p></o:p></span></b></div></td><td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 400pt;" valign="top" width="533"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ამ კლასის გამოყენებით შესაძლებელია უფრო განვითარებული </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">dialog box </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ის შექმნა, რომელიც სტანდარტულად არ აჩვენებს ყველა ინფორმაციას, მაგრამ შესაძლებელია მომხმარებლის მიერ გაფართოვდეს ინფორმაციის თვალსაწიერი. გაუფართოებელ ფორმაში კი ჩანს მხოლოდ სათაურის კონტექსტი(</span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">herader)</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">. <o:p></o:p></span></div></td></tr><tr><td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 67.5pt;" valign="top" width="90"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">TabItem<o:p></o:p></span></b></div></td><td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 400pt;" valign="top" width="533"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლი არის </span><span style="font-family: "Sylfaen","serif";">TabControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის წევრი. ამ კლასის </span></span><span style="font-family: "Sylfaen","serif";">Header</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">თვისება განსაზღვრავს თუ რა უნდა გამოჩნდეს </span></span><span style="font-family: "Sylfaen","serif";">TabControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ში მოთავსებული ტაბების სათაურად.<o:p></o:p></span></span></div></td></tr><tr><td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 67.5pt;" valign="top" width="90"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">GroupBox<o:p></o:p></span></b></div></td><td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 400pt;" valign="top" width="533"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს კონტროლი საშუალებას გვაძლევს მასში ჩავსვათ სხვა კონტროლები, და თან ეს კონტროლები იყვნენ შემოსაზღვრულები და დასათაურებულები. <o:p></o:p></span></div></td></tr></tbody></table><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ქვემოთ არის მარტივი </span><span style="font-family: "Sylfaen","serif";">Expander </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მაგალით მოცემული. მას გააჩნია </span><span style="font-family: "Sylfaen","serif";">Header </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისება, რომელიც არის, ჩვენს შემთხვევაში, „დამაჭირე გასაფართოებლად“. როდესაც კონტროლი გაფართოვდება, მაშინ გამოჩნდება </span><span style="font-family: "Sylfaen","serif";">Content </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისებაში მოთავსებული ტექსტური ცვლად, თუ არსებობოს. <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-aW5ixLRaiaw/UqH5O4yNq5I/AAAAAAAABgU/7WPiPtLIdcU/s1600/exp0.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://1.bp.blogspot.com/-aW5ixLRaiaw/UqH5O4yNq5I/AAAAAAAABgU/7WPiPtLIdcU/s1600/exp0.PNG" height="640" width="624" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://4.bp.blogspot.com/-S9a4ecHHli0/UqH5O2OXD2I/AAAAAAAABgQ/D8nK2ELcVdo/s1600/exp1.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://4.bp.blogspot.com/-S9a4ecHHli0/UqH5O2OXD2I/AAAAAAAABgQ/D8nK2ELcVdo/s1600/exp1.PNG" height="267" width="400" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-54yvP8HxT7s/UqH5OxlNTUI/AAAAAAAABgY/VVDUoprqL9k/s1600/exp2.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-54yvP8HxT7s/UqH5OxlNTUI/AAAAAAAABgY/VVDUoprqL9k/s1600/exp2.PNG" height="267" width="400" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"><v:stroke joinstyle="miter"><v:formulas><v:f eqn="if lineDrawn pixelLineWidth 0"><v:f eqn="sum @0 1 0"><v:f eqn="sum 0 0 @1"><v:f eqn="prod @2 1 2"><v:f eqn="prod @3 21600 pixelWidth"><v:f eqn="prod @3 21600 pixelHeight"><v:f eqn="sum @0 0 1"><v:f eqn="prod @6 1 2"><v:f eqn="prod @7 21600 pixelWidth"><v:f eqn="sum @8 21600 0"><v:f eqn="prod @7 21600 pixelHeight"><v:f eqn="sum @10 21600 0"></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"><o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="Picture_x0020_18" o:spid="_x0000_i1027" style="height: 479.25pt; mso-wrap-style: square; visibility: visible; width: 468pt;" type="#_x0000_t75"> <v:imagedata o:title="exp0" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_19" o:spid="_x0000_i1026" style="height: 265.5pt; mso-wrap-style: square; visibility: visible; width: 396pt;" type="#_x0000_t75"><v:imagedata o:title="exp1" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image002.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span><br /></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_20" o:spid="_x0000_i1025" style="height: 265.5pt; mso-wrap-style: square; visibility: visible; width: 396pt;" type="#_x0000_t75"><v:imagedata o:title="exp2" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image003.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span><br /></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Item Controls</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">ItemControl</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">კლასი შეიცავს წევრების სიას, რომელზეც წვდომა შესაძლებელია განხორციელდეს </span></span><span style="font-family: "Sylfaen","serif";">Items </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისების გამოყენებით. ქვემოთ მოცემულია კლასები, რომლებიც მემკვიდრეობენ </span><span style="font-family: "Sylfaen","serif";">ItemControl </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასიდან.<o:p></o:p></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Grid2Accent6" style="border-collapse: collapse; border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"><tbody><tr><td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 121.5pt;" valign="top" width="162"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Menu, ContextMenu<o:p></o:p></span></b></div></td><td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 346pt;" valign="top" width="461"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">მემკვიდრეები არიან აბსტრაქტული საბაზო კლასისა </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">MenuBase</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">. შესაძლებელია მომხმარებელს შესთავაზოთ მენიუ </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">MenuItem </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ელემენტის დამატებით </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">Item </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">სიაში<o:p></o:p></span></div></td></tr><tr><td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 121.5pt;" valign="top" width="162"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">StatusBar<o:p></o:p></span></b></div></td><td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 346pt;" valign="top" width="461"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ჩვეულებრივ მოთავსებულია აპლიკაციის ქვედა ნაწილში და მომხმარებელს აჩვენებს აპლიკაციის სტატუსს. </span><span style="font-family: "Sylfaen","serif";">StatusBarItem </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მოთავსება შესაძლებელია </span><span style="font-family: "Sylfaen","serif";">StatusBar </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის წევრების სიაში<o:p></o:p></span></div></td></tr><tr><td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 121.5pt;" valign="top" width="162"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ListBox, ComboBox, TabControl<o:p></o:p></span></b></div></td><td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 346pt;" valign="top" width="461"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მემკვიდრეობენ ერთი და იმავე აბსტრაქტული კლასისაგან </span><span style="font-family: "Sylfaen","serif";">Selector.</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">საბაზო კლასი საშუალებას იძლევა ავირჩიოთ ამ კონტროლების წევრები. <o:p></o:p></span></span></div></td></tr><tr><td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 121.5pt;" valign="top" width="162"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Treeview<o:p></o:p></span></b></div></td><td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 346pt;" valign="top" width="461"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">წევრების იერარქიულად საჩვენებლად გამოიყენება </span><span style="font-family: "Sylfaen","serif";">Treeview </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლი.<o:p></o:p></span></div></td></tr><tr><td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 121.5pt;" valign="top" width="162"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">DataGrid<o:p></o:p></span></b></div></td><td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 346pt;" valign="top" width="461"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის გარეგნულად დახვეწილი </span><span style="font-family: "Sylfaen","serif";">Grid</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, სპეციალურად მონაცემების საჩვენებლად. ეს კონტროლი ახალია და შემოვიდა </span><span style="font-family: "Sylfaen","serif";">.NET 4 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თან ერთად<o:p></o:p></span></div></td></tr></tbody></table><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";"><b>Headered Items Controls</b><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">HeaderedItemsControl </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის იმ კონტროლების საბაზო კლასი, რომელსაც გააჩნიათ წევრები და ამავე დროს ეს წევრები საშუალებას იძლევიან, რომ ჰქონდეთ სათაური. ქვემოთ მოცემულია ეს კონტროლები.<o:p></o:p></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Plain1" style="border-collapse: collapse; border: currentColor; mso-border-alt: solid #BFBFBF .5pt; mso-border-themecolor: background1; mso-border-themeshade: 191; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"><tbody><tr><td style="border: 1pt solid rgb(191, 191, 191); mso-border-alt: solid #BFBFBF .5pt; mso-border-themecolor: background1; mso-border-themeshade: 191; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">MenuItem<o:p></o:p></span></b></div></td><td style="border: 1pt solid rgb(191, 191, 191); mso-border-alt: solid #BFBFBF .5pt; mso-border-left-alt: solid #BFBFBF .5pt; mso-border-left-themecolor: background1; mso-border-left-themeshade: 191; mso-border-themecolor: background1; mso-border-themeshade: 191; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">კლასები </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">Menu, ContextMenu</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;"> <span lang="GEO/KAT">შეიცავენ წევრებს, რომლებიც არის </span></span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">MenuItem </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ტიპის. მენიუს წევრები შეიძლება პირდაპირ დაუკავშირდნენ ბრძანებებს, რადგან </span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">MenuItem</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;"> <span lang="GEO/KAT">კლასი იმპლემენტაციას უკეთებს </span></span><span style="font-family: "Sylfaen","serif"; mso-bidi-font-weight: bold;">IcommandSource </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT"; mso-bidi-font-weight: bold;">ინტერფეისს.<o:p></o:p></span></div></td></tr><tr><td style="background: rgb(242, 242, 242); border: 1pt solid rgb(191, 191, 191); mso-background-themecolor: background1; mso-background-themeshade: 242; mso-border-alt: solid #BFBFBF .5pt; mso-border-themecolor: background1; mso-border-themeshade: 191; mso-border-top-alt: solid #BFBFBF .5pt; mso-border-top-themecolor: background1; mso-border-top-themeshade: 191; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">TreeViewItem<o:p></o:p></span></b></div></td><td style="background: rgb(242, 242, 242); border-color: currentColor rgb(191, 191, 191) rgb(191, 191, 191) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: background1; mso-background-themeshade: 242; mso-border-alt: solid #BFBFBF .5pt; mso-border-bottom-themecolor: background1; mso-border-bottom-themeshade: 191; mso-border-left-alt: solid #BFBFBF .5pt; mso-border-left-themecolor: background1; mso-border-left-themeshade: 191; mso-border-right-themecolor: background1; mso-border-right-themeshade: 191; mso-border-themecolor: background1; mso-border-themeshade: 191; mso-border-top-alt: solid #BFBFBF .5pt; mso-border-top-themecolor: background1; mso-border-top-themeshade: 191; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის </span><span style="font-family: "Sylfaen","serif";">Treeview </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლის წევრის ტიპი<o:p></o:p></span></div></td></tr><tr><td style="border: 1pt solid rgb(191, 191, 191); mso-border-alt: solid #BFBFBF .5pt; mso-border-themecolor: background1; mso-border-themeshade: 191; mso-border-top-alt: solid #BFBFBF .5pt; mso-border-top-themecolor: background1; mso-border-top-themeshade: 191; padding: 0in 5.4pt; width: 80.75pt;" valign="top" width="108"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ToolBar<o:p></o:p></span></b></div></td><td style="border-color: currentColor rgb(191, 191, 191) rgb(191, 191, 191) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-alt: solid #BFBFBF .5pt; mso-border-bottom-themecolor: background1; mso-border-bottom-themeshade: 191; mso-border-left-alt: solid #BFBFBF .5pt; mso-border-left-themecolor: background1; mso-border-left-themeshade: 191; mso-border-right-themecolor: background1; mso-border-right-themeshade: 191; mso-border-themecolor: background1; mso-border-themeshade: 191; mso-border-top-alt: solid #BFBFBF .5pt; mso-border-top-themecolor: background1; mso-border-top-themeshade: 191; padding: 0in 5.4pt; width: 386.75pt;" valign="top" width="516"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის კონტროლი, რომელიც თავის მხრივ შეიცავს კონტროლების ჯგუფს. ჩვეულებრივ </span><span style="font-family: "Sylfaen","serif";">Button </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Separator</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ელემენტებს. </span></span><span style="font-family: "Sylfaen","serif";">ToolBar </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მოთავსება შესაძლებელია </span><span style="font-family: "Sylfaen","serif";">ToolBarTray </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს შიგნით</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"> </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div></td></tr></tbody></table><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Decoration <o:p></o:p></span></b></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">დეკორაციები ასოცირდებიან საზღვრებთან </span><span style="font-family: "Sylfaen","serif";">ViewBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თან და სიებთან. </span><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-46780194686642908942013-12-04T00:31:00.000-08:002014-06-20T07:54:42.322-07:00WPF - 4(ფუნჯები)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="53" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ ნაწილში ავხსნი თ როგორ შეგვიძლია გამოვიყენოთ ფუნჯები </span><span style="font-family: "Sylfaen","serif";">WPF</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ში უკანა და წინა ხედისთვის ფერის მისაცემად. ფუნჯები თავის მხრივ იყოფიან რამდენიმე ნაწილად და ვაპირებ თითოეულ მათგანს შევეხო იმ დონეზე, რომ იყოს გასაგები, შემდეგ კი იმპროვიზაციას შეგიძლიათ მიმართოთ, სხვადასხვა კომბინაციების გამოყენებით და სასურველი შედეგის მისაღებად. დავიწყოთ ფუნჯების ვარიაციების განხილვა</span></span></div><a name='more'></a><br /><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">SolidColorBrush</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-dAFERNi35Ew/Up7ncPa1TOI/AAAAAAAABfI/VCq6rv53NAo/s1600/solidColorBrush.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="468" src="http://3.bp.blogspot.com/-dAFERNi35Ew/Up7ncPa1TOI/AAAAAAAABfI/VCq6rv53NAo/s1600/solidColorBrush.PNG" width="640" /></a></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";"><br /></span></b></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shapetype coordsize="21600,21600" filled="f" id="_x0000_t75" o:preferrelative="t" o:spt="75" path="m@4@5l@4@11@9@11@9@5xe" stroked="f"> <v:stroke joinstyle="miter"> <v:formulas> <v:f eqn="if lineDrawn pixelLineWidth 0"> <v:f eqn="sum @0 1 0"> <v:f eqn="sum 0 0 @1"> <v:f eqn="prod @2 1 2"> <v:f eqn="prod @3 21600 pixelWidth"> <v:f eqn="prod @3 21600 pixelHeight"> <v:f eqn="sum @0 0 1"> <v:f eqn="prod @6 1 2"> <v:f eqn="prod @7 21600 pixelWidth"> <v:f eqn="sum @8 21600 0"> <v:f eqn="prod @7 21600 pixelHeight"> <v:f eqn="sum @10 21600 0"> </v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:f></v:formulas> <v:path gradientshapeok="t" o:connecttype="rect" o:extrusionok="f"> <o:lock aspectratio="t" v:ext="edit"></o:lock></v:path></v:stroke></v:shapetype><v:shape id="Picture_x0020_12" o:spid="_x0000_i1030" style="height: 345pt; mso-wrap-style: square; visibility: visible; width: 468pt;" type="#_x0000_t75"> <v:imagedata o:title="solidColorBrush" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png"></v:imagedata></v:shape></span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ზემოთ მოცემული ღილაკი იყენებს </span><span style="font-family: "Sylfaen","serif";">SolidColorBrush</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ს, როგორც ამჩნევთ მთლიანი ფართი დაფარულია ერთი და იმავე ფერით. ჩვეულებრივ </span></span><span style="font-family: "Sylfaen","serif";">SolidColorBrush</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის გამოყენების გარეშეც შესაძლებელია ღილაკ კონტროლისთვის ფერის მინიჭება, რაშიც მისი თვისება </span></span><span style="font-family: "Sylfaen","serif";">Background </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ი გვეხმარება, რომელიც ტექსტურ ცვლადს აფორმატებს ფერში.</span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">LinearGradientBrush</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ფერების უფრო დინამიური და გლუვი ცვლილებებისთვის შესაძლებელია გამოიყენოთ </span><span style="font-family: "Sylfaen","serif";">LinearGradientBrush</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, როგორც ქვემოთ არის ნაჩვენები ეს ფუნჯი განსაზღვრავს </span><span style="font-family: "Sylfaen","serif";">StartPoint </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">EndPoint </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისებებს. ამ თვისებების გამოყენებით შესაძლებელია ორ განზომილებიანი კოორდინატების დანიშვნა ფუნჯისთვის. სტანდარტული ფუნჯი, რომელიც არის </span><span style="font-family: "Sylfaen","serif";">gradient </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ტიპის იყენებს დიაგონალურ მნიშვნელობებს, რაც იმას ნიშნავს, რომ იწყება 0,0 კოორდინატში და სრულდება 1,1 კოორდინატში, რომელიც მაქსიმალურია მისთვის და წარმოადგენს ფიგურის დასასრულს. სხვა მნიშვნელობებისთვის გრადაციამ შეიძლება შეიცვალოს მიმართულებები. მაგალითისთვის ავიღოთ </span><span style="font-family: "Sylfaen","serif";">StartPoint </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">0,0 და </span><span style="font-family: "Sylfaen","serif";">EndPoint</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">0,1 მივიღებთ ვერტიკალურ გრადაციას. <o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ ფუნჯის შიგთავსის გათვალისწინებით, შესაძლებელია ფიგურის წერტილებში განსაზღვროთ სასურველი ფერის დაწყების კოორდინატები. </span><span style="font-family: "Sylfaen","serif";">GradientStop</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ელემენტის გამოყენებით. <o:p></o:p></span></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-ZAJIyN7g8Gc/Up7nmVh2RBI/AAAAAAAABfQ/SnTCphMLPkU/s1600/linearGradientBrush.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="466" src="http://2.bp.blogspot.com/-ZAJIyN7g8Gc/Up7nmVh2RBI/AAAAAAAABfQ/SnTCphMLPkU/s1600/linearGradientBrush.PNG" width="640" /></a></div><div class="separator" style="clear: both; text-align: center;"><br /></div><br /><br /><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_13" o:spid="_x0000_i1029" style="height: 341.25pt; mso-wrap-style: square; visibility: visible; width: 467.25pt;" type="#_x0000_t75"> <v:imagedata o:title="linearGradientBrush" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image002.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> </span><b><span style="font-family: "Sylfaen","serif";">RadialGradientBrush<o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">RadialGradientBrush</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის გამოყენებით შესაძლებელია ფერების გლუვი განაწილება წრიული ფორმით. ეს ფუნჯი განსაზღვრავს ფერის საწყისს, რომელიც იწყება </span></span><span style="font-family: "Sylfaen","serif";">GradientOrigin </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">წერტილიდან. <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-WTGAf5o7SAQ/Up7no7xYSkI/AAAAAAAABgE/BJKk3kwv6Hc/s1600/RadialGradientBrush.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="514" src="http://2.bp.blogspot.com/-WTGAf5o7SAQ/Up7no7xYSkI/AAAAAAAABgE/BJKk3kwv6Hc/s1600/RadialGradientBrush.PNG" width="640" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_14" o:spid="_x0000_i1028" style="height: 376.5pt; mso-wrap-style: square; visibility: visible; width: 467.25pt;" type="#_x0000_t75"> <v:imagedata o:title="RadialGradientBrush" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image003.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ImageBrush</span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სურათზე ფუნჯის გადასატარებლად საჭიროა სურათი და </span><span style="font-family: "Sylfaen","serif";">ImageBrush </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ელემენტი, რომელიც ამის საშუალებას გაძლევთ. ამ ელემენტშივე ხდება სურათის წყაროს მითითება<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Button Content="Image Brush" Width="100" Height="80" Margin="5"<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">Foreground="White"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Button.Background><o:p></o:p></span></div><div class="MsoNormal" style="margin-left: 0.5in; text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><ImageBrush ImageSource="/BrushesDemo; component/Budapest.jpg" /><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Button.Background><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Button><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><b><span style="background-color: white; font-family: Helvetica, sans-serif; font-size: 11.5pt; line-height: 107%;">VisualBrush</span></b><b><span lang="GEO/KAT" style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;"><o:p></o:p></span></b></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">ის გამოყენებით შესაძლებელია </span><span style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">WPF </span><span lang="GEO/KAT" style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">ის სხვა ელემენტების გამოყენება, როგორც ფუნჯი. შეგიძლიათ, </span><span style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">WPF</span><span style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;"> <span lang="GEO/KAT">ელემენტს დაუმატოთ </span></span><span style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">Visual </span><span lang="GEO/KAT" style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;">თვისება. ვნახოთ ოთხკუთხედისა და ღილაკის კომბინაცია. <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-ZW7kY3u0y_k/Up7npsIueTI/AAAAAAAABf4/kIYAM7JigNM/s1600/visualBrush.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://2.bp.blogspot.com/-ZW7kY3u0y_k/Up7npsIueTI/AAAAAAAABf4/kIYAM7JigNM/s1600/visualBrush.PNG" width="548" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="background-color: white; font-family: Sylfaen, serif; font-size: 11.5pt; line-height: 107%;"><v:shape id="Picture_x0020_15" o:spid="_x0000_i1027" style="height: 546pt; mso-wrap-style: square; visibility: visible; width: 468pt;" type="#_x0000_t75"> <v:imagedata o:title="visualBrush" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image004.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამის შემდეგ შემიძლია განვიხილო მომენტი, როდესაც საჭიროა </span><span style="font-family: "Sylfaen","serif";">VisualBrush </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს დავუმატო ნებისმიერი </span><span style="font-family: "Sylfaen","serif";">UIElement. განვიხილავ MediaElement</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის დამატებას. ამისთვის საჭირო იქნება, ჩემი მაგალითის გათვალისწინებით </span></span><span style="font-family: "Sylfaen","serif";">solution Explorer</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში შევქმნათ ახალი ფაილი, ან პირდაპირ იქ დავამატოთ მედია ელემენტი, რომელის გამოყენებაც გვინდა. ჩემი </span><span style="font-family: "Sylfaen","serif";">solution Explorer </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ასე გამოიყურება:<o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-P2xBceNWCX4/Up7npUaos3I/AAAAAAAABfs/3XQXBMRx-uU/s1600/solutionexplorer.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="208" src="http://1.bp.blogspot.com/-P2xBceNWCX4/Up7npUaos3I/AAAAAAAABfs/3XQXBMRx-uU/s1600/solutionexplorer.PNG" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-4RtbGcZGo_I/Up7npjQIFOI/AAAAAAAABgA/nA7svqWBhug/s1600/visualbrushwmedia.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://3.bp.blogspot.com/-4RtbGcZGo_I/Up7npjQIFOI/AAAAAAAABgA/nA7svqWBhug/s1600/visualbrushwmedia.PNG" width="592" /></a></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_16" o:spid="_x0000_i1026" style="height: 7in; mso-wrap-style: square; visibility: visible; width: 468pt;" type="#_x0000_t75"> <v:imagedata o:title="visualbrushwmedia" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image005.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">VisualBrush </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის დახმარებით შესაძლებელია ბევრი საინტერესო ეფექტის გაკეთება, მათ შორის არის არეკვლის ეფექტი, რომელსაც შემოგთავაზებთ. <o:p></o:p></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-XPm7hZBHhqU/Up7noxm-_GI/AAAAAAAABfw/yO9zHz7Oahs/s1600/reflectionEffect.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="442" src="http://2.bp.blogspot.com/-XPm7hZBHhqU/Up7noxm-_GI/AAAAAAAABfw/yO9zHz7Oahs/s1600/reflectionEffect.PNG" width="640" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-no-proof: yes;"><v:shape id="Picture_x0020_17" o:spid="_x0000_i1025" style="height: 324pt; mso-wrap-style: square; visibility: visible; width: 467.25pt;" type="#_x0000_t75"> <v:imagedata o:title="reflectionEffect" src="file:///C:\Users\MASTER\AppData\Local\Temp\msohtmlclip1\01\clip_image006.png"></v:imagedata></v:shape></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ღილაკი, რომელიც ნაჩვენებია შეიცავს </span><span style="font-family: "Sylfaen","serif";">StackPanel</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს, რომელიც თავის მხრივ შეიცავს </span><span style="font-family: "Sylfaen","serif";">MediaElement</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს, რომელიც ჩვენთვის ნაცნობია და </span><span style="font-family: "Sylfaen","serif";">Border</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს. </span><span style="font-family: "Sylfaen","serif";">Border შეიცავს</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> </span><span style="font-family: "Sylfaen","serif";">Rectangle, რომელიც ივსება VisualBrush </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ით. ეს ფუნჯი განსაზღვრავს გამჭვირვალობასა და ტრანსფორმაციას. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"> </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ტრანსფორმაცია ხდება </span><span style="font-family: "Sylfaen","serif";">RelativeTransform </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის დახმარებით, რომელიც არის </span><span style="font-family: "Sylfaen","serif";">VisualBrush</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის თვისება და იყენებს ფარდობით კოორდინატებს. </span></span><span style="font-family: "Sylfaen","serif";">scaleY = -1 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ით </span><span style="font-family: "Sylfaen","serif";">Y </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კოორდინატზე კეთდება არეკვლის ეფექტი, ანუ სურათი ტრიალდება, ხოლო </span><span style="font-family: "Sylfaen","serif";">TranslateTransform</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ჩამოაქვს ამოტრიალებული სურათი ქვემოთ, სადაც წესით უნდა იყოს არეკვლა. მონაცემთა კავშირს ავხსნი მოგვიანებით, (</span></span><span style="font-family: "Sylfaen","serif";">Viusal = “{Binding ElementName = reflected}”).</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><span lang="GEO/KAT"><o:p></o:p></span></span><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-33008312449602293812013-12-02T21:26:00.000-08:002014-06-20T07:54:42.335-07:00WPF-3 (ტრანსფორმაცია)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="53" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს ნაწილი დაეთმობა </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში ფიგურების ტრანსფორმაციასა და მისი ძირითადი სახეების განხილვას. იმის გათვალისწინებით, რომ </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ს გააჩნია ვექტორზე დაფუძნებული გრაფიკა შესაძლებელია ყველა ელემენტის ზომის შეცვლა. ვექტორზე დაფუძნებული გრაფიკული ერთეულები ახლა არის გაზომვადი, მობრუნებადი და გადახრადი. მაუსის შეხებისას კი ნებისმიერი კოორდინატის კალკულაციის გარეშე შესაძლებელია რაიმე მოვლენის დარეგისტრირება და შესრულება. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ელემენტის გასადიდებლად საჭიროა უბრალოდ შედეგი </span><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის შესრულება</span><br /><a name='more'></a><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"><br /></span></div><o:p></o:p><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Canvas.LayoutTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><ScaleTransform ScaleX="1.5" ScaleY="1.5" /><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Canvas.LayoutTransform><o:p></o:p></span><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მობრუნებაც ისევე მარტივია, როგორ სკალირება, </span><span style="font-family: "Sylfaen","serif";">RotationTransform </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის გამოყენებით, რომელსაც გააჩნია </span><span style="font-family: "Sylfaen","serif";">Angle </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისება, მისი მნიშვნელობის მინიჭებით ელემენტი ბრუნდება იმ კუთხით, რომელიც მითითებულია ამ თვისებაზე:<o:p></o:p></span><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Canvas.LayoutTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><RotateTransform Angle="30" /><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Canvas.LayoutTransform><o:p></o:p></span><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">გადახრისთვის უნდა გამოიყენოთ </span><span style="font-family: "Sylfaen","serif";">skewTransform </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ელემენტი. გადახრისთვის საჭიროა </span><span style="font-family: "Sylfaen","serif";">X </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Y </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მიმართულებებით კუთხის დანიშვნა. </span><span style="font-family: "Sylfaen","serif";">X, Y </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">განიხილება, როგორც დეკარტის სტანდარტული კოორდინატების სისტემის ღერძები.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Canvas.LayoutTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><SkewTransform AngleX="20" AngleY="25" /><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Canvas.LayoutTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ასე ცალ-ცალკე, რომ არ მოგვიწიოს თითოეული ოპერაციის ჩატარება, შესაძლებელია განვსაზღვროთ </span><span style="font-family: "Sylfaen","serif";">TransformGroup</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, რომლის საშუალებითაც მოხდება </span><span style="font-family: "Sylfaen","serif";">RotateTransform</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ისა და </span></span><span style="font-family: "Sylfaen","serif";">SkewTransform</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ის გამოყენება ერთდროულად ერთიდაიმავე ელემენტზე. <o:p></o:p></span></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">გარდა </span><span style="font-family: "Sylfaen","serif";">TransformGroup </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ისა შეგიძლიათ ისარგებლოთ </span><span style="font-family: "Sylfaen","serif";">MatrixTransform</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ითაც, სადაც </span></span><span style="font-family: "Sylfaen","serif";">Matrix </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ელემენტს გააჩნია თვისებები </span><span style="font-family: "Sylfaen","serif";">M11 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">M22 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">გაწელვისთვის და </span><span style="font-family: "Sylfaen","serif";">M12 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">M21</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">გადახრისთვის. <o:p></o:p></span></span><br /><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><span lang="GEO/KAT"><br /></span></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Canvas.LayoutTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><MatrixTransform><o:p></o:p></span></div><div class="MsoNormal" style="margin-left: 0.5in; text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><MatrixTransform.Matrix><o:p></o:p></span></div><div class="MsoNormal" style="margin-left: 1in; text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><Matrix M11="0.8" M22="1.6" M12="1.3" M21="0.4" /><o:p></o:p></span></div><div class="MsoNormal" style="margin-left: 0.5in; text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></MatrixTransform.Matrix><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify; text-indent: 0.5in;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></MatrixTransform><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></Canvas.LayoutTransform><o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">რა თქმა უნდა კარგი იქნება თუ ამ ყველაფრის დემონსტრაციას მოვახდენთ </span><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">+ ილუსტრაციებით, ამიტომ ქვემოთ მოცემულია ეს ყველაფერი:<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-orErs63Rrkk/Up1rQu7hBJI/AAAAAAAABeU/Uezue2nSnUc/s1600/MatrixTransform.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://3.bp.blogspot.com/-orErs63Rrkk/Up1rQu7hBJI/AAAAAAAABeU/Uezue2nSnUc/s1600/MatrixTransform.PNG" width="571" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-iHzXQkQsNvo/Up1rQrV3toI/AAAAAAAABeQ/Z6uw6WDJ0mo/s1600/RotateTransform.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://3.bp.blogspot.com/-iHzXQkQsNvo/Up1rQrV3toI/AAAAAAAABeQ/Z6uw6WDJ0mo/s1600/RotateTransform.PNG" width="620" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-QoxBGnrOpd4/Up1rRZ1pqtI/AAAAAAAABeo/i4IaMldkYOI/s1600/scaleTransform.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://1.bp.blogspot.com/-QoxBGnrOpd4/Up1rRZ1pqtI/AAAAAAAABeo/i4IaMldkYOI/s1600/scaleTransform.PNG" width="620" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-m-wiXbSQaHI/Up1rQihT90I/AAAAAAAABew/0Pe8JEe9CtI/s1600/SkewTranformY.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://1.bp.blogspot.com/-m-wiXbSQaHI/Up1rQihT90I/AAAAAAAABew/0Pe8JEe9CtI/s1600/SkewTranformY.PNG" width="634" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-piyExKlHIPk/Up1rQ3FgPPI/AAAAAAAABeY/bFTEqmnqeUA/s1600/SkewTransformX.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://2.bp.blogspot.com/-piyExKlHIPk/Up1rQ3FgPPI/AAAAAAAABeY/bFTEqmnqeUA/s1600/SkewTransformX.PNG" width="630" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://1.bp.blogspot.com/-g6otsMhBz5M/Up1rRCriJwI/AAAAAAAABes/R73k8J-19gI/s1600/SkewTransformXY.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://1.bp.blogspot.com/-g6otsMhBz5M/Up1rRCriJwI/AAAAAAAABes/R73k8J-19gI/s1600/SkewTransformXY.PNG" width="636" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"></span><br /></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">იმის გათვალისწინებით, რომ ყველაფერს ქვემოთ მოცემული აქვს შესაბამისი </span><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კოდი, ჩემი აზრით არ არის დამატებითი ახსნა საჭირო, ხოლო რაც შეეხება </span><span style="font-family: "Sylfaen","serif";">SkewTransform</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ს გაკეთებულია ჯერ </span></span><span style="font-family: "Sylfaen","serif";">X </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შემდეგ </span><span style="font-family: "Sylfaen","serif";">Y </span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">და შემდეგ </span></span><span style="font-family: "Sylfaen","serif";">XY </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თვისებების გამოყენებით, რითაც უფრო კარგად დაინახავთ ამ ოპერაციას და მის სიმძლავრეს. <o:p></o:p></span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-2362437873239565862013-12-02T04:05:00.000-08:002014-06-20T07:54:42.377-07:00WPF - 2 (გეომეტრია)<div class="MsoNormal" style="text-align: justify;"><div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="53" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" width="320" /></a></div><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ კლასის შესახებ წინა სექციაშიც ვისაუბრეთ და ის შეიძლება გამოყენებულ იქნას არა მარტო </span><span style="font-family: "Sylfaen","serif";">Path </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ელემენტთან, არამედ </span><span style="font-family: "Sylfaen","serif";">DrawingBrush</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">თანაც კი. </span></span><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">Shape </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ელემენტები საკმაოდ ჰგვანან ერთმანეთს. მაგალითად </span><span style="font-family: "Sylfaen","serif";">Shape </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ებში არის </span><span style="font-family: "Sylfaen","serif";">Line, Ellipse </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Rectangle.</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ხოლო </span></span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში შეგვიძლია ვნახოთ </span><span style="font-family: "Sylfaen","serif";">LineGeometry, EllipseGeometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">RectangleGeometry. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ერთის მხრივ ეს მსგავსება კარგია, მაგრამ არ უნდა იყოს დამაბნეველი,</span><br /><a name='more'></a></div><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">რადგან რაღაც დონის შემდეგ მსგავსება ძალიან დიდ განსხვავებად იქცევა. ძირითადად ფორმები (</span><span style="font-family: "Sylfaen","serif";">Shapes) </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის </span><span style="font-family: "Sylfaen","serif";">FrameworkElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ები, რომლიც თავის მხრივ არის </span><span style="font-family: "Sylfaen","serif";">UIElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მემკვიდრე. ფორმები მონაწილეობენ დიზაინის სისტემაში და მათ შეუძლიათ თავიანთი თავის დარენდერება. ხოლო </span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასს არ შეუძლია თვით დარენდერება და ასევე მათ უფრო ნაკლები თვისებები აქვთ ვიდრე ზომების კლასს. </span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასის წინაპარია </span><span style="font-family: "Sylfaen","serif";">Freezable </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი. <o:p></o:p></span><br /><br /><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">Path </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">კლასი იყენებს </span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის თავისი თავის დასახატად. ასევე </span><span style="font-family: "Sylfaen","serif";">Geometry </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის ობიექტი შეიძლება დაენიშნოს </span><span style="font-family: "Sylfaen","serif";">Path </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">კლასის </span><span style="font-family: "Sylfaen","serif";">Data</span><span style="font-family: "Sylfaen","serif";"> <span lang="GEO/KAT">თვისებას. მარტივი გეომეტრიული ელემენტები, რომლის გამოყენებაც არის შესაძლებელი შეიძლება იყვნენ </span></span><span style="font-family: "Sylfaen","serif";">EllispseGeometry, LineGeometry, RectangleGeometry, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">რომლებიც ენიშნებიან შესაბამისად ელიფსს, ხაზსა და ოთხკუთხედს.<o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">რთული, ანუ რამდენიმე გეომეტრიის შერევის საშუალებას გვაძლევს </span><span style="font-family: "Sylfaen","serif";">CombinedGeomery </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი, რომელსაც გააჩნია თვისება </span><span style="font-family: "Sylfaen","serif";">Geometry1 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Geometry2,</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">რის შემდეგაც ხდება მათი შერევა </span></span><span style="font-family: "Sylfaen","serif";">GeometryCombineMode </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის საშუალებით, რომელიც გაერთიანებაში იღებს რამდენიმე მნიშვნელობას: </span><span style="font-family: "Sylfaen","serif";">Union, Intersect, Xor, Exclude.</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">პირველი თვისება ორ გეომეტრიულ ფიგურას ერთმანეთში სვავს - აერთებს. </span></span><span style="font-family: "Sylfaen","serif";">Intersect </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის საშუალებით შესაძლებელია მხოლოდ იმ ფართობის გამოჩენა, რომელიც ჩანს ორივე გეომეტრიული ფიგურის ფართობის გადაფარვით. </span><span style="font-family: "Sylfaen","serif";">Xor</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">მოქმედებს, როგორც </span></span><span style="font-family: "Sylfaen","serif";">Intersect </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">იმ განსხვავებით, მაგრამ იმ განსხვავებით, რომ ნაჩვენებ ფართობში არ ჩანს ის ნაწილი, სადაც ორივე ფიგურა ერთმანეთზე არის გადადებული. </span><span style="font-family: "Sylfaen","serif";">Exclude </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კი აჩვენებს პირველი ფიგურის ფართობს გამოკლებული მეორე ფიგურის ფართობი, თავისი გადაფარვით. ამ ყველაფრის სადემონსტრაციოდ შემოგთავაზებს </span><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კოდის მიხედვით რეგენერირებულ ფიგურებს.<o:p></o:p></span><br /><span style="font-family: Sylfaen, serif;">Exclude ის გამოყენება</span><br /><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-uYnF05FfMaQ/Upx364b4TsI/AAAAAAAABdk/7CFRAxX6Fi0/s1600/Exclude.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://3.bp.blogspot.com/-uYnF05FfMaQ/Upx364b4TsI/AAAAAAAABdk/7CFRAxX6Fi0/s640/Exclude.PNG" width="606" /></a></div><br />Intersect <span style="font-family: Sylfaen, serif;">ის გამოყენება</span><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-92w74MKE5qQ/Upx36x_z9OI/AAAAAAAABdc/Tql37h94c70/s1600/Intersect.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://2.bp.blogspot.com/-92w74MKE5qQ/Upx36x_z9OI/AAAAAAAABdc/Tql37h94c70/s640/Intersect.PNG" width="600" /></a></div><div class="separator" style="clear: both; text-align: center;">Union <span style="font-family: Sylfaen, serif; text-align: justify;">ის გამოყენება</span></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://3.bp.blogspot.com/-rRYW1jNXyJk/Upx36_yu-6I/AAAAAAAABdY/lVkCZC0HEE0/s1600/Union.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://3.bp.blogspot.com/-rRYW1jNXyJk/Upx36_yu-6I/AAAAAAAABdY/lVkCZC0HEE0/s640/Union.PNG" width="612" /></a></div><div class="separator" style="clear: both; text-align: center;">Xor <span style="font-family: Sylfaen, serif; text-align: justify;">ის გამოყენება</span></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="http://2.bp.blogspot.com/-WmiQJSefZuE/Upx37A9uZ6I/AAAAAAAABdg/wRwyhCHocKI/s1600/Xor.PNG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="640" src="http://2.bp.blogspot.com/-WmiQJSefZuE/Upx37A9uZ6I/AAAAAAAABdg/wRwyhCHocKI/s640/Xor.PNG" width="606" /></a></div><br /></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-16795929660475096302013-11-30T02:52:00.000-08:002014-06-20T07:54:42.392-07:00WPF - 1 (კლასები და სახელსივრცეები)<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="53" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" width="320" /></a></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ ტუტორიალში, შევეცდები ოდნავ მაინც შევეხო და განვიხილო WPF ის ძირითადი სახელსივრცეები და კლასები, რომლები გამოიყენება მთელი ამ ტექნოლოგიის ფუქნციონირებისთვისა და მარტივი და მოხერხებული ტექნიკის გამოენებისთვის.</span></div><a name='more'></a><br /><br /><div class="MsoNormal" style="text-align: justify;"><div class="MsoNormal"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">პირველ რიგში, საჭიროა ერთი გაუგებრობის აღმოფხვრა, რადგან შეიძლება ამან ხელი შეგიშალოთ </span><span style="font-family: "Sylfaen","serif";">Windows Forms და WPF</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის კლასების გარჩევაში. საზოგადოდ, </span><span style="font-family: "Sylfaen","serif";">Windows Forms </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის კლასები მოთავსებულია </span><span style="font-family: "Sylfaen","serif";">System.Windows.Forms </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცეში, როცა </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის კლასები მოთავსებულები</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";"></span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არიან </span><span style="font-family: "Sylfaen","serif";">System.Windows </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცეში. მაგალითისთვის რომ ავიღოთ </span><span style="font-family: "Sylfaen","serif";">TextBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი, ის მოთავსებულია </span><span style="font-family: "Sylfaen","serif";">Windows Forms </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ებისათვის </span><span style="font-family: "Sylfaen","serif";">System.Windows.Forms.TextBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცეში, ხოლო </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ისთვის მოთავსებულია </span><span style="font-family: "Sylfaen","serif";">System.Windows.Controls.TextBox </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ში. ქვემოთ მოცემულია </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ძირითადი სახელსივრცეები და მათი დანიშნულება<o:p></o:p></span></div><div class="MsoNormal"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Grid2Accent1" style="border-collapse: collapse; border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows<o:p></o:p></span></b></div></td> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს არის </span></b><b><span style="font-family: "Sylfaen","serif";">WPF </span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ძირითადი სახელსივრცე. აქ შეიძლება ისეთი კლასების პოვნა, როგორიცაა </span></b><b><span style="font-family: "Sylfaen","serif";">Applocation, DependancyObject, DependencyProperty და </span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ყველა </span></b><b><span style="font-family: "Sylfaen","serif";">WPF </span></b><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ელემენტის საბაზისო კლასი </span></b><b><span style="font-family: "Sylfaen","serif";">FrameworkElement.<o:p></o:p></span></b></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Annotations<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს კლასი არის მხოლოდ მომხმარებლის მიერ შექმნილი ანოტაციებისთვისა და ჩანაწერებისათვის აპლიკაციის მონაცემებზე, რომელიც მოთავსებულია განცალკევებით დოკუმენტში. </span><span style="font-family: "Sylfaen","serif";">System.Windows.Annotations.Storage </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასი კი შეიცავს კლასებს ანოტაციების მოსათავსებლად.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Automation<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცე, რომლის დახმარებითაც ხდება </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">აპლიკაციის ავტომატიზაცია. ეს სახელსივრცე თავის მხრივ შეიცავს </span><span style="font-family: "Sylfaen","serif";">System.Windows.Automation.Peers </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცეს, რომელიც </span><span style="font-family: "Sylfaen","serif";">WPF ელემენტების ავტომატიზაციისთვის გამოიყენება</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">, ხოლო თუ საჭირო გახდა მომხმარებლის მიერ ავტომატიზაციის შექმნა, მაშინ შეგიძლიათ გამოიყენოთ </span><span style="font-family: "Sylfaen","serif";">System.Windows.Automation.Provider </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცე.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Baml2006<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ეს სახელსივრცე ახალია </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ისთვის და შემოსულია </span><span style="font-family: "Sylfaen","serif";">.NET 4 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თან ერთად და შეიცავს </span><span style="font-family: "Sylfaen","serif";">Baml2006Reader</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">კლასს, რომელიც გამოიყენება ორობით მონიშვნის წასაკითხად, ხოლო თვითონ ქმნის </span></span><span style="font-family: "Sylfaen","serif";">XAML ს.</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Controls<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ამ სახელსივრცეში შესაძლებელია ყველა </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კონტროლის პოვნა. ხოლო ქვე სახელსივრცეში </span><span style="font-family: "Sylfaen","serif";">System.Windows.Controls.Primitives </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შესაძლებელია იმ კლასების პოვნა, რომელიც გამოიყენება კომპლექსური კონტროლების შექმნისთვის.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Converters<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">აქ მოთავსებულ კლასებს შეუძლიათ მონაცემთა კონვერტირება. მაგრამ ყველა კონვერტორი არ არის ამ სახელსივრცეში. საბაზისო კონვერტორები არის </span><span style="font-family: "Sylfaen","serif";">System.Windows </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცეში. <o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Data<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სახელსივრცე, რომელიც გამოიყენება მონაცემთა გადაბმისათვის. უმნიშვნელოვანესი კლასია </span><span style="font-family: "Sylfaen","serif";">Binding, </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">რომელიც შესაბამისობას ამყარებს </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სამიზნე ელემენტსა და </span><span style="font-family: "Sylfaen","serif";">CLR </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">წყაროს შორის. <o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Documents<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">დოკუმენტებთან მუშაობისას ამ სახელსივრცეში შესაძლებელია გამოსადეგი კლასების გამოყენება. </span><span style="font-family: "Sylfaen","serif";">System.Windows.Documents.Serializtion </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">კლასის გამოყენებით შესაძლებელია დოკუმენტების დისკზე ჩაწერაც.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Ink<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">თანამედროვე მოწყობილობების გათვალისწინებით, ტაბლეტები და სმარტფონები საკმაოდ გამოყენებადია. ამ სახელსივრცის გამოყენებით ხდება მომხმარებლის მოძრაობების ინიციალიზება. <o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Input<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შედის კლასები ბრძანებების მოგვარებისთვის, კლავიატურიდან ინფორმაციის აღსაქმელად, სტილუსთან სამუშაოდ და ასე შემდეგ.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Interop<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">Win32 </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ისა და </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ინტეგრაციისთვის შესაძლებელია კლასების გამოყენება.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Markup<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">XAML </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მონიშვნის კოდის დამხმარე კლასები<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Media<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მოთავსებულია კლასები ვიდეო, აუდიო და სურათებთან სამუშაოდ.<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Navigation<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ფანჯრებს შორის სანავიგაციოთ განკუთვნილი კლასების სახლესივრცე</span><span style="font-family: "Sylfaen","serif";">.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Resources<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">რესურსებთან სამუშაო კლასები<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(222, 234, 246); border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Shapes<o:p></o:p></span></b></div></td> <td style="background: rgb(222, 234, 246); border: currentColor; mso-background-themecolor: accent1; mso-background-themetint: 51; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მომხმარებლის ინტერფეისთან მომუშავე ძირითადი კლასების „სათასო“<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(156, 194, 229) rgb(156, 194, 229) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #9CC2E5 .25pt; mso-border-right-themecolor: accent1; mso-border-right-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 150.45pt;" valign="top" width="201"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">System.Windows.Shapes<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #9CC2E5 .25pt; mso-border-bottom-themecolor: accent1; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #9CC2E5 .25pt; mso-border-left-themecolor: accent1; mso-border-left-themetint: 153; mso-border-top-alt: solid #9CC2E5 .25pt; mso-border-top-themecolor: accent1; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 317.05pt;" valign="top" width="423"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის ელემენტები იყენებენ ერთ ნაკადს. ამ სახელსივრცის გამოყენებით შესაძლებელია ელემენტებმა გამოიყენონ რამდენიმე ნაკადი ერთდროულად.<o:p></o:p></span></div></td> </tr></tbody></table><div class="MsoNormal"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <o:p></o:p></span></div><div class="MsoNormal"><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">შეიცავს ათასობით კლასს ღრმა იერარქიით. ქვემოთ მოცემულია მცირეოდენის ცხრილური განხილვა.<o:p></o:p></span></div><div class="MsoNormal"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><br /></span></div><table border="1" cellpadding="0" cellspacing="0" class="MsoTable15Grid2Accent6" style="border-collapse: collapse; border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184;"> <tbody><tr> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">DispatcherObject<o:p></o:p></span></b></div></td> <td style="background: white; border: currentColor; mso-background-themecolor: background1; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის საბაზისო აბსტრაქტული კლასი იმ კლასებისთვის, რომელიც იყენებენ ერთ ნაკადს. <o:p></o:p></span></b></div></td> </tr><tr> <td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Application<o:p></o:p></span></b></div></td> <td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">აპლიკაციის შექმნისას ავტომატურად იქმნება ამ კლასის ობიექტი, რომელის გავლითაც შესაძლებელია აპლიკაციის ფანჯრებზე, რესურსებზე და თვისებებზე წვდომა. <o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">DependencyObject<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის საბაზო კლასი ყველა იმ კლასისთვის, რომელსაც შეუძლია დამოკიდებულების თვისების გამოყენება</span><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Visual<o:p></o:p></span></b></div></td> <td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ვიზუალური ელემენტების საბაზო კლასი. კლასს შეუძლია ასევე ტრანსფორმირება და ტესტირება<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">UIElement<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">საბაზო კლასი იმ ელემენტებისთვის, რომლებსაც სჭირდებათ საბაზისო პრეზენტაციის შესაძლებლობა. ეს კლასი გამარაგებთ </span><span style="font-family: "Sylfaen","serif";">Tunneling </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">და </span><span style="font-family: "Sylfaen","serif";">Bubbling </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მოვლენებით მაუსის მოძრაობისთვის. <o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">FrameworkElement<o:p></o:p></span></b></div></td> <td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის </span><span style="font-family: "Sylfaen","serif";">UIElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მემკვიდრე, რომელიც იმპლემენტაციას უკეთებს წინაპარი კლასის მეთოდებს<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Shape<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის საბაზო კლასი ფორმის ელემენტებისათვის, როგორებიცაა </span><span style="font-family: "Sylfaen","serif";">Line, Ellipse, Polygon, Rectangle</span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"><o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">Control</span></b><b><span style="font-family: "Sylfaen","serif";"><o:p></o:p></span></b></div></td> <td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მემკვიდრეა </span><span style="font-family: "Sylfaen","serif";">FrameworkElement </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის მემკვიდრე, ხოლო თვითონ არის საბაზო კლასი ყველა მომხმარებელთან იტერაქტიული ელემენტისა.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ContentControl<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის წინაპარი კლასი, რომელიც შეიცავს ერთ კონტენტს -</span><span style="font-family: "Sylfaen","serif";"> Label, Button. </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">სტანდარტული სტილი ლიმიტირებულია, ხოლო ფუნქციონალურობის გაზრდა შესაძლებელია </span><span style="font-family: "Sylfaen","serif";">Template </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">ის გამოყენებით<o:p></o:p></span></div></td> </tr><tr> <td style="background: rgb(226, 239, 217); border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">ItemControl<o:p></o:p></span></b></div></td> <td style="background: rgb(226, 239, 217); border: currentColor; mso-background-themecolor: accent6; mso-background-themetint: 51; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">არის საბაზისო კლასი ყველა იმ კლასისა, რომელიც შეიცავს წევრების კოლექციას.<o:p></o:p></span></div></td> </tr><tr> <td style="border-color: currentColor rgb(168, 208, 141) rgb(168, 208, 141) currentColor; border-style: none solid solid none; border-width: medium 1pt 1pt medium; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-right-alt: solid #A8D08D .25pt; mso-border-right-themecolor: accent6; mso-border-right-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 103.25pt;" valign="top" width="138"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><b><span style="font-family: "Sylfaen","serif";">Panel<o:p></o:p></span></b></div></td> <td style="border: currentColor; mso-border-bottom-alt: solid #A8D08D .25pt; mso-border-bottom-themecolor: accent6; mso-border-bottom-themetint: 153; mso-border-left-alt: solid #A8D08D .25pt; mso-border-left-themecolor: accent6; mso-border-left-themetint: 153; mso-border-top-alt: solid #A8D08D .25pt; mso-border-top-themecolor: accent6; mso-border-top-themetint: 153; padding: 0in 5.4pt; width: 364.25pt;" valign="top" width="486"><div class="MsoNormal" style="margin-bottom: 0pt; text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";">მემკვიდრეა</span><span style="font-family: "Sylfaen","serif";"> FrameworUIElement</span><span style="font-family: "Sylfaen","serif"; mso-ansi-language: "GEO/KAT";"> <span lang="GEO/KAT">ისა და არის აბსტრაქტული საბაზო კლასი ყველა პანელისთვის. <o:p></o:p></span></span></div></td> </tr></tbody></table><br /><div class="MsoNormal"><br /></div></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-9268083853162962922013-11-29T11:11:00.000-08:002014-06-20T07:54:42.434-07:00WPF - 0 შესავალი<div class="separator" style="clear: both; text-align: center;"><a href="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://upload.wikimedia.org/wikipedia/commons/8/8e/WPF_Logo_2.png" height="53" width="320" /></a></div><br /><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">Windows Presentation Foundation </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">არის ბიბლიოთეკა, რომლის საშუალებებითაც შესაძლებელია ჭკვიანი აპლიკაციის ინტერფეისის შექმნა. ვაპირებ, რომ დავფარო ძირითადი კონცეპტები და უკეთ წარმოვაჩინო </span><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ის შესაძლებლობები.</span></div><a name='more'></a><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ეს პოსტი იქნება უბრალოდ მისი მიმოხილვა. ამ ტუტორიალის საშუალებით შესაძლებლობა გექნებათ ნახოთ სხვადასხვა კონტროლი და მათი კატეგორიები, ასევე მათი მოთავსება პანელებში, ვიზუალური მხარის დამუშავება სტილების, რესურსებისა და </span><span style="font-family: "Sylfaen","serif";">template </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">ების გამოყენებით. ასევე, ტრიგერები და მათი დინამიური ქცევა. ანიმაციები და ცოტაოდენი </span><span style="font-family: "Sylfaen","serif";">3D.<o:p></o:p></span><br /><br /><div class="MsoNormal" style="text-align: justify;"><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">პირველ რიგში უნდა გაიგოთ, რომ ეს ტექნოლოგია იყოფა ორ ნაწილად: დიზაინერისა და დეველოპერის მხარეთ, რაც უფრო კონკრეტულად იმას ნიშნავს, რომ დიზაინერის მხარე პირდაპირ ხვდება დეველოპერის ხელში და აქედან იწყება არც თუ ისე მარტივი სამუშაო. ასევე კარგად უნდა იცოდეთ რა არის </span><span style="font-family: "Sylfaen","serif";">eXtensible Application Markup Language.<o:p></o:p></span></div><br /><div class="MsoNormal" style="text-align: justify;"><span style="font-family: "Sylfaen","serif";">WPF </span><span lang="GEO/KAT" style="font-family: "Sylfaen","serif";">შეიცავს რამდენიმე ჯგუფს, რომლებიც თავის მხრივ შეიცავენ ათასობით კლასს. ვფიქრობ, კარგი იქნება თუ მოკლე მიმოხილვას გავაკეთებ ამ სახელ სივრცეებისთვის და მათში შემავალი კლასებისთვის.<o:p></o:p></span></div><div class="MsoNormal" style="text-align: justify;"><br /></div><div class="MsoNormal" style="text-align: justify;"><span style="font-family: Sylfaen, serif;">გიორგი ჯამბაზიშვილი.</span></div>Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0tag:blogger.com,1999:blog-3203290427045998152.post-47355946470524901962013-11-19T00:27:00.000-08:002014-06-20T07:54:42.442-07:00კონტაქტი <div class="separator" style="clear: both; text-align: center;"><a href="https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcR_eVhFcEioGGpRm577G6v3K4qbHEkCats2fZqNHSi-b2Brqv-YCQ" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcR_eVhFcEioGGpRm577G6v3K4qbHEkCats2fZqNHSi-b2Brqv-YCQ" /></a></div>მოგესალმებით და გადნობებთ, რომ ნებისმიერ თემაზე შეგიძლიათ მომწეროთ. შეგიძლიათ დამისვათ შეკითხვა ბლოგზე განთავსებული კონტექსტის შესახებ ან იმის შესახებ, რაც გაინტერესებთ და რაც თემატურად კავშირშია ბლოგზე განთავსებულ ინფორმაციასთან. <br /><br />ჩემი მეილია - <a href="mailto:Giorgi.Jambazishvili@gmail.com">Giorgi.Jambazishvili@gmail.com</a><br />ან შეგიძლიათ სცადოთ - <a href="mailto:BV_SOG@live.com">BV_SOG@live.com</a><br /><br />დიდი მადლობა ყურადღებისათვის!<br /><br />Jambazishvilihttp://www.blogger.com/profile/18313944956706696794noreply@blogger.com0