suppress debug messaging if instructed and control lazy loading
This commit is contained in:
parent
7f74b4521a
commit
b5d828b0dc
|
@ -408,6 +408,13 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
|
|
||||||
public interface ProfileKnowledgeProvider {
|
public interface ProfileKnowledgeProvider {
|
||||||
class BindingResolution {
|
class BindingResolution {
|
||||||
|
public BindingResolution(String display, String url) {
|
||||||
|
this.display = display;
|
||||||
|
this.url = url;
|
||||||
|
}
|
||||||
|
public BindingResolution() {
|
||||||
|
// TODO Auto-generated constructor stub
|
||||||
|
}
|
||||||
public String display;
|
public String display;
|
||||||
public String url;
|
public String url;
|
||||||
}
|
}
|
||||||
|
@ -735,6 +742,7 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
}
|
}
|
||||||
if (!Utilities.noString(b.toString())) {
|
if (!Utilities.noString(b.toString())) {
|
||||||
String msg = "The profile "+derived.getUrl()+" has "+ce+" "+Utilities.pluralize("element", ce)+" in the differential ("+b.toString()+") that don't have a matching element in the snapshot: check that the path and definitions are legal in the differential (including order)";
|
String msg = "The profile "+derived.getUrl()+" has "+ce+" "+Utilities.pluralize("element", ce)+" in the differential ("+b.toString()+") that don't have a matching element in the snapshot: check that the path and definitions are legal in the differential (including order)";
|
||||||
|
if (debug) {
|
||||||
System.out.println("Error in snapshot generation: "+msg);
|
System.out.println("Error in snapshot generation: "+msg);
|
||||||
if (!debug) {
|
if (!debug) {
|
||||||
System.out.println("Differential: ");
|
System.out.println("Differential: ");
|
||||||
|
@ -744,6 +752,7 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
for (ElementDefinition ed : derived.getSnapshot().getElement())
|
for (ElementDefinition ed : derived.getSnapshot().getElement())
|
||||||
System.out.println(" "+ed.getId()+" = "+ed.getPath()+" : "+typeSummaryWithProfile(ed)+"["+ed.getMin()+".."+ed.getMax()+"]"+sliceSummary(ed)+" "+constraintSummary(ed));
|
System.out.println(" "+ed.getId()+" = "+ed.getPath()+" : "+typeSummaryWithProfile(ed)+"["+ed.getMin()+".."+ed.getMax()+"]"+sliceSummary(ed)+" "+constraintSummary(ed));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (exception)
|
if (exception)
|
||||||
throw new DefinitionException(msg);
|
throw new DefinitionException(msg);
|
||||||
else
|
else
|
||||||
|
@ -2507,9 +2516,13 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
generateSnapshot(context.fetchTypeDefinition("Extension"), sd, sd.getUrl(), webUrl, sd.getName());
|
generateSnapshot(context.fetchTypeDefinition("Extension"), sd, sd.getUrl(), webUrl, sd.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (sd == null)
|
if (sd == null) {
|
||||||
|
if (debug) {
|
||||||
System.out.println("Failed to find referenced profile: " + type.getProfile());
|
System.out.println("Failed to find referenced profile: " + type.getProfile());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
if (sd == null)
|
if (sd == null)
|
||||||
sd = context.fetchTypeDefinition(type.getWorkingCode());
|
sd = context.fetchTypeDefinition(type.getWorkingCode());
|
||||||
if (sd == null)
|
if (sd == null)
|
||||||
|
@ -6694,8 +6707,9 @@ public class ProfileUtilities extends TranslatingUtilities {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void setNewSlicingProcessing(boolean newSlicingProcessing) {
|
public ProfileUtilities setNewSlicingProcessing(boolean newSlicingProcessing) {
|
||||||
this.newSlicingProcessing = newSlicingProcessing;
|
this.newSlicingProcessing = newSlicingProcessing;
|
||||||
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue