congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
LenientErrorHandler.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
ca.uhn.fhir.parser.LenientErrorHandler
constructor

Best Java code snippets using ca.uhn.fhir.parser.LenientErrorHandler.<init> (Showing top 7 results out of 315)

origin: jamesagnew/hapi-fhir

public void parse() throws FileNotFoundException, IOException {
  FhirContext ctx = FhirContext.forDstu2();
  IParser newXmlParser = ctx.newXmlParser();
  newXmlParser.setParserErrorHandler(new LenientErrorHandler(false));
origin: jamesagnew/hapi-fhir

@Override
public IBaseResource getResource() {
  if (myParsed == null) {
    IParser parser = getResourceAsStringEncoding().newParser(getFhirContext());
    LenientErrorHandler errorHandler = new LenientErrorHandler();
    errorHandler.setErrorOnInvalidValue(false);
    parser.setParserErrorHandler(errorHandler);
    myParsed = parser.parseResource(getResourceAsString());
  }
  return myParsed;
}
origin: jamesagnew/hapi-fhir

if (igPack != null) {
  FhirContext hl7orgCtx = FhirContext.forDstu2Hl7Org();
  hl7orgCtx.setParserErrorHandler(new LenientErrorHandler(false));
  IgPackParserDstu2 parser = new IgPackParserDstu2(hl7orgCtx);
  org.hl7.fhir.instance.hapi.validation.IValidationSupport igValidationSupport = parser.parseIg(igPack, igpackFilename);
origin: jamesagnew/hapi-fhir

if (resourceEncoding != ResourceEncodingEnum.DEL) {
  IParser parser = resourceEncoding.newParser(getContext(theEntity.getFhirVersion()));
  parser.setParserErrorHandler(new LenientErrorHandler(false).setErrorOnInvalidValue(false));
origin: ca.uhn.hapi.fhir/hapi-fhir-base

@Override
public IBaseResource getResource() {
  if (myParsed == null) {
    IParser parser = getResourceAsStringEncoding().newParser(getFhirContext());
    LenientErrorHandler errorHandler = new LenientErrorHandler();
    errorHandler.setErrorOnInvalidValue(false);
    parser.setParserErrorHandler(errorHandler);
    myParsed = parser.parseResource(getResourceAsString());
  }
  return myParsed;
}
origin: FirelyTeam/fhirstarters

  public static void main(String[] args) {
    String input = "<Encounter xmlns=\"http://hl7.org/fhir\"><AAAA value=\"foo\"/></Encounter>";

    IParser p = FhirContext.forDstu3().newXmlParser();
    
    // Parse with (default) lenient error handler
    p.setParserErrorHandler(new LenientErrorHandler());
    p.parseResource(input);

    // Parse with strict error handler
    p.setParserErrorHandler(new StrictErrorHandler());
    p.parseResource(input);
  }
}
origin: ca.uhn.hapi.fhir/hapi-fhir-jpaserver-base

if (resourceEncoding != ResourceEncodingEnum.DEL) {
  IParser parser = resourceEncoding.newParser(getContext(theEntity.getFhirVersion()));
  parser.setParserErrorHandler(new LenientErrorHandler(false).setErrorOnInvalidValue(false));
ca.uhn.fhir.parserLenientErrorHandler<init>

Javadoc

Constructor which configures this handler to log all errors

Popular methods of LenientErrorHandler

  • setErrorOnInvalidValue
    If set to false (default is true) invalid values will be logged. By default invalid attribute values
  • createIncorrectJsonTypeMessage

Popular in Java

  • Reactive rest calls using spring rest template
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getSupportFragmentManager (FragmentActivity)
  • putExtra (Intent)
  • Pointer (com.sun.jna)
    An abstraction for a native pointer data type. A Pointer instance represents, on the Java side, a na
  • Component (java.awt)
    A component is an object having a graphical representation that can be displayed on the screen and t
  • BufferedReader (java.io)
    Wraps an existing Reader and buffers the input. Expensive interaction with the underlying reader is
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Github Copilot alternatives
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