org.ow2.dragon.api.to
Class RequestOptionsTO

java.lang.Object
  extended by org.ow2.dragon.api.to.RequestOptionsTO

public class RequestOptionsTO
extends java.lang.Object

Defines options for requesting DragonDataBase.

This allows defining "sort", "pagination" and "case sensitive" options when requesting the DragonDataBase

Author:
ofabre - eBM Websourcing

Constructor Summary
RequestOptionsTO()
           
 
Method Summary
 int getFirstResult()
          Returns the requested first result index.
 int getNbOfResults()
          Returns the requested number of results.
 SortCriteria getSortCriteria()
          Returns the sort criteria ID
 boolean hasPagination()
          Determines whether pagination options are set
 boolean hasSortOption()
          Determines whether sort options are set
 boolean isCaseSensitive()
           
 boolean isSortAscendingly()
          Determines whether sort is ascending.
 void setCaseSensitive(boolean caseSensitive)
           
 void setFirstResult(int firstResult)
          Sets the requested first result index.
 void setNbOfResults(int nbOfResults)
          Sets the requested number of results.
 void setSortAscendingly(boolean sortAscendingly)
          Sets whether sort is ascending.
 void setSortCriteria(SortCriteria sortColumn)
          Sets the sort criteria ID
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RequestOptionsTO

public RequestOptionsTO()
Method Detail

getFirstResult

public int getFirstResult()
Returns the requested first result index.

This the pagination offset

Returns:

getNbOfResults

public int getNbOfResults()
Returns the requested number of results.

This the pagination length

Returns:

getSortCriteria

public SortCriteria getSortCriteria()
Returns the sort criteria ID

Returns:

hasPagination

public boolean hasPagination()
Determines whether pagination options are set

Returns:

hasSortOption

public boolean hasSortOption()
Determines whether sort options are set

Returns:

isCaseSensitive

public boolean isCaseSensitive()

isSortAscendingly

public boolean isSortAscendingly()
Determines whether sort is ascending.

Returns:

setCaseSensitive

public void setCaseSensitive(boolean caseSensitive)

setFirstResult

public void setFirstResult(int firstResult)
Sets the requested first result index.

Parameters:
firstResult -

setNbOfResults

public void setNbOfResults(int nbOfResults)
Sets the requested number of results.

Parameters:
nbOfResults -

setSortAscendingly

public void setSortAscendingly(boolean sortAscendingly)
Sets whether sort is ascending.

Parameters:
sortAscendingly -

setSortCriteria

public void setSortCriteria(SortCriteria sortColumn)
Sets the sort criteria ID

Parameters:
sortColumn -


Copyright © 2008-2009 eBMWebsourcing. All Rights Reserved.