congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
GenericParser.encode
Code IndexAdd Tabnine to your IDE (free)

How to use
encode
method
in
ca.uhn.hl7v2.parser.GenericParser

Best Java code snippets using ca.uhn.hl7v2.parser.GenericParser.encode (Showing top 2 results out of 315)

origin: ca.uhn.hapi/hapi-base

/** 
 * Converts XML message to ER7, first checking integrity of parse and throwing 
 * an exception if parse not correct
 */
static String safeER7Conversion(String xmlMessage) throws HL7Exception {
  Message m = parser.parse(xmlMessage);
  String check = parser.encode(m, "XML");
  if (!equivalent(xmlMessage, check)) {
    throw new HL7Exception("Parsed and encoded message not equivalent to original (possibilities: invalid message, bug in parser)");
  }
  
  return parser.encode(m, "VB");        
}
origin: ca.uhn.hapi/hapi-osgi-base

/** 
 * Converts XML message to ER7, first checking integrity of parse and throwing 
 * an exception if parse not correct
 */
static String safeER7Conversion(String xmlMessage) throws HL7Exception {
  Message m = parser.parse(xmlMessage);
  String check = parser.encode(m, "XML");
  if (!equivalent(xmlMessage, check)) {
    throw new HL7Exception("Parsed and encoded message not equivalent to original (possibilities: invalid message, bug in parser)");
  }
  
  return parser.encode(m, "VB");        
}
ca.uhn.hl7v2.parserGenericParserencode

Popular methods of GenericParser

  • <init>
    Creates a new instance of GenericParser
  • parse
  • getAppropriateParser
    Checks the encoding of the message using getEncoding(), and returns the corresponding parser (either
  • getCriticalResponseData
    Returns a minimal amount of data from a message string, including only the data needed to send a re
  • getEncoding
    Returns a String representing the encoding of the given message, if the encoding is recognized. For
  • setPipeParserAsPrimary
    Sets the underlying PipeParser as the primary parser, so that subsequent calls to encode() will retu
  • setValidationContext
  • compile
  • setListener

Popular in Java

  • Reading from database using SQL prepared statement
  • getContentResolver (Context)
  • scheduleAtFixedRate (Timer)
  • compareTo (BigDecimal)
  • BufferedReader (java.io)
    Wraps an existing Reader and buffers the input. Expensive interaction with the underlying reader is
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • Socket (java.net)
    Provides a client-side TCP socket.
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • StringTokenizer (java.util)
    Breaks a string into tokens; new code should probably use String#split.> // Legacy code: StringTo
  • JComboBox (javax.swing)
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now