Skip to content

Commit

Permalink
Merge pull request #2986 from FirelyTeam/6.0/run-improved-codegen
Browse files Browse the repository at this point in the history
Some renames to types that were incorrect.
  • Loading branch information
mmsmits authored Dec 5, 2024
2 parents 0a31ed4 + 64e79f0 commit fcfb244
Show file tree
Hide file tree
Showing 6 changed files with 51 additions and 23 deletions.
4 changes: 2 additions & 2 deletions src/Hl7.Fhir.Base/Model/Generated/Narrative.cs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public enum NarrativeStatus
/// <summary>
/// generated | extensions | additional | empty.
/// </summary>
[FhirElement("status", InSummary=true, Order=30)]
[FhirElement("status", Order=30)]
[DeclaredType(Type = typeof(Code))]
[Binding("NarrativeStatus")]
[Cardinality(Min=1,Max=1)]
Expand Down Expand Up @@ -130,7 +130,7 @@ public Hl7.Fhir.Model.Narrative.NarrativeStatus? Status
/// <summary>
/// Limited xhtml content.
/// </summary>
[FhirElement("div", XmlSerialization = XmlRepresentation.XHtml, InSummary=true, Order=40)]
[FhirElement("div", XmlSerialization = XmlRepresentation.XHtml, Order=40)]
[Cardinality(Min=1,Max=1)]
[DataMember]
public Hl7.Fhir.Model.XHtml DivElement
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public void TestResolve()
Assert.IsNull(inner7.Resolve("http://nu.nl/3", externalResolve));
Assert.AreEqual("http://nu.nl/3", lastUrlResolved);

