@Target(value={METHOD,ANNOTATION_TYPE})
@Retention(value=RUNTIME)
@Documented
public @interface SetOnce
PropertyBean
properties that can only be set to a non-null value once. A set-once property is one which can have any value when the PropertyBean
is used for a create operation. For an update operation, performed by calling ManagedPortalObject.setProperties(B)
, the PropertyBean
property value must be equal to the existing property value on the ManagedPortalObject
if the existing property value is not null.
The SetOnce annotation must be applied to the property getter method.
SetOnce properties are enforced by the presence of an ValidateSetOnce
class level validator.
ValidateSetOnce
, Immutable
Modifier and Type | Optional Element and Description |
---|---|
java.lang.Class<?> |
propertyGroup
Assigns this annotation to a particular group of property annotations.
|
public abstract java.lang.Class<?> propertyGroup
ValidateSetOnce
class annotation, that is responsible for triggering validation of the properties in this group.