Package org.xwiki.refactoring.job
Class MoveRequest
- java.lang.Object
-
- org.xwiki.job.AbstractRequest
-
- org.xwiki.job.api.AbstractCheckRightsRequest
-
- org.xwiki.refactoring.job.EntityRequest
-
- org.xwiki.refactoring.job.AbstractCopyOrMoveRequest
-
- org.xwiki.refactoring.job.MoveRequest
-
- All Implemented Interfaces:
Serializable
,org.xwiki.job.Request
public class MoveRequest extends AbstractCopyOrMoveRequest
A job request that can be used to move a collection of entities to a specified destination. This request can also be used to rename an entity.- Since:
- 7.2M1
- Version:
- $Id: 5f524721354e74ce9e08d7f5ed0a273f612c2cb1 $
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MoveRequest()
Default constructor.MoveRequest(org.xwiki.job.Request request)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
isAutoRedirect()
boolean
isDeleteSource()
Deprecated.Since 10.11 the MoveRequest does not handle copy anymore.boolean
isUpdateParentField()
void
setAutoRedirect(boolean autoRedirect)
Sets whether the original pages should be redirected automatically to the new location when accessed by the user, in order to preserve external links.void
setDeleteSource(boolean deleteSource)
Deprecated.Since 10.11 the MoveRequest does not handle copy anymore.void
setUpdateParentField(boolean updateParentField)
Sets whether the parent-child relationship should be preserved by updating theparent
field of thesource
's child pages to use thedestination
as parent instead;false
otherwise.-
Methods inherited from class org.xwiki.refactoring.job.AbstractCopyOrMoveRequest
getDestination, isUpdateLinks, isUpdateLinksOnFarm, setDestination, setUpdateLinks, setUpdateLinksOnFarm
-
Methods inherited from class org.xwiki.refactoring.job.EntityRequest
getEntityParameters, getEntityReferences, getJobType, isDeep, setDeep, setEntityParameters, setEntityReferences, setJobType
-
Methods inherited from class org.xwiki.job.api.AbstractCheckRightsRequest
getAuthorReference, getUserReference, isCheckAuthorRights, isCheckRights, setAuthorReference, setCheckAuthorRights, setCheckRights, setUserReference
-
Methods inherited from class org.xwiki.job.AbstractRequest
containsProperty, equals, getContext, getId, getProperties, getProperty, getProperty, getPropertyNames, hashCode, isInteractive, isRemote, isStatusLogIsolated, isStatusSerialized, isVerbose, removeProperty, setContext, setId, setId, setId, setInteractive, setProperty, setRemote, setStatusLogIsolated, setStatusSerialized, setVerbose
-
-
-
-
Method Detail
-
isDeleteSource
@Deprecated public boolean isDeleteSource()
Deprecated.Since 10.11 the MoveRequest does not handle copy anymore. So it should always delete the source.- Returns:
true
if the source entities specified byEntityRequest.getEntityReferences()
should be deleted,false
otherwise; in a standard move operation the source is deleted but sometimes you may want to keep the source as a backup; this option can also be used to perform a copy instead of a move; note that the difference between a copy and a standard move without delete is that the back-links are not updated
-
setDeleteSource
@Deprecated public void setDeleteSource(boolean deleteSource)
Deprecated.Since 10.11 the MoveRequest does not handle copy anymore. So it should always delete the source.Sets whether the source entities specified byEntityRequest.getEntityReferences()
should be deleted or not.- Parameters:
deleteSource
-true
to delete the source,false
to keep it as a backup
-
isAutoRedirect
public boolean isAutoRedirect()
- Returns:
true
if the original pages should be redirected automatically to the new location when accessed by the user, in order to preserve external links,false
otherwise
-
setAutoRedirect
public void setAutoRedirect(boolean autoRedirect)
Sets whether the original pages should be redirected automatically to the new location when accessed by the user, in order to preserve external links.- Parameters:
autoRedirect
-true
to automatically redirect the old pages to the new location,false
otherwise
-
isUpdateParentField
public boolean isUpdateParentField()
- Returns:
true
if the parent-child relationship should be preserved by updating theparent
field of thesource
's child pages to use thedestination
as parent instead;false
otherwise- Since:
- 8.0M2, 7.4.2
-
setUpdateParentField
public void setUpdateParentField(boolean updateParentField)
Sets whether the parent-child relationship should be preserved by updating theparent
field of thesource
's child pages to use thedestination
as parent instead;false
otherwise.- Parameters:
updateParentField
-true
to update the parent field of thesource
's child pages and use thedestination
as parent instead,false
otherwise- Since:
- 8.0M2, 7.4.2
-
-