Package com.ateam.webstore.dao

Examples of com.ateam.webstore.dao.CreditCardDAO


public class CreditCardService implements RepositoryService<CreditCard> {

  @Override
  public CreditCard store(CreditCard creditCard) {

    CreditCardDAO repository = new CreditCardDAO()
    return repository.save(creditCard);
   
  }
View Full Code Here


  }

  @Override
  public void remove(CreditCard creditCard) {
   
    CreditCardDAO repository = new CreditCardDAO();
    repository.delete(creditCard);
   
  }
View Full Code Here

  }

  @Override
  public Collection<CreditCard> getAll() {

    CreditCardDAO repository = new CreditCardDAO();
    return repository.getAll();
   
  }
View Full Code Here

   
  }

  @Override
  public CreditCard getById(Serializable id) {
    CreditCardDAO repository = new CreditCardDAO();
    return repository.get(id);
  }
View Full Code Here

    CreditCardDAO repository = new CreditCardDAO();
    return repository.get(id);
  }
 
  public Collection<CreditCard> getByCustomerId(Serializable id) {
    CreditCardDAO repository = new CreditCardDAO();
    Customer customer = new CustomerService().getById(id);
    return repository.getByCustomer(customer);
  }
View Full Code Here

TOP

Related Classes of com.ateam.webstore.dao.CreditCardDAO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.