Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what are generics? Without generics what are the
disadvantages in 1.1?

Answer Posted / lakshmi

They are tad similar to C++ templates. With .net 1.0,
creating a flexible class or method that should use classes
that are known at compile time must be based on the object
class. With the object class, theres no type safety during
compile time. casting is necessary. Also, using the object
class for value types has a performance impact. .Net 2.0
supports generics, with generics the object class is no
longer necessary in such scenarios. Generic classes make
use of generic types that are replaced with specific types
as needed. This allows for typesafety. The
system.collections.Generic namespace gives you access to
generic versions of the stack, dictionary,
sorted dictionary, list and queue classes.
Advantages: Binary code reuse, performance, easy of
reading, typesafety.

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain unit test done by tester on development team?

994


What is basic authentication in web api?

1049


What is managed extensibility framework?

995


Where are the routing rules defined in an asp.net mvc application?

1058


i just want to write an exam regarding .net?plz give me information about taking a test?where to pay 4 d exam,exam centre?

2222


Explain JSON Binding?

1067


Is dapper better than entity framework?

971


Explain linq to entities? : Entity framework

1028


What is entity framework used for?

1044


What is the difference between viewbag and viewdata in mvc?

962


Can you explain renderbody and renderpage in mvc?

1021


Explain RenderBody and RenderPage in ASP.Net MVC?

1161


What are the possible razor view extensions?

989


What is entitytype? : Entity framework

982


What are non action methods in mvc?

1019