com.gentlyweb.utils
public class GeneralCollector extends Object
Modifier and Type | Field and Description |
---|---|
static String |
KEYS |
static String |
VALUES |
Constructor and Description |
---|
GeneralCollector(Class c) |
GeneralCollector(Class c,
String field) |
Modifier and Type | Method and Description |
---|---|
void |
collect(Collection objects,
Collection retData) |
void |
collect(Collection objects,
List retData) |
void |
collect(List objects,
Collection retData) |
void |
collect(List objects,
List retData) |
void |
collect(Map objects,
String type,
Collection retData) |
void |
collect(Map objects,
String type,
List retData) |
void |
collect(Map objects,
String type,
Map retData) |
String |
getField()
Get a field given a field name.
|
void |
setField(String field)
Set the field that we collect if you readd the same field then
the type is just updated.
|
public static final String KEYS
public static final String VALUES
public GeneralCollector(Class c)
public void collect(Map objects, String type, List retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(Map objects, String type, Collection retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(Map objects, String type, Map retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(Collection objects, Collection retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(Collection objects, List retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(List objects, List retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void collect(List objects, Collection retData) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException
public void setField(String field) throws IllegalArgumentException
field
- The field to sort on.IllegalArgumentException
- If we can't find the field in the
class/class chain passed into the constructor.public String getField()