Class CqlProcessor


  • public class CqlProcessor
    extends Object
    • Constructor Detail

      • CqlProcessor

        public CqlProcessor​(List<org.hl7.fhir.utilities.npm.NpmPackage> packages,
                            List<String> folders,
                            ILibraryReader reader,
                            org.hl7.fhir.r5.context.IWorkerContext.ILoggingService logger,
                            org.fhir.ucum.UcumService ucumService,
                            String packageId,
                            String canonicalBase)
    • Method Detail

      • execute

        public void execute()
                     throws org.hl7.fhir.exceptions.FHIRException
        Do the compile. Do not return any exceptions related to content; only throw exceptions for infrastructural issues note that it's not an error if there's no .cql files - this is called without checking for their existence Any exception will stop the build cold.
        Throws:
        org.hl7.fhir.exceptions.FHIRException
      • getFileInformation

        public CqlProcessor.CqlSourceFileInformation getFileInformation​(String filename)
        Return CqlSourceFileInformation for the given filename
        Parameters:
        filename - Fully qualified name of the source file
        Returns:
      • getGeneralErrors

        public List<org.hl7.fhir.utilities.validation.ValidationMessage> getGeneralErrors()
        Called at the end after all getFileInformation have been called return any errors that didn't have any particular home, and also errors for any files that were linked but haven't been accessed using getFileInformation - these have been omitted from the IG, and that's an error
        Returns:
      • getCqlTranslatorOptions

        public org.cqframework.cql.cql2elm.CqlTranslatorOptions getCqlTranslatorOptions()
      • getLibraryManager

        public org.cqframework.cql.cql2elm.LibraryManager getLibraryManager()
      • severityToIssueType

        public static org.hl7.fhir.utilities.validation.ValidationMessage.IssueType severityToIssueType​(org.cqframework.cql.cql2elm.CqlCompilerException.ErrorSeverity severity)
      • severityToIssueSeverity

        public static org.hl7.fhir.utilities.validation.ValidationMessage.IssueSeverity severityToIssueSeverity​(org.cqframework.cql.cql2elm.CqlCompilerException.ErrorSeverity severity)
      • exceptionToValidationMessage

        public static org.hl7.fhir.utilities.validation.ValidationMessage exceptionToValidationMessage​(File file,
                                                                                                       org.cqframework.cql.cql2elm.CqlCompilerException exception)