Package wicket.contrib.phonebook
Interface ContactDao
-
- All Known Implementing Classes:
HibernateContactDao,ShadesContactDao
public interface ContactDaoThe implementation-independent DAO interface. Defines the operations required to be supported by an implementation.- Author:
- igor
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intcount(Contact filter)Return the number of Contacts in the DB.voiddelete(long id)Delete aContactfrom the DB, given it's id.Iterator<Contact>find(QueryParam qp, Contact filter)Query the DB, using the supplied query details.List<String>getUniqueLastNames()Returns the list of all unique last names in the databaseContactload(long id)Load aContactfrom the DB, given it's id.Contactsave(Contact contact)Save the contact to the DB
-
-
-
Method Detail
-
load
Contact load(long id)
Load aContactfrom the DB, given it's id.- Parameters:
id- The id of the Contact to load.- Returns:
- Contact
-
save
Contact save(Contact contact)
Save the contact to the DB- Parameters:
contact-- Returns:
- persistent instance of contact
-
delete
void delete(long id)
Delete aContactfrom the DB, given it's id.- Parameters:
id- The id of the Contact to delete.
-
find
Iterator<Contact> find(QueryParam qp, Contact filter)
Query the DB, using the supplied query details.- Parameters:
qp- Query Paramaters to use.- Returns:
- The results of the query as an Iterator.
-
count
int count(Contact filter)
Return the number of Contacts in the DB.- Returns:
- count
-
-