@Component @Named(value="refactoring") @Singleton public class RefactoringScriptService extends Object implements org.xwiki.script.service.ScriptService
| Constructor and Description |
|---|
RefactoringScriptService() |
| Modifier and Type | Method and Description |
|---|---|
org.xwiki.job.Job |
changeDocumentAuthor(org.xwiki.model.reference.DocumentReference oldAuthorReference,
org.xwiki.model.reference.DocumentReference newAuthorReference)
Schedules an asynchronous job for replacing the author and the content author of the existing wiki pages.
|
org.xwiki.job.Job |
convertToNestedDocument(org.xwiki.model.reference.DocumentReference documentReference)
Schedules an asynchronous job to convert the specified terminal document to a nested document (that can have
child documents).
|
org.xwiki.job.Job |
convertToTerminalDocument(org.xwiki.model.reference.DocumentReference documentReference)
Schedules an asynchronous job to convert the specified nested document to a terminal document (that can't have
child documents).
|
org.xwiki.job.Job |
copy(Collection<org.xwiki.model.reference.EntityReference> sources,
org.xwiki.model.reference.EntityReference destination)
Schedules an asynchronous job to copy the specified source entities to the specified destination entity.
|
org.xwiki.job.Job |
copy(CopyRequest request)
Schedules an asynchronous job to perform the given copy request.
|
org.xwiki.job.Job |
copy(org.xwiki.model.reference.EntityReference source,
org.xwiki.model.reference.EntityReference destination)
Schedules an asynchronous job to copy the specified source entity to the specified destination entity.
|
org.xwiki.job.Job |
copyAs(CopyRequest request)
Schedules an asynchronous job to perform the given copy-as request.
|
org.xwiki.job.Job |
copyAs(org.xwiki.model.reference.EntityReference sourceReference,
org.xwiki.model.reference.EntityReference copyReference)
Schedules an asynchronous job to copy the specified entity with a different reference.
|
org.xwiki.job.Job |
copyAs(org.xwiki.model.reference.EntityReference reference,
String copyName)
Schedules an asynchronous job to copy the specified entity with a different name.
|
org.xwiki.job.Job |
create(Collection<org.xwiki.model.reference.EntityReference> entityReferences)
Schedules an asynchronous job to create the specified entities.
|
org.xwiki.job.Job |
create(CreateRequest request)
Schedules an asynchronous job to perform the given create request.
|
org.xwiki.job.Job |
create(org.xwiki.model.reference.EntityReference entityReference)
Schedules an asynchronous job to create the specified entity.
|
org.xwiki.job.Job |
delete(Collection<org.xwiki.model.reference.EntityReference> entityReferences)
Schedules an asynchronous job to delete the specified entities.
|
org.xwiki.job.Job |
delete(org.xwiki.model.reference.EntityReference entityReference)
Schedules an asynchronous job to delete the specified entity.
|
org.xwiki.job.Job |
delete(EntityRequest request)
Schedules an asynchronous job to perform the given delete request.
|
Exception |
getLastError()
Get the error generated while performing the previously called action.
|
RequestFactory |
getRequestFactory() |
boolean |
isRecycleBinSkippingAllowed() |
org.xwiki.job.Job |
move(Collection<org.xwiki.model.reference.EntityReference> sources,
org.xwiki.model.reference.EntityReference destination)
Schedules an asynchronous job to move the specified source entities to the specified destination entity (which
becomes their new parent).
|
org.xwiki.job.Job |
move(org.xwiki.model.reference.EntityReference source,
org.xwiki.model.reference.EntityReference destination)
Schedules an asynchronous job to move the specified source entity to the specified destination entity (which
becomes its new parent).
|
org.xwiki.job.Job |
move(MoveRequest request)
Schedules an asynchronous job to perform the given move request.
|
org.xwiki.job.Job |
permanentlyDelete(List<Long> deletedDocumentIds)
Schedules an asynchronous job for permanently deleting entities.
|
org.xwiki.job.Job |
permanentlyDelete(PermanentlyDeleteRequest request)
Schedules an asynchronous job for permanently deleting entities.
|
org.xwiki.job.Job |
permanentlyDelete(String batchId)
Schedules an asynchronous job for permanently deleting entities.
|
org.xwiki.job.Job |
rename(org.xwiki.model.reference.EntityReference oldReference,
org.xwiki.model.reference.EntityReference newReference)
Schedules an asynchronous job to rename the specified entity.
|
org.xwiki.job.Job |
rename(org.xwiki.model.reference.EntityReference reference,
String newName)
Schedules an asynchronous job to rename the specified entity.
|
org.xwiki.job.Job |
rename(MoveRequest request)
Schedules an asynchronous job to perform the given rename request.
|
org.xwiki.job.Job |
replaceUser(ReplaceUserRequest request)
Schedules an asynchronous job to perform the given request.
|
org.xwiki.job.Job |
restore(List<Long> deletedDocumentIds)
Schedules an asynchronous job for restoring the specified deleted documents.
|
org.xwiki.job.Job |
restore(RestoreRequest restoreRequest)
Schedules an asynchronous job for restoring the specified entities.
|
org.xwiki.job.Job |
restore(String batchId)
Schedules an asynchronous job for restoring the specified the batchId.
|
public RequestFactory getRequestFactory()
public org.xwiki.job.Job move(MoveRequest request)
request - the move request to performnull in case of failurepublic org.xwiki.job.Job move(Collection<org.xwiki.model.reference.EntityReference> sources, org.xwiki.model.reference.EntityReference destination)
sources - specifies the entities to be moveddestination - specifies the place where to move the entities (their new parent entity)null in case of failurepublic org.xwiki.job.Job move(org.xwiki.model.reference.EntityReference source,
org.xwiki.model.reference.EntityReference destination)
source - specifies the entity to be moveddestination - specifies the place where to move the entity (its new parent entity)null in case of failurepublic org.xwiki.job.Job rename(MoveRequest request)
request - the rename request to performnull in case of failurepublic org.xwiki.job.Job rename(org.xwiki.model.reference.EntityReference oldReference,
org.xwiki.model.reference.EntityReference newReference)
oldReference - the entity to renamenewReference - the new entity reference after the renamenull in case of failurepublic org.xwiki.job.Job rename(org.xwiki.model.reference.EntityReference reference,
String newName)
reference - the entity to renamenewName - the new entity namenull in case of failurepublic org.xwiki.job.Job convertToNestedDocument(org.xwiki.model.reference.DocumentReference documentReference)
Space1.Space2.Name is converted to Space1.Space2.Name.WebHome
.documentReference - the terminal document to convert to a nested document (that can have child documents)null in case of failurepublic org.xwiki.job.Job convertToTerminalDocument(org.xwiki.model.reference.DocumentReference documentReference)
One.Two.WebHome is converted to One.Two .documentReference - the nested document to convert to a terminal document (that can't have child documents)null in case of failurepublic org.xwiki.job.Job copy(CopyRequest request)
request - the copy request to performnull in case of failurepublic org.xwiki.job.Job copy(Collection<org.xwiki.model.reference.EntityReference> sources, org.xwiki.model.reference.EntityReference destination)
sources - specifies the entities to be copieddestination - specifies the place where to copy the entitiesnull in case of failurepublic org.xwiki.job.Job copy(org.xwiki.model.reference.EntityReference source,
org.xwiki.model.reference.EntityReference destination)
source - specifies the entity to be copieddestination - specifies the place where to copy the entitynull in case of failurepublic org.xwiki.job.Job copyAs(CopyRequest request)
request - the copy-as request to performnull in case of failurepublic org.xwiki.job.Job copyAs(org.xwiki.model.reference.EntityReference sourceReference,
org.xwiki.model.reference.EntityReference copyReference)
sourceReference - the entity to copycopyReference - the reference to use for the copynull in case of failurepublic org.xwiki.job.Job copyAs(org.xwiki.model.reference.EntityReference reference,
String copyName)
reference - the entity to copycopyName - the name to use for the copynull in case of failurepublic org.xwiki.job.Job delete(EntityRequest request)
request - the delete request to performnull in case of failurepublic org.xwiki.job.Job delete(Collection<org.xwiki.model.reference.EntityReference> entityReferences)
entityReferences - the entities to deletenull in case of failurepublic org.xwiki.job.Job delete(org.xwiki.model.reference.EntityReference entityReference)
entityReference - the entity to deletenull in case of failurepublic org.xwiki.job.Job create(CreateRequest request)
request - the create request to performnull in case of failurepublic org.xwiki.job.Job create(Collection<org.xwiki.model.reference.EntityReference> entityReferences)
entityReferences - the entities to createnull in case of failurepublic org.xwiki.job.Job create(org.xwiki.model.reference.EntityReference entityReference)
entityReference - the entity to createnull in case of failurepublic Exception getLastError()
null if no exception was thrownpublic org.xwiki.job.Job restore(RestoreRequest restoreRequest)
restoreRequest - the information of the restore to donull in case of failurepublic org.xwiki.job.Job restore(String batchId)
batchId - the batchId corresponding to the entities to restorenull in case of failurepublic org.xwiki.job.Job restore(List<Long> deletedDocumentIds)
deletedDocumentIds - the ids of the deleted documents to restorenull in case of failurepublic org.xwiki.job.Job permanentlyDelete(PermanentlyDeleteRequest request)
request - the request to run.null in case of failurepublic org.xwiki.job.Job permanentlyDelete(String batchId)
batchId - the batchId with the entities to permanently deletenull in case of failurepublic org.xwiki.job.Job permanentlyDelete(List<Long> deletedDocumentIds)
deletedDocumentIds - the list of document ids to deletenull in case of failurepublic org.xwiki.job.Job changeDocumentAuthor(org.xwiki.model.reference.DocumentReference oldAuthorReference,
org.xwiki.model.reference.DocumentReference newAuthorReference)
oldAuthorReference - the old author referencenewAuthorReference - the new author referencenull in case of failurepublic org.xwiki.job.Job replaceUser(ReplaceUserRequest request)
request - the request to perform (specifies the old user reference and the new user reference)null in case of failure@Unstable public boolean isRecycleBinSkippingAllowed()
true if the current user can be given the option to choose between sending a document to the
recycle bin or deleting it permanently. false otherwise.Copyright © 2004–2021 XWiki. All rights reserved.