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: 9e6113d3c8c3e13a9475b3d37afee8ace51082e2 $
Fields inherited from class com.xpn.xwiki.api.Api |
context |
Constructor Summary |
DeletedDocument(com.xpn.xwiki.doc.XWikiDeletedDocument deletedDoc,
com.xpn.xwiki.XWikiContext context)
Simple constructor, initializes a new API object with the current context and
the specified protected deleted document object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DeletedDocument
public DeletedDocument(com.xpn.xwiki.doc.XWikiDeletedDocument deletedDoc,
com.xpn.xwiki.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 com.xpn.xwiki.doc.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
Copyright © 2004-2011 XWiki. All Rights Reserved.