-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: SitaramanM
Message 4 in Discussion

Hi Anand    From your answer Although all .NET Complaint languages will genetrate the 
IL there will be some difference in the coding (IL). so can we say there will be some 
performance issues also?   Yep!!!  When the code gets compiled to IL, there are a lot 
of changes that are done.   In fact one more intersweting thing that happens when Code 
is  compiled to IL is the snippet that the compiler places to handle VB.Net Static(NOT 
Shared) variables.   You can lookup one of the previous posts in BDotNot related to 
this.  Really cool stuff   IMHO, Im dont think there will be any performance Issue.  
but programming in IL gives you certain features which VB.Net or C# doesnt gibve.  For 
e.g.   a) You can have protected and Assembly(internal in  C#) qualifiers.  Right!!! 
Assembly means that only those classes that are in the same assembly as of the 
Declaring type cann access the member.  Protected means that only those classes wghich 
derive from he declaring type of the variable can access the member.  Ok  Now what if 
i want a mechanism, where only those types, which are a) in the same assembly + b) 
deriving from the declaring type to access the member.   VB.Net and C# do not offer 
this mechanism.  IL does it by using a Family&Assembly keyword   In IL,  You can have 
two methods which differ in only return types  in a same class.  This is not the case 
in Vb.Net or C#(or in any other language that i know of)  where for method overloading 
the signatures need to be different and signature is basically, the type of params, 
order of params, and number of params.  In these languages return type is not part of 
the signature,  In IL it is not.    So IL offers a lot , i guess,  who want to explore 
it!!         What is the difference between dll created by extending the IComponent 
and Without Extending the same. You are basically looking for a component created 
implementing the IComponent and one that doesnt.  Right!!!!   Am not very good at UI 
components.  But did some basic R&D and this is my observation.   IComponent is 
typically used when you want a component that will be contained in a container.      
IComponent holds a Event called Disposed and a property of type ISite        Public 
Interface IComponent Inherits IDisposable      Public Event Disposed As EventHandler
Public Property Site() As ISite
     Get
End Get
Set(ByVal value As ISite)
End Set
End Property
End Interface
 ISite in turn  is as follows     Public Interface ISite Inherits IServiceProvider     
 Public Property Component() As IComponent
     Get
End Get
End Property
Public Property Container() As IContainer
     Get
End Get
End Property
Public Property DesignMode() As Boolean
     Get
End Get
End Property
Public Property Name() As String
     Get
End Get
Set(ByVal value As String)
End Set
End Property
End Interface 
Here if you note ISite has properties like Container and DesignMode.  So i think when 
you create components like a button,  which will be placed in a container like a 
windows forms and will allow you to modify its properties at designtime, then you need 
to implement the IComponent interface.  This is only based on my inference.  hope this 
helps.  Also will appreciate comments, if any, from the group         Why C# is called 
as Component Based Language Not sure whether this was in context to any specific 
feature.  But the term Component Based Language is quite generic.   You have 
applications which are monolithic,  that is one entity itaself containing the UI, 
Business and Data Processing Logic.  Later the industry moved onto a tier based 
development,  where instead of designing an application as a whole,  we develop 
individual components  which have a cleard, precise and specific functionailty that 
they cater to and these components together form an application.  Such components are 
basically called as the building blocks of an application and are analogous to the 
Lego blocks that children play with( you have a number of blocks with which you can 
consgtruct a building or a vehicle or a bridge etc...).  Advantage of such a design is 
that these components are higly pluggable in nature and a change in one component can 
be handled without modifying the app as a whole.  That said,  C# definitely is a 
Component Based Language  withing the above-said parameters,  as is VB.Net( and VB 
since v4.0, for that matter)      hth   regards,   sr regards,   sr

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to