IBM®
메인 컨텐츠로 가기
    Korea [국가변경]    이용약관
 
 
   
        제품    서비스 & 솔루션    고객지원 & 다운로드    회원 서비스    
메인 컨텐츠로 가기

한국 developerWorks  >  웹 아키텍쳐  >

The Spring series, Part 1: Spring 프레임웍 소개

Spring AOP와 IOC 컨테이너

developerWorks

메인으로

페이지를 출력할 때 가로방향 레이아웃 옵션을 선택하십시오.


Listing 6. CreateCreditCardAccount


   public class CreateCreditCardAccount implements 
   CreateCreditCardAccountInterface {

   public CreditLinkingInterface getCreditLinkingInterface() {
   return creditLinkingInterface;
   }


   public void setCreditLinkingInterface(
   CreditLinkingInterface creditLinkingInterface) {
   this.creditLinkingInterface = creditLinkingInterface;
   }


   public CreditRatingInterface getCreditRatingInterface() {
   return creditRatingInterface;
   }


   public void setCreditRatingInterface(CreditRatingInterface creditRatingInterface)   
   {
   this.creditRatingInterface = creditRatingInterface;
   }


   public EmailInterface getEmailInterface() {
   return emailInterface;
   }


   public void setEmailInterface(EmailInterface emailInterface) {
   this.emailInterface = emailInterface;
   }


   //Client will call this method
   public void createCreditCardAccount(ICustomer icustomer) throws Exception{
         boolean crediRating = 
         getCreditRatingInterface().getUserCreditHistoryInformation(icustomer);
         icustomer.setCreditRating(crediRating);
         //Good Rating
         if(crediRating){
         getCreditLinkingInterface().linkCreditBankAccount(icustomer);
         }

         getEmailInterface().sendEmail(icustomer);


   }

메인으로


    IBM 소개개인정보 보호정책문의