H
Holger Kasten
Hello,
I would like to add imlicit or explicit cast functionality to a class.
How can I do that?
public class Varia
{
public sring _var;
}
Varia a = new Varia();
a._var = "2";
double b = 5;
How can I change it to work like this:
double res = a + b;
or to work like this:
double res = (double) a + b;
Regards,
Holger
I would like to add imlicit or explicit cast functionality to a class.
How can I do that?
public class Varia
{
public sring _var;
}
Varia a = new Varia();
a._var = "2";
double b = 5;
How can I change it to work like this:
double res = a + b;
or to work like this:
double res = (double) a + b;
Regards,
Holger