Package ca.cdr.api.camel
Interface IHl7V2CamelProcessorTxLogHelper
public interface IHl7V2CamelProcessorTxLogHelper
Transaction log helper to be used by for HL7V2 Camel procedures
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addHl7LogStepOrNewLog
(org.apache.camel.Exchange theExchange, Hl7v2ToFhirConversionResultJson theConversionResult, boolean theIntermediateProcess, TransactionLogEventTypeEnum theLogType, IHL7V2TxLogStepsProvider theStepsProvider) If transaction logging is active, logs a step if transaction log is present or a new transaction log otherwisegetHl7LogStepsForBundles
(org.apache.camel.Exchange theExchange, Hl7v2ToFhirConversionResultJson theConversionResult, String theProcedureName) Builds a list of bundles corresponding to the received conversionResultvoid
logHl7RawMsg
(String theProcedureName, org.apache.camel.Exchange theExchange, ca.uhn.hl7v2.model.Message theMessage) Adds a transaction log step If a transaction log is present or a new transaction log otherwise
-
Method Details
-
logHl7RawMsg
void logHl7RawMsg(String theProcedureName, org.apache.camel.Exchange theExchange, ca.uhn.hl7v2.model.Message theMessage) throws ca.uhn.hl7v2.HL7Exception Adds a transaction log step If a transaction log is present or a new transaction log otherwise- Parameters:
theProcedureName
- the calling procedure nametheExchange
- the camel exchangetheMessage
- the HL7V2 message- Throws:
ca.uhn.hl7v2.HL7Exception
- on message encoding failure
-
addHl7LogStepOrNewLog
void addHl7LogStepOrNewLog(org.apache.camel.Exchange theExchange, Hl7v2ToFhirConversionResultJson theConversionResult, boolean theIntermediateProcess, TransactionLogEventTypeEnum theLogType, IHL7V2TxLogStepsProvider theStepsProvider) throws ca.uhn.hl7v2.HL7Exception If transaction logging is active, logs a step if transaction log is present or a new transaction log otherwise- Parameters:
theExchange
- the camel exchangetheConversionResult
- the input Hl7v2ToFhirConversionResultJsontheIntermediateProcess
- boolean indicating if caller is intermediate HL7V2 processtheLogType
- the TransactionLogEventTypeEnumtheStepsProvider
- the HL7V2TransactionLogStepsProvider- Throws:
ca.uhn.hl7v2.HL7Exception
- when original message can't be extracted from exchange
-
getHl7LogStepsForBundles
List<TransactionLogStepJson> getHl7LogStepsForBundles(org.apache.camel.Exchange theExchange, Hl7v2ToFhirConversionResultJson theConversionResult, String theProcedureName) throws ca.uhn.hl7v2.HL7Exception Builds a list of bundles corresponding to the received conversionResult- Parameters:
theExchange
- the camel exchangetheConversionResult
- the ongoing processHl7v2ToFhirConversionResultJson
theProcedureName
- the current procedure name- Returns:
- the list of transaction log steps corresponding to the bundles contained in received theConversionResult
- Throws:
ca.uhn.hl7v2.HL7Exception
- if HL7V2 message can't be extracted fromHl7v2ToFhirConversionResultJson
-