@@ -61,7 +61,7 @@ private static void DemonstrateDefaultValidationInNhapi()
6161 eventReasonCode += "RANDOMTEXT" ;
6262 }
6363
64- var anAdtMessageWithInvalidEvn4Field =
64+ var adtMessageWithInvalidEvn4Field =
6565 "MSH|^~\\ &|SENDING_APPLICATION|SENDING_FACILITY|RECEIVING_APPLICATION|RECEIVING_FACILITY|" +
6666 "20110613083617||ADT^A01|2323232223232|P|2.3||||\r " +
6767 "EVN|A01|20110613083617||" + eventReasonCode + "|\r " +
@@ -74,7 +74,7 @@ private static void DemonstrateDefaultValidationInNhapi()
7474 var parser = new PipeParser { ValidationContext = new DefaultValidation ( ) } ;
7575 try
7676 {
77- parser . Parse ( anAdtMessageWithInvalidEvn4Field ) ;
77+ parser . Parse ( adtMessageWithInvalidEvn4Field ) ;
7878 }
7979 catch ( Exception e )
8080 {
@@ -92,7 +92,7 @@ private static void DemonstrateStrictValidationInNhapi()
9292 //We are going to set the value in PID-1 (Set ID – Patient ID - 'SI' data type field) to be a negative number
9393 //This should trigger an exception as part of the strict validation rules enabled in the NHAPI parser
9494
95- var anAdtMessageWithInvalidPid1Field =
95+ var adtMessageWithInvalidPid1Field =
9696 "MSH|^~\\ &|SENDING_APPLICATION|SENDING_FACILITY|" +
9797 "RECEIVING_APPLICATION|RECEIVING_FACILITY|" +
9898 "20110613083617||ADT^A01|2323232223232|P|2.3||||\r " +
@@ -106,7 +106,7 @@ private static void DemonstrateStrictValidationInNhapi()
106106 var parser = new PipeParser { ValidationContext = new StrictValidation ( ) } ;
107107 try
108108 {
109- parser . Parse ( anAdtMessageWithInvalidPid1Field ) ;
109+ parser . Parse ( adtMessageWithInvalidPid1Field ) ;
110110 }
111111 catch ( Exception e )
112112 {
@@ -122,7 +122,7 @@ private static void DemonstrateCustomValidationUsingNhapi()
122122 //We are going to specify a message rule that EVN-4 (Event Reason Code) field is mandatory
123123 //We do not have any data for the EVN-4 field here in order to trigger the validation exception
124124
125- var anAdtMessageWithMissingEvn4Field =
125+ var adtMessageWithMissingEvn4Field =
126126 "MSH|^~\\ &|SENDING_APPLICATION|SENDING_FACILITY|RECEIVING_APPLICATION|RECEIVING_FACILITY|" +
127127 "20110613083617||ADT^A01|2323232223232|P|2.3||||\r " +
128128 "EVN|A01|20110613083617|||\r " +
@@ -131,11 +131,11 @@ private static void DemonstrateCustomValidationUsingNhapi()
131131 "PV1|1|O|||||^^^^^^^^|^^^^^^^^" ;
132132 ;
133133
134- //make the parser use our custom validation context class
134+ //make the parser use our custom message validation context class
135135 var parser = new PipeParser { ValidationContext = new OurCustomMessageValidation ( ) } ;
136136 try
137137 {
138- parser . Parse ( anAdtMessageWithMissingEvn4Field ) ;
138+ parser . Parse ( adtMessageWithMissingEvn4Field ) ;
139139 }
140140 catch ( Exception e )
141141 {
0 commit comments