Java Tutorial/Class Definition/This
Версия от 17:44, 31 мая 2010; (обсуждение)
The this Keyword
You use the this keyword from any method or constructor to refer to the current object.
public class Box {
int length;
int width;
int height;
public Box(int length, int width, int height) {
this.length = length;
this.width = width;
this.height = height;
}
}