Code example for ObjectRetrievalFailureException

0
	} 
 
	public Account findByCreditCard(String creditCardNumber) { 
		Account account = accountsByCreditCard.get(creditCardNumber); 
		if (account == null) { 
			throw new ObjectRetrievalFailureException(Account.class, creditCardNumber); 
		} 
		return account; 
	} 
 
	public void updateBeneficiaries(Account account) { 
		// nothing to do, everything is in memory 
	} 
}