net.sourceforge.floggy.persistence
Interface PolymorphicObjectSet
- All Superinterfaces:
- ObjectSet
public interface PolymorphicObjectSet
- extends ObjectSet
An interface representing a search result. The
PolymorphicObjectSet
logically maintains a sequence of the
object's IDs. It is possible to iterate over all objects (or a subset, if an
optional object filter has been supplied) using the
get(int index)
method.
PersistableManager pm = PersistableManager.getInstance();
PolymorphicObjectSet os = manager.polymorphicFind(Customer.class, null, null);
for(int i = 0; i < os.size(); i++) {
Customer customer = (Customer) os.get(i);
...
}
By using an optional Filter
, only the objects that matches
the provided filter will be avaiable in this set.
By using an optional Comparator
, the order of the objects in
this set will be determined by the comparator.
- Since:
- 1.4.0
- Author:
- Thiago Moreira
- See Also:
PersistableManager.polymorphicFind(Class, Filter, boolean)
,
Filter
,
Comparator
Copyright © 2006-2011 Floggy Open Source Group. All Rights Reserved.