自分メモです。
b.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
// @todo
}
});
これをXtendだったら
b.addActionListener([e|
// @todo
])
メソッドが一個のインターフェースならなんでも、ラムダと同じでokぽい。
More than 5 years have passed since last update.
自分メモです。
b.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
// @todo
}
});
これをXtendだったら
b.addActionListener([e|
// @todo
])
メソッドが一個のインターフェースならなんでも、ラムダと同じでokぽい。
Register as a new user and use Qiita more conveniently