本文整理汇总了Java中ca.uhn.hl7v2.parser.EncodingNotSupportedException类的典型用法代码示例。如果您正苦于以下问题:Java EncodingNotSupportedException类的具体用法?Java EncodingNotSupportedException怎么用?Java EncodingNotSupportedException使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
EncodingNotSupportedException类属于ca.uhn.hl7v2.parser包,在下文中一共展示了EncodingNotSupportedException类的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: getOruR01Content
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
private Content getOruR01Content(HttpServletRequest request, LoggedInInfo loggedInInfo) throws EncodingNotSupportedException, UnsupportedEncodingException, HL7Exception {
// for OruR01 we need segmentId.
String segmentId=request.getParameter("segmentId");
ViewOruR01UIBean viewOruR01UIBean=new ViewOruR01UIBean(segmentId);
if (!viewOruR01UIBean.hasBinaryFile())
{
logger.error("Odd, this request should not have taken place, there's no binary content.", new IllegalStateException());
return(null);
}
Content content=new Content();
content.contentType=getServletContext().getMimeType(viewOruR01UIBean.getFilename());
content.data=viewOruR01UIBean.getFileContents();
LogAction.addLog(loggedInInfo.getLoggedInProviderNo(), getClass().getSimpleName(), "getOruR01Content", "segmentId="+segmentId);
return(content);
}
开发者ID:williamgrosset,项目名称:OSCAR-ConCert,代码行数:20,代码来源:ContentRenderingServlet.java
示例2: getOruR01Content
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
private Content getOruR01Content(HttpServletRequest request) throws EncodingNotSupportedException, UnsupportedEncodingException, HL7Exception {
// for OruR01 we need segmentId.
String segmentId=request.getParameter("segmentId");
ViewOruR01UIBean viewOruR01UIBean=new ViewOruR01UIBean(segmentId);
if (!viewOruR01UIBean.hasBinaryFile())
{
logger.error("Odd, this request should not have taken place, there's no binary content.", new IllegalStateException());
return(null);
}
Content content=new Content();
content.contentType=getServletContext().getMimeType(viewOruR01UIBean.getFilename());
content.data=viewOruR01UIBean.getFileContents();
LoggedInInfo loggedInInfo=LoggedInInfo.loggedInInfo.get();
LogAction.addLog(loggedInInfo.loggedInProvider.getProviderNo(), getClass().getSimpleName(), "getOruR01Content", "segmentId="+segmentId);
return(content);
}
开发者ID:oscarservice,项目名称:oscar-old,代码行数:21,代码来源:ContentRenderingServlet.java
示例3: parseMessages
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
@SuppressWarnings("unchecked")
private void parseMessages()
throws HL7Exception, EncodingNotSupportedException
{
this.inputMessage = (T) this.pipeParser.parse(this.inputText);
// if we haven't been given an output container -- use intermediate
// message
if (this.outputMessage == null)
{
// for backwards compatibility -- this allows old translations
// to be tested with new framework while we transition
this.outputMessage =
(T) this.pipeParser.parse(this.getOutputText() == null
? this.inputText
: this.getOutputText());
}
if (this.messageType == null)
{
this.messageType = this.outputMessage.getClass();
}
this.expectedMessage = (T) this.pipeParser.parse(this.expectedText);
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:25,代码来源:TestContext.java
示例4: init
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
public void init(String hl7Body) throws HL7Exception, EncodingNotSupportedException {
hl7Body = preProcess(hl7Body);
Parser parser = new GenericParser();
parser.setValidationContext(new NoValidation());
Message m = parser.parse(hl7Body);
if (!(m instanceof ORU_R01)) {
throw new HL7Exception("Unsupported message type: " + m.getName() + ". Expected ORU^R01 ver 2.2");
}
ORU_R01 message = (ORU_R01) m;
int commentReps = message.getPATIENT_RESULT().getORDER_OBSERVATION().currentReps("NTE");
if (commentReps < 2) {
throw new HL7Exception("Expected at least 2 comments in the NTE field.");
}
this.message = message;
}
开发者ID:williamgrosset,项目名称:OSCAR-ConCert,代码行数:16,代码来源:EaapsMessageSupport.java
示例5: ViewOruR01UIBean
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
public ViewOruR01UIBean(String segmentId) throws EncodingNotSupportedException, HL7Exception, UnsupportedEncodingException
{
this.segmentId=segmentId;
String hl7Message=Factory.getHL7Body(segmentId);
oruR01=(ORU_R01) OscarToOscarUtils.pipeParserParse(hl7Message);
PID pid=oruR01.getPATIENT_RESULT(0).getPATIENT().getPID();
demographic=DataTypeUtils.parsePid(pid);
observationData=OruR01.getObservationData(oruR01);
}
开发者ID:williamgrosset,项目名称:OSCAR-ConCert,代码行数:13,代码来源:ViewOruR01UIBean.java
示例6: prepare
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
public void prepare()
throws IOException, EncodingNotSupportedException, HL7Exception
{
this.pipeParser = Util.createVersionedParser("2.4");
this.loadResources();
this.parseMessages();
this.prepareExchange();
this.originalInputText = this.inputText;
this.inputText = this.inputMessage.encode();
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:12,代码来源:TestContext.java
示例7: LoadResources
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
@Override
public void LoadResources(Class<?> testClass, PipeParser pipeParser)
throws IOException, EncodingNotSupportedException, HL7Exception
{
this.inputMessage =
TestUtils.getClassResourceStream(testClass, this.name);
pipeParser.setValidationContext(new NoValidation());
this.outputMessage =
pipeParser
.parse(TestUtils.getClassResourceStream(testClass, this.output))
.encode();
// (AbstractMessage)pipeParser.parse(
// TestUtils.getClassResourceStream(testClass,
// this.output)).getFieldSeparatorValue("|");
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:16,代码来源:TranslatedTestMessage.java
示例8: LoadResources
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
@Override
public void LoadResources(Class<?> testClass, PipeParser pipeParser)
throws IOException, EncodingNotSupportedException, HL7Exception
{
this.inputMessage =
TestUtils.getClassResourceStream(testClass, this.name);
this.outputMessage = pipeParser.parse(this.inputMessage).encode();
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:9,代码来源:PassthroughTestMessage.java
示例9: init
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
public MessageResource init()
throws EncodingNotSupportedException, HL7Exception
{
this.pipeParser = Util.createVersionedParser("2.4");
this.message = this.parseMessage();
return this;
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:8,代码来源:MessageResource.java
示例10: getMessageResource
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
public static MessageResource getMessageResource(String sourceDataFile)
throws IOException, EncodingNotSupportedException, HL7Exception
{
String messageText = loadResource(sourceDataFile);
MessageResource messageResource = new MessageResource(messageText);
messageResource.init();
return messageResource;
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:9,代码来源:ResourceLoader.java
示例11: getExpectedMessage
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
private AbstractMessage getExpectedMessage()
throws HL7Exception, EncodingNotSupportedException
{
return (AbstractMessage) this.pipeParser.parse(this.expected);
}
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:6,代码来源:AbstractHl7Test.java
示例12: transform
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
void transform(AbstractProcessor processor, AbstractMessage actual)
throws EncodingNotSupportedException, HL7Exception;
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:3,代码来源:TransformerProxy.java
示例13: LoadResources
import ca.uhn.hl7v2.parser.EncodingNotSupportedException; //导入依赖的package包/类
void LoadResources(Class<?> testClass, PipeParser pipeParser)
throws IOException, EncodingNotSupportedException, HL7Exception;
开发者ID:KingsCollegeHospital,项目名称:rassyeyanie,代码行数:3,代码来源:TestMessage.java
注:本文中的ca.uhn.hl7v2.parser.EncodingNotSupportedException类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论