@Documented
@Target(value=METHOD)
public @interface OnPropChange
Each parameter is expected to be named according to the pattern "last[MyProp]", "prev[MyProp]"
or "[myProp]". If name of the parameter does not follow the pattern then the name can be explicitly
mapped via the PropRef
annotation on a parameter.
The method must also conform to the following constraints:
ReactComponent
SuppressWarnings
or SuppressReact4jWarnings
annotations with a key
"React4j:PublicMethod". This warning is also suppressed by the annotation processor if it is implementing
an interface method.
ReactComponent
annotation as the method is not
expected to be invoked outside the component. A warning will be generated but can be suppressed by the
SuppressWarnings
or SuppressReact4jWarnings
annotations with a key "React4j:ProtectedMethod".
Modifier and Type | Optional Element and Description |
---|---|
OnPropChange.Phase |
phase
The phase in which the method should be invoked.
|
public abstract OnPropChange.Phase phase