IScopedNode? externalResolve(string url)
IScopedNode externalResolve(string url)
{
lastUrlResolved = url;
return null;
Expand Down
14 changes: 14 additions & 0 deletions src/Hl7.Fhir.R4B/CompatibilitySuppressions.xml
Original file line number Diff line number Diff line change
@@ -1,13 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- https://learn.microsoft.com/en-us/dotnet/fundamentals/package-validation/diagnostic-ids -->
<Suppressions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Suppression>
<DiagnosticId>CP0001</DiagnosticId>
<Target>T:Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent</Target>
<Left>lib/net8.0/Hl7.Fhir.R4B.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R4B.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>CP0002</DiagnosticId>
<Target>M:Hl7.Fhir.FhirPath.FhirPathExtensions.ToFhirPathResolver(System.Func{System.String,Hl7.Fhir.Model.Resource})</Target>
<Left>lib/net8.0/Hl7.Fhir.R4B.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R4B.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>CP0002</DiagnosticId>
<Target>M:Hl7.Fhir.Model.Citation.CitedArtifactContributorshipComponent.get_Summary</Target>
<Left>lib/net8.0/Hl7.Fhir.R4B.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R4B.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>PKV006</DiagnosticId>
<Target>.NETStandard,Version=v2.0</Target>
Expand Down
20 changes: 10 additions & 10 deletions src/Hl7.Fhir.R4B/Model/Generated/Citation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3977,13 +3977,13 @@ public List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>
[FhirElement("summary", Order=60)]
[Cardinality(Min=0,Max=-1)]
[DataMember]
public List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent> Summary
public List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent> Summary
{
get { if(_Summary==null) _Summary = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>(); return _Summary; }
get { if(_Summary==null) _Summary = new List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>(); return _Summary; }
set { _Summary = value; OnPropertyChanged("Summary"); }
}

private List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent> _Summary;
private List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent> _Summary;

public override IDeepCopyable CopyTo(IDeepCopyable other)
{
Expand All @@ -3997,7 +3997,7 @@ public override IDeepCopyable CopyTo(IDeepCopyable other)
base.CopyTo(dest);
if(CompleteElement != null) dest.CompleteElement = (Hl7.Fhir.Model.FhirBoolean)CompleteElement.DeepCopy();
if(Entry.Any()) dest.Entry = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>(Entry.DeepCopy());
if(Summary.Any()) dest.Summary = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>(Summary.DeepCopy());
if(Summary.Any()) dest.Summary = new List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>(Summary.DeepCopy());
return dest;
}

Expand Down Expand Up @@ -4063,7 +4063,7 @@ internal protected override Base SetValue(string key, object value)
Entry = (List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>)value;
return this;
case "summary":
Summary = (List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>)value;
Summary = (List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>)value;
return this;
default:
return base.SetValue(key, value);
Expand Down Expand Up @@ -4859,7 +4859,7 @@ internal protected override IEnumerable<KeyValuePair<string, object>> GetElement
[Serializable]
[DataContract]
[FhirType("Citation.citedArtifact.contributorship.summary", IsBackboneType=true)]
public partial class CitedArtifactContributorshipSummaryComponent : Hl7.Fhir.Model.BackboneElement
public partial class ContributorshipSummaryComponent : Hl7.Fhir.Model.BackboneElement
{
/// <summary>
/// FHIR Type Name
Expand Down Expand Up @@ -4942,7 +4942,7 @@ public string Value

public override IDeepCopyable CopyTo(IDeepCopyable other)
{
var dest = other as CitedArtifactContributorshipSummaryComponent;
var dest = other as ContributorshipSummaryComponent;

if (dest == null)
{
Expand All @@ -4959,13 +4959,13 @@ public override IDeepCopyable CopyTo(IDeepCopyable other)

public override IDeepCopyable DeepCopy()
{
return CopyTo(new CitedArtifactContributorshipSummaryComponent());
return CopyTo(new ContributorshipSummaryComponent());
}

///<inheritdoc />
public override bool Matches(IDeepComparable other)
{
var otherT = other as CitedArtifactContributorshipSummaryComponent;
var otherT = other as ContributorshipSummaryComponent;
if(otherT == null) return false;

if(!base.Matches(otherT)) return false;
Expand All @@ -4979,7 +4979,7 @@ public override bool Matches(IDeepComparable other)

public override bool IsExactly(IDeepComparable other)
{
var otherT = other as CitedArtifactContributorshipSummaryComponent;
var otherT = other as ContributorshipSummaryComponent;
if(otherT == null) return false;

if(!base.IsExactly(otherT)) return false;
Expand Down
14 changes: 14 additions & 0 deletions src/Hl7.Fhir.R5/CompatibilitySuppressions.xml
Original file line number Diff line number Diff line change
@@ -1,13 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- https://learn.microsoft.com/en-us/dotnet/fundamentals/package-validation/diagnostic-ids -->
<Suppressions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Suppression>
<DiagnosticId>CP0001</DiagnosticId>
<Target>T:Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent</Target>
<Left>lib/net8.0/Hl7.Fhir.R5.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R5.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>CP0002</DiagnosticId>
<Target>M:Hl7.Fhir.FhirPath.FhirPathExtensions.ToFhirPathResolver(System.Func{System.String,Hl7.Fhir.Model.Resource})</Target>
<Left>lib/net8.0/Hl7.Fhir.R5.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R5.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>CP0002</DiagnosticId>
<Target>M:Hl7.Fhir.Model.Citation.CitedArtifactContributorshipComponent.get_Summary</Target>
<Left>lib/net8.0/Hl7.Fhir.R5.dll</Left>
<Right>lib/net8.0/Hl7.Fhir.R5.dll</Right>
<IsBaselineSuppression>true</IsBaselineSuppression>
</Suppression>
<Suppression>
<DiagnosticId>PKV006</DiagnosticId>
<Target>.NETStandard,Version=v2.0</Target>
Expand Down
20 changes: 10 additions & 10 deletions src/Hl7.Fhir.R5/Model/Generated/Citation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3677,13 +3677,13 @@ public List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>
[FhirElement("summary", Order=60)]
[Cardinality(Min=0,Max=-1)]
[DataMember]
public List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent> Summary
public List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent> Summary
{
get { if(_Summary==null) _Summary = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>(); return _Summary; }
get { if(_Summary==null) _Summary = new List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>(); return _Summary; }
set { _Summary = value; OnPropertyChanged("Summary"); }
}

private List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent> _Summary;
private List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent> _Summary;

public override IDeepCopyable CopyTo(IDeepCopyable other)
{
Expand All @@ -3697,7 +3697,7 @@ public override IDeepCopyable CopyTo(IDeepCopyable other)
base.CopyTo(dest);
if(CompleteElement != null) dest.CompleteElement = (Hl7.Fhir.Model.FhirBoolean)CompleteElement.DeepCopy();
if(Entry.Any()) dest.Entry = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>(Entry.DeepCopy());
if(Summary.Any()) dest.Summary = new List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>(Summary.DeepCopy());
if(Summary.Any()) dest.Summary = new List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>(Summary.DeepCopy());
return dest;
}

Expand Down Expand Up @@ -3763,7 +3763,7 @@ internal protected override Base SetValue(string key, object value)
Entry = (List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipEntryComponent>)value;
return this;
case "summary":
Summary = (List<Hl7.Fhir.Model.Citation.CitedArtifactContributorshipSummaryComponent>)value;
Summary = (List<Hl7.Fhir.Model.Citation.ContributorshipSummaryComponent>)value;
return this;
default:
return base.SetValue(key, value);
Expand Down Expand Up @@ -4263,7 +4263,7 @@ internal protected override IEnumerable<KeyValuePair<string, object>> GetElement
[Serializable]
[DataContract]
[FhirType("Citation.citedArtifact.contributorship.summary", IsBackboneType=true)]
public partial class CitedArtifactContributorshipSummaryComponent : Hl7.Fhir.Model.BackboneElement
public partial class ContributorshipSummaryComponent : Hl7.Fhir.Model.BackboneElement
{
/// <summary>
/// FHIR Type Name
Expand Down Expand Up @@ -4346,7 +4346,7 @@ public string Value

public override IDeepCopyable CopyTo(IDeepCopyable other)
{
var dest = other as CitedArtifactContributorshipSummaryComponent;
var dest = other as ContributorshipSummaryComponent;

if (dest == null)
{
Expand All @@ -4363,13 +4363,13 @@ public override IDeepCopyable CopyTo(IDeepCopyable other)

public override IDeepCopyable DeepCopy()
{
return CopyTo(new CitedArtifactContributorshipSummaryComponent());
return CopyTo(new ContributorshipSummaryComponent());
}

///<inheritdoc />
public override bool Matches(IDeepComparable other)
{
var otherT = other as CitedArtifactContributorshipSummaryComponent;
var otherT = other as ContributorshipSummaryComponent;
if(otherT == null) return false;

if(!base.Matches(otherT)) return false;
Expand All @@ -4383,7 +4383,7 @@ public override bool Matches(IDeepComparable other)

public override bool IsExactly(IDeepComparable other)
{
var otherT = other as CitedArtifactContributorshipSummaryComponent;
var otherT = other as ContributorshipSummaryComponent;
if(otherT == null) return false;

if(!base.IsExactly(otherT)) return false;
Expand Down

0 comments on commit fcfb244

Please sign in to comment.