示例#1
0
  private synchronized List<Hl7v2Interceptor> getProducerInterceptorChain() {
    if (producerInterceptorChain == null) {
      // set up initial interceptor chain
      List<Hl7v2Interceptor> initialChain = new ArrayList<Hl7v2Interceptor>();
      initialChain.add(new ProducerStringProcessingInterceptor());
      if (isSupportUnsolicitedFragmentation()) {
        initialChain.add(new ProducerRequestFragmenterInterceptor());
      }
      initialChain.add(
          isSupportInteractiveContinuation()
              ? new ProducerMarshalAndInteractiveResponseReceiverInterceptor()
              : new ProducerMarshalInterceptor());
      initialChain.add(new ProducerResponseAcceptanceInterceptor());
      if (isAudit()) {
        initialChain.add(new ProducerAuditInterceptor());
      }
      initialChain.add(new ProducerRequestAcceptanceInterceptor());
      initialChain.add(new ProducerAdaptingInterceptor());

      // add interceptors provided by the user
      List<Hl7v2Interceptor> additionalInterceptors =
          new ArrayList<Hl7v2Interceptor>(mllpComponent.getAdditionalProducerInterceptors());
      additionalInterceptors.addAll(customInterceptors);
      producerInterceptorChain = ChainUtils.createChain(initialChain, additionalInterceptors);
    }
    return producerInterceptorChain;
  }
示例#2
0
  private synchronized List<Hl7v2Interceptor> getConsumerInterceptorChain() {
    if (consumerInterceptorChain == null) {
      // set up initial interceptor chain
      List<Hl7v2Interceptor> initialChain = new ArrayList<Hl7v2Interceptor>();
      initialChain.add(new ConsumerStringProcessingInterceptor());
      if (isSupportUnsolicitedFragmentation()) {
        initialChain.add(new ConsumerRequestDefragmenterInterceptor());
      }
      initialChain.add(new ConsumerMarshalInterceptor());
      initialChain.add(new ConsumerRequestAcceptanceInterceptor());
      if (isSupportInteractiveContinuation()) {
        initialChain.add(new ConsumerInteractiveResponseSenderInterceptor());
      }
      if (isAudit()) {
        initialChain.add(new ConsumerAuditInterceptor());
      }
      initialChain.add(new ConsumerResponseAcceptanceInterceptor());
      initialChain.add(new ConsumerAdaptingInterceptor(getCharsetName()));
      if (isAudit()) {
        initialChain.add(new ConsumerAuthenticationFailureInterceptor());
      }

      // add interceptors provided by the user
      List<Hl7v2Interceptor> additionalInterceptors =
          new ArrayList<Hl7v2Interceptor>(mllpComponent.getAdditionalConsumerInterceptors());
      additionalInterceptors.addAll(customInterceptors);
      consumerInterceptorChain = ChainUtils.createChain(initialChain, additionalInterceptors);
    }
    return consumerInterceptorChain;
  }
示例#3
0
 /** Returns transaction-specific ACK and NAK factory. */
 @Override
 public NakFactory getNakFactory() {
   return mllpComponent.getNakFactory();
 }
示例#4
0
 /** Returns transaction configuration. */
 @Override
 public Hl7v2TransactionConfiguration getHl7v2TransactionConfiguration() {
   return mllpComponent.getHl7v2TransactionConfiguration();
 }
示例#5
0
 /** Returns server-side audit strategy instance. */
 public MllpAuditStrategy getServerAuditStrategy() {
   return mllpComponent.getServerAuditStrategy();
 }
示例#6
0
 /** Returns client-side audit strategy instance. */
 public MllpAuditStrategy getClientAuditStrategy() {
   return mllpComponent.getClientAuditStrategy();
 }