Search:
Namespaces
Discussions
.NET v1.1
Feedback
the meaning of 100% manged code
Messages
Related Types
This message was discovered on
ASPFriends.com 'aspngcontrolscs' list
.
Lasse Johansen
-- Copied from [winforms-vb] to [aspngcontrolscs] by Bob Levittan <
Click here to reveal e-mail address
> --
I have been looking for a control that can zip/unzip files and stumbled into
this strange sentence:
This control is written entirely in .NET. This is 100% managed code.
Several other controls that actually makes the same functionality, do not
claim to be such a control. What does this mean exactly. The more I look
into examples I see people using imported API calls (in VB.NET/C#). If you
do that, will it still be 100% managed code, or did it lost its title. What
if I use a COM component (I guess it will loose its title)? And.. and...
what criteria's is there for the control to be a "written entirely in .NET".
Thanks in advance for any clarification
Lasse Johansen
Reply to this message...
Andy Smith
the idea there is that "100% managed code" only uses the Framework Class =
Library ( FCL ), and doesn't talk to the Win32 API or COM.
one side-effect is that code that does use Win32 or COM has to have =
higher security clearance because the CLR can't make sure the code =
doesn't do anything evil.
another is that 100% managed code has the opportunity to be =
cross-platform compatible when a complete implementation is on another =
platform.
__
Andy Smith
Keyboard Jockey #3a7-2.78.1
[Original message clipped]
Reply to this message...
Ryan Trudelle-Schwarz
Which is funny because much of the Framework Class Library is interop
itself...
-> -----Original Message-----
-> From: Andy Smith [mailto:
Click here to reveal e-mail address
]
->
-> the idea there is that "100% managed code" only uses the Framework
Class
-> Library ( FCL ), and doesn't talk to the Win32 API or COM.
->
-> one side-effect is that code that does use Win32 or COM has to have
-> higher security clearance because the CLR can't make sure the code
-> doesn't do anything evil.
->
-> another is that 100% managed code has the opportunity to be cross-
-> platform compatible when a complete implementation is on another
-> platform.
-> __
-> Andy Smith
-> Keyboard Jockey #3a7-2.78.1
->
-> > -----Original Message-----
-> > From: Lasse Johansen [mailto:
Click here to reveal e-mail address
]
-> >
-> > I have been looking for a control that can zip/unzip files
-> > and stumbled into
-> > this strange sentence:
-> >
-> > This control is written entirely in .NET. This is 100% managed
code.
-> >
-> > Several other controls that actually makes the same
-> > functionality, do not
-> > claim to be such a control. What does this mean exactly. The
-> > more I look
-> > into examples I see people using imported API calls (in
-> > VB.NET/C#). If you
-> > do that, will it still be 100% managed code, or did it lost
-> > its title. What
-> > if I use a COM component (I guess it will loose its title)?
-> > And.. and...
-> > what criteria's is there for the control to be a "written
-> > entirely in .NET".
-> >
-> > Thanks in advance for any clarification
-> >
-> > Lasse Johansen
---
[This E-mail scanned for viruses by Declude Virus]
Reply to this message...
Andy Smith
yes, but the difference is that Microsoft has signed the code in the =
FCL.
an "untrusted" ( in the "clr security" sense ) source trying to execute =
code thru the clr into unmanaged code would defeat the security =
restrictions in place.
__
Andy Smith
Keyboard Jockey #3a7-2.78.1
[Original message clipped]
Reply to this message...
Lasse Johansen
Hi andy
So how can you make a RS232 class that is 100%
managed(
http://www.codeproject.com/managedcpp/howtocomport.asp
)? You have to
call non FCL functions to do that...
And finally.. how do you know/test whether your code is managed code or not?
Lasse Johansen
----- Original Message -----
From: "Andy Smith" <
Click here to reveal e-mail address
>
To: "aspngcontrolscs" <
Click here to reveal e-mail address
>
Sent: Wednesday, June 26, 2002 10:49 AM
Subject: [aspngcontrolscs] RE: the meaning of 100% manged code
the idea there is that "100% managed code" only uses the Framework Class
Library ( FCL ), and doesn't talk to the Win32 API or COM.
one side-effect is that code that does use Win32 or COM has to have higher
security clearance because the CLR can't make sure the code doesn't do
anything evil.
another is that 100% managed code has the opportunity to be cross-platform
compatible when a complete implementation is on another platform.
__
Andy Smith
Keyboard Jockey #3a7-2.78.1
[Original message clipped]
| [aspngcontrolscs] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.asplists.com/asplists/aspngcontrolscs.asp
= JOIN/QUIT
|
http://www.asplists.com/search
= SEARCH Archives
Reply to this message...
Alex Lowe
Lasse,
I think the issue here is the definition of "managed code".
What is "managed code"? Managed code is any code created by a compiler
that targets the Common Language Runtime (CLR). The language compiler
emits code that contains metadata. The metadata describes the code
(types, etc.). The CLR (also referred to as a Common Execution
Environment) then makes use of the metadata to execute the code and
perform various other services like memory management, generating native
code, providing an exception engine, and enforcing certain security
mechanisms.
So, for a class to be 100% managed code, every line of the code must
target the CLR. If you poke out of the CLR and use the Win32 API or a
COM based API then that code is not targetting the CLR and therefore it
cannot be 100% managed code according to the definition above.
I don't want to go on and on because this list is for building controls
but it is important to understand these concepts. The last thing I will
say is that there are going to be circumstanaces where building a class
or component with 100% managed code is not possible (based on some
requirement). The Framework Class Library does not, and wasn't really
intended to, replace the entire Win32 API or the various other COM based
APIs floating around. Does it cover a heck of a lot of functionality?
Yes. Does it cover everything? No. Look for new classes in future
versions to start to fill in the holes hopefully.
Further discussion should probably be moved to a framework list of some
kind.
Hth,
Alex - AspFriends.com Moderation Team
Microsoft MVP - ASP.NET
***********************************************************
Translate C# code to VB.NET code at
http://aspalliance.com/aldotnet/examples/translate.aspx
***********************************************************
[Original message clipped]
Reply to this message...
Paul D. Murphy
This discussion does not belong on the control list. Please talk about
the CLR and CLR issues on the CLR lists.
For the .NET implementation of the CLR
http://www.aspfriends.com/aspfriends/cli-implementations-dotnet.asp
For the ROTOR implementation of the CLR
http://www.aspfriends.com/aspng/cli-implementations-sscli.asp
Paul
Paul D. Murphy
Click here to reveal e-mail address
"Teamwork is a lot of people doing what I say."
-----Original Message-----
From: Alex Lowe [mailto:
Click here to reveal e-mail address
]=20
Sent: Wednesday, June 26, 2002 9:26 PM
To: aspngcontrolscs
Subject: [aspngcontrolscs] RE: the meaning of 100% manged code
Lasse,
I think the issue here is the definition of "managed code".
What is "managed code"? Managed code is any code created by a compiler
that targets the Common Language Runtime (CLR). The language compiler
emits code that contains metadata. The metadata describes the code
(types, etc.). The CLR (also referred to as a Common Execution
Environment) then makes use of the metadata to execute the code and
perform various other services like memory management, generating native
code, providing an exception engine, and enforcing certain security
mechanisms.
So, for a class to be 100% managed code, every line of the code must
target the CLR. If you poke out of the CLR and use the Win32 API or a
COM based API then that code is not targetting the CLR and therefore it
cannot be 100% managed code according to the definition above.=20
I don't want to go on and on because this list is for building controls
but it is important to understand these concepts. The last thing I will
say is that there are going to be circumstanaces where building a class
or component with 100% managed code is not possible (based on some
requirement). The Framework Class Library does not, and wasn't really
intended to, replace the entire Win32 API or the various other COM based
APIs floating around. Does it cover a heck of a lot of functionality?
Yes. Does it cover everything? No. Look for new classes in future
versions to start to fill in the holes hopefully.
Further discussion should probably be moved to a framework list of some
kind.
Hth,
Alex - AspFriends.com Moderation Team
Microsoft MVP - ASP.NET
***********************************************************
Translate C# code to VB.NET code at
http://aspalliance.com/aldotnet/examples/translate.aspx
***********************************************************
[Original message clipped]
| [aspngcontrolscs] member
Click here to reveal e-mail address
=3D YOUR ID
|
http://www.asplists.com/asplists/aspngcontrolscs.asp
=3D JOIN/QUIT
|
http://www.asplists.com/search
=3D SEARCH Archives
Reply to this message...
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us
-
Terms of Use
-
Privacy Policy
-
www.dotnet247.com