1 16 17 package org.springframework.jca.cci.object; 18 19 import javax.resource.cci.ConnectionFactory ; 20 import javax.resource.cci.InteractionSpec ; 21 22 import org.springframework.beans.factory.InitializingBean; 23 import org.springframework.jca.cci.core.CciTemplate; 24 25 37 public abstract class EisOperation implements InitializingBean { 38 39 private CciTemplate cciTemplate = new CciTemplate(); 40 41 private InteractionSpec interactionSpec; 42 43 44 49 public void setCciTemplate(CciTemplate cciTemplate) { 50 if (cciTemplate == null) { 51 throw new IllegalArgumentException ("cciTemplate must not be null"); 52 } 53 this.cciTemplate = cciTemplate; 54 } 55 56 59 public CciTemplate getCciTemplate() { 60 return this.cciTemplate; 61 } 62 63 66 public void setConnectionFactory(ConnectionFactory connectionFactory) { 67 this.cciTemplate.setConnectionFactory(connectionFactory); 68 } 69 70 73 public void setInteractionSpec(InteractionSpec interactionSpec) { 74 this.interactionSpec = interactionSpec; 75 } 76 77 80 public InteractionSpec getInteractionSpec() { 81 return this.interactionSpec; 82 } 83 84 85 public void afterPropertiesSet() { 86 this.cciTemplate.afterPropertiesSet(); 87 88 if (this.interactionSpec == null) { 89 throw new IllegalArgumentException ("interactionSpec is required"); 90 } 91 } 92 93 } 94 | Popular Tags |