public interface CustomerDao
| Modifier and Type | Method and Description |
|---|---|
Customer |
create() |
void |
delete(Customer customer)
Remove a customer from the persistent store
|
void |
detach(Customer customer)
Detaches the given Customer instance from the entity manager.
|
List<Customer> |
readBatchCustomers(int start,
int pageSize)
Reads a batch list of customers from the DB.
|
List<Customer> |
readBatchCustomersFromLastID(Long lastID,
int pageSize)
Reads a batch of customer using ID as a starting point
|
Customer |
readCustomerByEmail(String emailAddress)
Returns the first customer that matches the passed in email.
|
Customer |
readCustomerByExternalId(String externalId) |
Customer |
readCustomerById(Long id) |
Customer |
readCustomerByUsername(String username)
Returns the first customer that match the passed in username, with caching defaulted.
|
Customer |
readCustomerByUsername(String username,
Boolean cacheable)
Returns the first customer that match the passed in username, and caches according to
cacheable.
|
List<Customer> |
readCustomersByEmail(String emailAddress)
Returns all customers that matches the passed in email.
|
List<Customer> |
readCustomersByIds(List<Long> ids) |
List<Customer> |
readCustomersByUsername(String username)
Returns all customers that match the passed in username, with caching defaulted.
|
List<Customer> |
readCustomersByUsername(String username,
Boolean cacheable)
Returns all customers that match the passed in username, and caches according to
cacheable.
|
Long |
readNumberOfCustomers() |
void |
refreshCustomer(Customer customer) |
Customer |
save(Customer customer) |
List<Customer> readBatchCustomers(int start, int pageSize)
start - pageSize - List<Customer> readBatchCustomersFromLastID(Long lastID, int pageSize)
lastID - pageSize - Customer readCustomerByUsername(String username)
username - Customer readCustomerByUsername(String username, Boolean cacheable)
username - cacheable - List<Customer> readCustomersByUsername(String username)
username - List<Customer> readCustomersByUsername(String username, Boolean cacheable)
username - cacheable - Customer readCustomerByEmail(String emailAddress)
emailAddress - List<Customer> readCustomersByEmail(String emailAddress)
emailAddress - Customer create()
void delete(Customer customer)
customer - the customer entity to removevoid detach(Customer customer)
customer - Long readNumberOfCustomers()
void refreshCustomer(Customer customer)
Copyright © 2021. All rights reserved.