בג'וואה
כדי להפעיל בנאי B מתוך בנאי A צריך פקודה ראשונה בתוך בנאי A לכתוב
this();
דוגמא:
class SomeClass
{
private int a;
private in b;
public SomeClass(int a, int b)
{
this.a = a;
this.b = b;
}
public SomeClass(float a, float b)
{
this(a,b); // it casts those floats back to integers, losing the mantissa
}
}