com.xpn.xwiki.criteria.impl
Class RevisionCriteria

java.lang.Object
  extended by com.xpn.xwiki.criteria.impl.RevisionCriteria

public class RevisionCriteria
extends Object

information about document versions used to retreive a set of document versions.

Since:
1.4M1
Version:
$Id: 61b6f1208bc89b7f42fa26333bb1ec9f70682746 $
See Also:
XWikiDocument.getRevisions(RevisionCriteria, com.xpn.xwiki.XWikiContext)

Constructor Summary
RevisionCriteria()
          Default constructor, the default query match the versions created by any author, from January 1, 1970, 00:00:00 GMT (epoch) to the maximum possible date (Long.MAX_VALUE), minor versions aren't included
RevisionCriteria(String author, Period period, Range range, boolean includeMinorVersions)
          Fully featured constructor, allow to set all the query parameters, null arguments are ignored
 
Method Summary
 String getAuthor()
           
 boolean getIncludeMinorVersions()
          include minor versions in the set.
 Date getMaxDate()
           
 Date getMinDate()
           
 Period getPeriod()
           
 Range getRange()
           
 void setAuthor(String author)
           
 void setIncludeMinorVersions(boolean includeMinorVersions)
           
 void setPeriod(Period period)
          Set the Period (time limits) desired for the results
 void setRange(Range range)
          Set the Range (size limits) desired for the results
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RevisionCriteria

public RevisionCriteria()
Default constructor, the default query match the versions created by any author, from January 1, 1970, 00:00:00 GMT (epoch) to the maximum possible date (Long.MAX_VALUE), minor versions aren't included


RevisionCriteria

public RevisionCriteria(String author,
                        Period period,
                        Range range,
                        boolean includeMinorVersions)
Fully featured constructor, allow to set all the query parameters, null arguments are ignored

Method Detail

getAuthor

public String getAuthor()
Returns:
author the author of version set.

setAuthor

public void setAuthor(String author)
Parameters:
author - the author of version set.

getPeriod

public Period getPeriod()
Returns:
period the Period (time limits) desired for the results

setPeriod

public void setPeriod(Period period)
Set the Period (time limits) desired for the results

Parameters:
period -

getRange

public Range getRange()
Returns:
range the Range (size limits) desired for the results

setRange

public void setRange(Range range)
Set the Range (size limits) desired for the results

Parameters:
range - desired range @see Range

getMinDate

public Date getMinDate()
Returns:
minimum date of version set.

getMaxDate

public Date getMaxDate()
Returns:
maximum date of version set.

getIncludeMinorVersions

public boolean getIncludeMinorVersions()
include minor versions in the set.


setIncludeMinorVersions

public void setIncludeMinorVersions(boolean includeMinorVersions)
Parameters:
includeMinorVersions - true to include minor versions in the set, false to ignore them.


Copyright © 2004–2014 XWiki. All rights reserved.