public enum EncodingStyle extends Enum<EncodingStyle>
Enum Constant and Description |
---|
ER7
ER7 (Pipe and Hat, or Vertical Bar encoding)
|
XML
XML encoding
|
Modifier and Type | Method and Description |
---|---|
static EncodingStyle |
detect(String theMessage)
Detect the encoding style of a given message
|
String |
getContentType()
Returns the MIME type (content-type) associated with this encoding
|
static EncodingStyle |
getEncodingStyleForContentType(String theContentType)
Returns the encoding style (e.g.
|
static EncodingStyle |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static EncodingStyle[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final EncodingStyle ER7
ER7 (Pipe and Hat, or Vertical Bar encoding)
Content type: application/hl7-v2
public static final EncodingStyle XML
XML encoding
Content type: application/hl7-v2+xml
public static EncodingStyle[] values()
for (EncodingStyle c : EncodingStyle.values()) System.out.println(c);
public static EncodingStyle valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static EncodingStyle getEncodingStyleForContentType(String theContentType)
null
if content type does not match
an HL7 definition.theContentType
- The content type (case insensitive)NullPointerException
- If theContentType is nullpublic static EncodingStyle detect(String theMessage)
NullPointerException
- If theMessage is nullIllegalArgumentException
- If the message is not ER7 or XMLpublic String getContentType()
Copyright © 2012–2017 University Health Network. All rights reserved.