template class, operator T

From: Christopher (anon_at_nospam.net)
Date: 12/31/03


Date: Wed, 31 Dec 2003 04:16:25 GMT

I am trying to re-write some code from a book I am working on so that I
understand it's functionality.
I ran across this:

template <class T>
class Flag
{
public:
    // snip
    T value;
    operator T() {return value;};
    // snip
};

what does the operator T do? and is it not returning a value even a void?
,
Christopher



Relevant Pages

  • Re: template class, operator T
    ... Christopher wrote: ... > I am trying to re-write some code from a book I am working on so that I ... > understand it's functionality. ... and is it not returning a value even a void? ...
    (comp.lang.cpp)
  • Re: Enable/Disable Toolbar button
    ... Changing the state of a toolbar button effectively makes the global template ... and I can slip the 'proper' functionality in under one of them. ... the WindowSelectionChange event won't fire. ... Private Sub Document_Open ...
    (microsoft.public.word.vba.general)
  • Re: Enable/Disable Toolbar button
    ... On dirtying the template: ... and I can slip the 'proper' functionality in under one of them. ... You may have several buttons with the same .ID and .Tag ... Private Sub Document_Open ...
    (microsoft.public.word.vba.general)
  • Re: Visio 2003 Template Problem
    ... used to open up with a "drawing" that I could use and manipulate. ... Do you have any idea how I can get the drawing functionality back instead of ... the only purpose of a template but they can just provide a blank ... Now I did a 3rd install and damn the same blank template. ...
    (microsoft.public.visio.general)
  • Re: OWC11 Excel PrintArea
    ... I guess I'm not understanding the 'pringing functionality is the ... Excel defines a Print Area on each worksheet of a workbook: ... Somewhere between OWC loading the template and saving the ... >>> I am writing an ASP.NET application that is using OWC11. ...
    (microsoft.public.office.developer.web.components)