Esempio n. 1
0
        public ResourcesMaker(FileCleaner fc,
                              String resourceDir,
                              String pageDir,
                              String cacheDir)
        {
            const String fcn = "ResourcesMaker";

            Self = this;

            this.fc          = fc;
            this.resourceDir = resourceDir;
            this.pageDir     = pageDir;

            if (Directory.Exists(this.resourceDir) == false)
            {
                Directory.CreateDirectory(this.resourceDir);
            }

            if (Directory.Exists(this.pageDir) == false)
            {
                Directory.CreateDirectory(this.pageDir);
            }

            if (FhirStructureDefinitions.Self == null)
            {
                this.ConversionInfo(this.GetType().Name, fcn, $"Init'g 'FhirStructureDefinitions'");
                FhirStructureDefinitions.Create(cacheDir);
            }
        }
Esempio n. 2
0
        public PreFhirGenerator(FileCleaner fc, String cacheDir)
        {
            const String fcn = "PreFhirGenerator";

            this.fc = fc;
            if (FhirStructureDefinitions.Self == null)
            {
                this.ConversionInfo(this.GetType().Name, fcn, $"Init'g 'FhirStructureDefinitions'");
                FhirStructureDefinitions.Create(Path.Combine(cacheDir, "DefinitionCache"));
            }
        }
        public void Dump()
        {
            String baseDir = DirHelper.FindParentDir("BreastRadiology.XUnitTests");
            String rDir    = Path.Combine(baseDir, "Resources");
            String path    = Path.Combine(rDir, "Template.html");

            String cacheDir = Path.Combine(baseDir, "Cache");

            FhirStructureDefinitions.Create(cacheDir);

            CodeEditor ce = new CodeEditor();

            ce.Load(path);
            CodeBlockNested b = ce.Blocks.Find("Body");

            this.Dump(b);
            ce.Save(Path.Combine(DirHelper.FindParentDir(BaseDirName), "IG", "Content", "Dump.html"));
        }