@SmartNotifyChange("anotherProperty")
@SmartNotifyChange({"firstProperty", "secondProperty"})
@SmartNotifyChange("*")
@SmartNotifyChange(".")
Target: method (command method)
Purpose: Notify value change once it has changed, unlike @NotifyChange
.
Usually the annotation is used with @Command
.
public class OrderVM {
//other code...
//action command
@SmartNotifyChange({"selected", "orders", "messages"})
@Command
public void newOrder() {
Order order = new Order();
getOrders().add(order); // add new order to order list
selected = order; // select the new one
}
}