| java.lang.Object com.ecyrd.jspwiki.PageLock
PageLock | public class PageLock implements Serializable(Code) | | Describes a lock acquired by an user on a page. For the most part,
the regular developer does not have to instantiate this class.
The PageLock keeps no reference to a WikiPage because otherwise it could
keep a reference to a page for a long time.
author: Janne Jalkanen |
Method Summary | |
public Date | getAcquisitionTime() Returns the timestamp on which this lock was acquired. | public Date | getExpiryTime() Returns the timestamp on which this lock will expire. | public String | getLocker() Returns the locker name. | public String | getPage() Returns the name of the page which is locked. | public long | getTimeLeft() Returns the amount of time left in minutes, rounded up to the nearest
minute (so you get a zero only at the last minute). |
PageLock | public PageLock(WikiPage page, String locker, Date acquired, Date expiry)(Code) | | Creates a new PageLock. The lock is not attached to any objects at this point.
Parameters: page - WikiPage which is locked. Parameters: locker - The username who locked this page (for display purposes). Parameters: acquired - The timestamp when the lock is acquired Parameters: expiry - The timestamp when the lock expires. |
getAcquisitionTime | public Date getAcquisitionTime()(Code) | | Returns the timestamp on which this lock was acquired.
The acquisition time. |
getExpiryTime | public Date getExpiryTime()(Code) | | Returns the timestamp on which this lock will expire.
The expiry date. |
getLocker | public String getLocker()(Code) | | Returns the locker name.
The name of the locker. |
getPage | public String getPage()(Code) | | Returns the name of the page which is locked.
The name of the page. |
getTimeLeft | public long getTimeLeft()(Code) | | Returns the amount of time left in minutes, rounded up to the nearest
minute (so you get a zero only at the last minute).
Time left in minutes. |
|
|