Feed on
Subscription

.Net edge learns an edge to tell (one)

Through the use of period of time,Those who become aware the ABC of oneself are right.net masters is not quite enough,A lot of friends also have the possibility this kind of feeling,Undertook adjust and be changinged in a lot of respects plus Beta2,Accordingly I want to make development with Beta1 now is to suit not quite,Discuss a few ABC, principle together as everybody,These things are won't change,And mastered these,Process designing is met after more handy.The character of the sex of a few similar conclusion that falls here,Do not be opposite certainly,Individual feeling increases the experience that reads a few articles,Hope everybody can be discussed together.
1. type (Type) :
The main unit that the type is.Net.The Classes in.Net, interfaces, enumerations, structures is a type,The most type in.net is kind,Although you write an again simple program,be in in.net (be like:Hello World) also need kind,With Winform for,Main function needs kind,He is this kind member function.So kind what be after all?A definition gave on Dr.Net:He is a stencil that founds the boy or girl friend that includes data and the method that handle these data.Awkward-sounding having a place,Say simply,He is a stencil,Data and the method that handle these data were enclosed in this stencil.Such,You founded kind established a new data type, definition the term that handles these data.The abstraction that the type is a few concepts.Between a good OO design,The type is by a series of operate a definition,is not immanent data format decision.And we should state data commonly demesne,The other share that avoided a program so destroys this to enclose.E.g. ,We found kind
Public Class Auto{
Private Double Speed;
Public Double Speed{
Get{
Return(speed);
}
Set{
Speed = Value;
}
}
}
With this kind for exemple,The viewpoint of my expatiation above,Kind Auto can regard as a new data type,You can state other members are type of this kind of data: PUblic Auto Car(){} ,Such,What Car returns is an Auto type.This is distinguished with it doesn't matter of Public Int Car(){} ,In the Int in.net, string. . . When waiting kind is the " of " data type in other programming language not just, actually the Int in C# is the Int32 in.Net Runtime kind alias.Deeper the component that if want to do to cross a language,one situation says you,The standard that all types that you state must be.Net Runtime kind,Replace String with String that is to say,Int32 replaces Int to wait.So to enclosing,How do we understand?The abstraction that e.g. Single and Double they represent actual number is enclosed.So data format?We often do not need to know,Also do not want to know.Single and Double have certain limits and precision,Because they are abstract,is not actual number.You can realize a few operations to them,Include to add decrease by except.But cannot have an operation however,Because these operations are not to enclose the part inside,this is,The one part that so they also are not types.Kind it is stencil,But how can we just get real target? Auto D= New Auto(); such we understood,Why we are being used kind before,Why to want example to change.

Related:

    Submit: