.NET
  Home arrow .NET arrow Page 3 - Understanding the .NET Framework
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
.NET

Understanding the .NET Framework
By: McGraw-Hill/Osborne
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 28
    2004-05-19

    Table of Contents:
  • Understanding the .NET Framework
  • The .NET Architecture
  • The Common Type System
  • The .NET Framework Class Library
  • Assemblies
  • Assembly Manifest
  • Global Assembly Cache
  • Signing an Assembly

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Understanding the .NET Framework - The Common Type System


    (Page 3 of 8 )

    The CTS implements the formal specifications for the type system used by the .NET Framework. All data types represented by the CTS are objects. The CTS defines how a type is defined and the operators that it can accept. One of the primary goals of the CTS is to enable deep language integration by allowing code that's written in one language to be inherited and used by another language. Sharing a common system of data types is one of the most fundamental building blocks that enable this to happen.

    Classes of Types

    The .NET Framework supports two basic classes of types: value types and reference types. The following section describes these types in more detail.

    Value Types - Value types are very similar to the built-in data types provided by most programming languages. Typical data types that are used to store variable values include characters, integers, strings, and floating-point numbers. In the .NET Framework, they are termed value types because they are copied when they are passed as arguments. In other words, they are passed by value. The .NET Framework stores value types on the stack. Table 2-4 lists the value type supported by the .NET Framework along with their VB.NET and C# data type keywords. 

    Type

    Description

    VB.NET

    C#

    Boolean

    A Boolean value (true or false)

    Boolean

    bool

    Byte

    An 8-bit unsigned integer

    Byte

    byte

    Char

    A Unicode (16-bit) character

    Char

    char

    Decimal

    A 96-bit decimal value

    Decimal

    decimal

    Double

    A double-precision (64-bit) floating-point number

    Double

    double

    Int16

    A 16-bit signed integer

    Short

    short

    Int32

    A 32-bit signed integer

    Integer

    int

    Int64

    A 64-bit signed integer

    Long

    long

    IntPtr

    A signed integer whose size depends on the underlying platform

    IntPtr

    IntPtr

    Object

    The root of the object hierarchy

    Object

    object

    SByte

    An 8-bit signed integer

    SByte

    sbyte

    Single

    A single-precision (32-bit) floating-point number

    Single

    float

    String

    An immutable, fixed-length string of Unicode characters

    String

    string

    UInt16

    A 16-bit unsigned integer

    UInt16

    ushort

    UInt32

    A 32-bit unsigned integer

    UInt32

    uint

    UInt64

    A 64-bit unsigned integer

    UInt64

    ulong

    UIntPtr

    An unsigned integer whose size depends on the underlying platform

    UIntPtr

    UIntPtr

    Table 2-4. CTS Value Types

    Reference Types - Reference types store a reference to the value's memory address, and are allocated on the heap. Reference types can be self-describing types, pointer types, or interface types. Unlike value types, reference types are passed between procedures using the address. In other words, a reference to the original object is passed rather than a copy of that object, as is the case with value types.

    Type

    Description

    VB.NET

    C#

    Classes

    A class is a data structure that may contain data members (constants, variables, and events), function members (methods, properties, indexers, operators, and constructors), and nested types.

    Class

    class

    Delegates

    A delegate is a reference type that refers to a shared method of a type or to an instance method of an object.

    Delegate

    delegate

    Arrays

    An array is a data structure that contains a number of variables (elements of the array).

    Dim MyArray(5) As Integer

    int[] myArray=

    Interfaces

    Interfaces are implemented by other types to guarantee that they support certain operations. An interface defines a contract. A class or structure that implements an interface must adhere to that contract.

    Interface

    interface

    Pointers

    Pointers reference blocks of memory. There are three kinds of pointers supported by the runtime: managed pointers, unmanaged pointers, and unmanaged function pointers.

    N/A

    int*

    Table 2-5. CTS Reference Types

    This is chapter two of ADO.NET: The Complete Reference, by Michael and Denielle Otey (McGraw-Hill/Osborne, ISBN 0-07-222898-9, 2003). Check it out at your favorite bookstore today. Buy this book now.

    More .NET Articles
    More By McGraw-Hill/Osborne


     

    .NET ARTICLES

    - The Transformed XML Explorer in MFC
    - List Control and Property Grid with the MFC ...
    - Font, Shell and Masked Edit Controls for MFC
    - Color, Link and Image Editor Controls for M...
    - New Controls for MFC
    - The Windows Ribbon Framework
    - Markup Language for the Ribbon Framework
    - Visually Upgrade Your MFC Project
    - New Features for the Statusbar in MFC
    - Working with the Statusbar in MFC
    - Iron Speed Design v60 Review
    - Binary and XML Serialization
    - Using CrystalReportViewer to Display Crystal...
    - Creating Summary .Net Crystal Reports
    - More on Commands, Input and the WPF





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 5 Hosted by Hostway
    Stay green...Green IT