com.xpn.xwiki.api
Class DeletedDocument
java.lang.Object
com.xpn.xwiki.api.Api
com.xpn.xwiki.api.DeletedDocument
public class DeletedDocument
- extends Api
Information about a deleted document in the recycle bin.
- Version:
- $Id: 2c0440a480720743042e86c1d139229f228ca091 $
Fields inherited from class com.xpn.xwiki.api.Api |
context |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DeletedDocument
public DeletedDocument(XWikiDeletedDocument deletedDoc,
XWikiContext context)
- Simple constructor, initializes a new API object with the current
context
and
the specified protected deleted document
object.
- Parameters:
deletedDoc
- the internal object wrapped by this APIcontext
- the current request context
getFullName
public String getFullName()
- Returns:
- full name of document (ie: Main.WebHome)
getLanguage
public String getLanguage()
- Returns:
- language of document
getDate
public Date getDate()
- Returns:
- date of delete action
getDeleter
public String getDeleter()
- Returns:
- user which delete document
getId
public long getId()
- Returns:
- id of deleted document. id is unique only for this document.
canUndelete
public boolean canUndelete()
- Check if the current user has the right to restore the document.
- Returns:
true
if the current user can restore this document, false
otherwise
canDelete
public boolean canDelete()
- Returns:
true
if the current user can permanently delete this document, false
otherwise
getDeletedDocument
@Programming
public XWikiDeletedDocument getDeletedDocument()
- Returns:
- original deleted document if user has programming rights, else
null
.
getDocument
public Document getDocument()
- Returns:
- the document as it is in the recycle bin if the user has admin rights,
null
otherwise
Copyright © 2004-2013 XWiki. All Rights Reserved.