org.grails.datastore.gorm.finders
Class ListOrderByFinder
java.lang.Object
org.grails.datastore.gorm.finders.ListOrderByFinder
- All Implemented Interfaces:
- FinderMethod
public class ListOrderByFinder
- extends Object
- implements FinderMethod
The "listOrderBy*" static persistent method. Allows ordered listing of instances based on their properties.
eg.
Account.listOrderByHolder();
Account.listOrderByHolder(max); // max results
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ListOrderByFinder
public ListOrderByFinder(Datastore datastore)
setPattern
public void setPattern(String pattern)
- Specified by:
setPattern
in interface FinderMethod
- Parameters:
pattern
- A regular expression
invoke
public Object invoke(Class clazz,
String methodName,
Object[] arguments)
- Description copied from interface:
FinderMethod
- Invokes the method
- Specified by:
invoke
in interface FinderMethod
- Parameters:
clazz
- The classmethodName
- The method namearguments
- The arguments
- Returns:
- The return value
isMethodMatch
public boolean isMethodMatch(String methodName)
- Description copied from interface:
FinderMethod
- Whether the given method name matches this finder
- Specified by:
isMethodMatch
in interface FinderMethod
- Parameters:
methodName
- The method name
- Returns:
- true if it does