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); } }
public DirectFhirGenerator() { String sDefsPath = Path.Combine(this.OutputDir, "StructureDefinitions.json"); String specPath = Path.GetFullPath("specification.zip"); sDefs = new FhirStructureDefinitions(); this.items = new Dictionary <string, SDefInfo>(); }
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")); } }
private FhirStructureDefinitions(String bundleDir) { this.bundleDir = bundleDir; if (Directory.Exists(bundleDir) == false) { Directory.CreateDirectory(bundleDir); } String specPath = Path.GetFullPath("specification.zip"); if (File.Exists(specPath) == false) { throw new Exception($"Missing {specPath}"); } this.source = new ZipSource(specPath); FhirStructureDefinitions.Self = this; }
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")); }
public static void Create(String bundleDir) => Self = new FhirStructureDefinitions(bundleDir);
public MakerGen(String outputDir) { this.outputDir = outputDir; sDefs = new FhirStructureDefinitions(); }