public class EncodingCharacters extends Object implements Cloneable
Constructor and Description |
---|
EncodingCharacters(char fieldSeparator,
char componentSeparator,
char repetitionSeparator,
char escapeCharacter,
char subcomponentSeparator) |
EncodingCharacters(char fieldSeparator,
char componentSeparator,
char repetitionSeparator,
char escapeCharacter,
char subcomponentSeparator,
char truncationCharacter) |
EncodingCharacters(char fieldSeparator,
String encodingCharacters)
Creates new EncodingCharacters object with the given character
values.
|
EncodingCharacters(EncodingCharacters other)
copies contents of "other"
|
Modifier and Type | Method and Description |
---|---|
Object |
clone() |
static EncodingCharacters |
defaultInstance()
Returns an instance of encoding characters with the standard ER7 encoding characters
defined: |^~\&
|
boolean |
equals(Object o) |
char |
getComponentSeparator()
Returns the component separator.
|
char |
getEscapeCharacter()
Returns the escape character.
|
char |
getFieldSeparator()
Returns the field separator.
|
static EncodingCharacters |
getInstance(Message message)
Returns an instance using the MSH-1 and MSH-2 values of the given message
|
char |
getRepetitionSeparator()
Returns the repetition separator.
|
char |
getSubcomponentSeparator()
Returns the subcomponent separator.
|
char |
getTruncationCharacter()
Returns the truncation character.
|
int |
hashCode() |
void |
setComponentSeparator(char newComponentSep) |
void |
setEscapeCharacter(char newEscapeChar) |
void |
setFieldSeparator(char newFieldSep) |
void |
setRepetitionSeparator(char newRepetitionSep) |
void |
setSubcomponentSeparator(char newSubcomponentSep) |
void |
setTruncationCharacter(char newTruncationChar) |
String |
toString()
Returns the encoding characters (not including field separator)
as a string.
|
public EncodingCharacters(char fieldSeparator, String encodingCharacters)
fieldSeparator
- field seperatorencodingCharacters
- consists of the characters that appear in
MSH-2 (see section 2.8 of the HL7 spec). The characters are
Component Separator, Repetition Separator, Escape Character,
Subcomponent Separator, and, as of v2.7, the Truncation Character
(in that order).public EncodingCharacters(char fieldSeparator, char componentSeparator, char repetitionSeparator, char escapeCharacter, char subcomponentSeparator)
public EncodingCharacters(char fieldSeparator, char componentSeparator, char repetitionSeparator, char escapeCharacter, char subcomponentSeparator, char truncationCharacter)
public EncodingCharacters(EncodingCharacters other)
public static EncodingCharacters getInstance(Message message) throws HL7Exception
message
- the messageHL7Exception
- If either MSH-1 or MSH-2 are not populatedpublic char getFieldSeparator()
public char getComponentSeparator()
public char getRepetitionSeparator()
public char getEscapeCharacter()
public char getSubcomponentSeparator()
public char getTruncationCharacter()
public String toString()
public Object clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
public void setFieldSeparator(char newFieldSep)
public void setComponentSeparator(char newComponentSep)
public void setRepetitionSeparator(char newRepetitionSep)
public void setEscapeCharacter(char newEscapeChar)
public void setSubcomponentSeparator(char newSubcomponentSep)
public void setTruncationCharacter(char newTruncationChar)
public boolean equals(Object o)
equals
in class Object
Object.equals(java.lang.Object)
public int hashCode()
hashCode
in class Object
Object.hashCode()
public static EncodingCharacters defaultInstance()
Copyright © 2001–2017 University Health Network. All rights reserved.