Ejemplo n.º 1
0
        public static SpecificationWorkspace GetSpecification(Uri uri, bool expand)
        {
            SpecificationProvider provider = GetSpecificationResolver();
            SpecificationBuilder builder = new SpecificationBuilder(provider);
            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add(uri);
            if (expand) builder.Expand();

            return builder.ToSpecification();
        }
Ejemplo n.º 2
0
        public static SpecificationWorkspace GetProfileSpec(bool expand, bool online)
        {
            SpecificationProvider resolver = GetProvider(online);
            
            SpecificationBuilder builder = new SpecificationBuilder(resolver);
            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            if (expand) builder.Expand();

            return builder.ToSpecification();
        }
Ejemplo n.º 3
0
        public static SpecificationWorkspace GetExtendedPatientSpec(bool expand, bool online)
        {
            SpecificationProvider resolver = GetProvider(online);
            SpecificationBuilder builder = new SpecificationBuilder(resolver);
            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add("http://here.there/patient.extended.profile.xml");
            builder.Add("http://here.there/type-Extension.profile.xml");
            if (expand) builder.Expand();
            return builder.ToSpecification();

        }
Ejemplo n.º 4
0
        public static void Init(TestContext context)
        {
            SpecificationProvider provider = SpecificationProvider.CreateOffline(new FileArtifactSource("TestData"));
            SpecificationBuilder builder = new SpecificationBuilder(provider);

            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add("http://disk/Profile/lipid.profile.xml#lipidPanel");
            builder.Expand();

            spec =  builder.ToSpecification();
        }
Ejemplo n.º 5
0
        public static SpecificationWorkspace GetLipidSpec(bool expand, bool online)
        {
            SpecificationProvider resolver = GetProvider(online);
            SpecificationBuilder builder = new SpecificationBuilder(resolver);
            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add("http://here.there/TestData/valueset.profile.xml");
            builder.Add("http://here.there/TestData/lipid.profile.xml");
            if (expand) builder.Expand();
            
            return builder.ToSpecification();

        }
Ejemplo n.º 6
0
        private SpecificationWorkspace getSpecification(Uri uri, bool expand)
        {
            SpecificationProvider provider = new SpecificationProvider(Source);
            SpecificationBuilder  builder  = new SpecificationBuilder(provider);

            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(uri);
            if (expand)
            {
                builder.Expand();
            }

            return(builder.ToSpecification());
        }
Ejemplo n.º 7
0
        public static SpecificationWorkspace GetSpecification(Uri uri, bool expand)
        {
            SpecificationProvider provider = GetSpecificationResolver();
            SpecificationBuilder  builder  = new SpecificationBuilder(provider);

            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add(uri);
            if (expand)
            {
                builder.Expand();
            }

            return(builder.ToSpecification());
        }
Ejemplo n.º 8
0
        public SpecificationWorkspace Spec(string fileuri, string structure)
        {
            FhirFile.ExpandProfileFile("TestData\\" + fileuri + ".xml", "TestData\\testprofile.xml");
            Uri uri = new Uri("http://disk/testdata/testprofile.xml#"+structure);

            SpecificationProvider provider = SpecificationProvider.CreateOffline(new FileArtifactSource("TestData"));
            SpecificationBuilder builder = new SpecificationBuilder(provider);

            builder.Add(StructureFactory.PrimitiveTypes());
            builder.Add(StructureFactory.NonFhirNamespaces());
            builder.Add(uri);
            builder.Expand();

            return builder.ToSpecification();
        }