Interface CopyCommand
public interface CopyCommand
Command for copy fields action
- Since:
- 3.10.0
-
Method Summary
Modifier and TypeMethodDescriptionexcludeFields
(Iterable<String> excludedFields) Set list of excluded fields for copy.
All other fields will be copied.execute()
Execute copy action.
IfskipDeniedFields(boolean)
was not called withtrue
exception com.polarion.platform.security.PermissionDeniedException may be thrown
IfincludeFields(Iterable)
orexcludeFields(Iterable)
was not called before, all fields will be copied.includeAllCustomFields
(boolean value) Ifvalue
is set totrue
all custom fields will be copy even though they are in excluded fields
Default value isfalse
includeFields
(Iterable<String> includedFields) Set list of included fields for copy.
Only those fields will be copied.saveTargetObject
(boolean value) WhetherUpdatableModelObject.save()
is called on the target object after the fields are copied.skipDeniedFields
(boolean value) Ifvalue
is set totrue
the fields are checked if the user has permission READ and MODIFY.skipReadOnlyFields
(boolean value) Ifvalue
is set totrue
the fields will be checked if are not read-only (not per-field permissions).
-
Method Details
-
includeFields
Set list of included fields for copy.
Only those fields will be copied. -
excludeFields
Set list of excluded fields for copy.
All other fields will be copied. -
skipDeniedFields
Ifvalue
is set totrue
the fields are checked if the user has permission READ and MODIFY.
Those fields will not be merged and will be returned inCopyResult.notCopiedFields()
Default value isfalse
- Parameters:
value
-- Returns:
this
-
skipReadOnlyFields
Ifvalue
is set totrue
the fields will be checked if are not read-only (not per-field permissions).
It depends on the selected view in UI.
Those fields will not be merged and will be returned inCopyResult.notCopiedFields()
Default value isfalse
- Parameters:
value
-- Returns:
this
-
includeAllCustomFields
Ifvalue
is set totrue
all custom fields will be copy even though they are in excluded fields
Default value isfalse
- Parameters:
value
-- Returns:
this
-
saveTargetObject
WhetherUpdatableModelObject.save()
is called on the target object after the fields are copied. Default value istrue
.- Since:
- 3.20.2
-
execute
Execute copy action.
IfskipDeniedFields(boolean)
was not called withtrue
exception com.polarion.platform.security.PermissionDeniedException may be thrown
IfincludeFields(Iterable)
orexcludeFields(Iterable)
was not called before, all fields will be copied.- Returns:
CopyResult
where informations about executed copy action are stored
-