concatenation

From: Laszlo (graf.laszlo_at_axis.hu)
Date: 02/28/05


Date: 28 Feb 2005 05:25:58 -0800

Hi all

I my A C++ class at a point I declared a
     char *toString()
method. My class A, I have some private
members like
     float l, h;
     char *name
wich are initialized by the constructor:
     l = 10.0;
     h = 15.8;
     name = "THE_NAME";

When I invoke the toString method, I would
like to get a result like this:

     NAME[THE_NAME]:LENGTH[10.0]:HEIGHT[15.8]

How should I write the toString method?
Thank you.

Laci



Relevant Pages

  • Re: "Subclassing" Date
    ... as indicated by the Subject: "Subclassing" Date. ... Well, that changes the specifications, viz. ... with only two exceptions: when the constructor is called ... and the toString method. ...
    (comp.lang.javascript)
  • Re: "Subclassing" Date
    ... as indicated by the Subject: "Subclassing" Date. ... Well, that changes the specifications, viz. ... with only two exceptions: when the constructor is called ... and the toString method. ...
    (comp.lang.javascript)