次のように、列に TextInputCell があります。
TextInputCell textCell = new TextInputCell();
Column<EffortCost, String> hourColumn = new Column<EffortCost, String>(textCell) {
public String getValue(EffortCost object) {
String formatted = NumberFormat.getFormat("0.00").format(object.getHours());
return formatted;
}
};
「1」と書いた場合、文字列が返されました:「1.00」。私は同じ結果を望んでいますが、文字列をフォーマットしたくありません。ウィジェットにこれをすぐに実行させたいのですが、テキストを TextInputCell に入れます。つまり、テキストを自分のTextInputCell. これは「MaskedTextInputCell」のようなものです。これどうやってするの?いくつかの例を見ることができますか?
ご清聴ありがとうございました。