One more question about Attributes

  • Thread starter Thread starter C.G. Oh
  • Start date Start date
C

C.G. Oh

These Attributes seems very similar to C++ template.

What do you think about it?

Thanks,

C.G.
 
C.G. Oh said:
These Attributes seems very similar to C++ template.

What do you think about it?

Um, they're entirely different as far as I can tell. What makes you
think they're similar?
 
if you are referring writing IDL for COM using C++ yeah it sure is... we had
tags there as well... that was more like RPC def with COM enhancements
but templates no. cant think of a similarity. with attributes you are
marking the particular class so that framework knows how to treat it as Jon
mentioned in your earlier post.. whether a particular class is say
Serializable. or Is it a WebService or is a particular method in a
WebService class a WebMethod to be exposed.

Vector or a map or a string in STL etc dont need or use attributes and you
dont define any if you are making your class a template class, you just
specify generic substitute typename T but you have generics in C++ for .net
as well and coming to C# in 2.0

--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
 
Back
Top