TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: BENJAMIN L MCGEE
from: DARIN MCBRIDE
date: 1998-03-31 19:28:00
subject: template classes

 BLM> I've recently run smack into template classes and have 
 BLM> no idea how to work
 BLM> with them.  Any documentation you can recommend, 
 BLM> electronic is prefered of
 BLM> course but I'll settle for paper if I must. Thanks alot.
What template?  Is it one normally available that we can help you with?
template void func(const T& t)
{ ... }
call as:
func(my_var); // my_var can be of any type
///////
template 
class foo
{ ... 
  void bar();
};
create an object as:
class foo f;
call bar as:
f.bar(); // just as normal!
Any other questions?  :-)
---
---------------
* Origin: Tanktalus' Tower BBS (1:250/102)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.