[% INCLUDE header.tmpl %]

[% ontology_name %]: Ontology Comparison Report

Files used:

  • file 1 (old): [% f1_file_data %]
  • file 2 (new): [% f2_file_data %]
[% IF no_ontology_changes %]

No ontology changes found.

[% ELSE %]

New terms

[% IF f2_only %] [% FOREACH t IN f2_only.keys.sort %] [% END %]
ID name namespace
[% IF primary.url_prefix %][% t %][% ELSE %][% t %][% END %] [% IF primary.url_prefix %][% f2_term_hash.$t.name.0 %][% ELSE %][% f2_term_hash.$t.name.0 %][% END %] [% f2_term_hash.$t.namespace.0 || '' %]
[% ELSE %]

None

[% END %]

Obsoletions

[% IF f2_obsoletes %] [% FOREACH t IN f2_obsoletes.keys.sort %] [% END %]
ID name namespace
[% IF primary.url_prefix %][% t %][% ELSE %][% t %][% END %] [% IF primary.url_prefix %][% f2_term_hash.$t.name.0 %][% ELSE %][% f2_term_hash.$t.name.0 %][% END %] [% IF level == 'l'; IF f2_term_hash.$t.replaced_by; '
Replaced by: ' _ f2_term_hash.$t.replaced_by.join(", "); END; IF f2_term_hash.$t.consider; '
Consider: ' _ f2_term_hash.$t.consider.join(", "); END; IF f2_term_hash.$t.comment; '
' _ f2_term_hash.$t.comment.0; END; END %]
[% f1_term_hash.$t.namespace.0 || '' %]
[% ELSE %]

None

[% END %]

Term merges

[% IF f1_to_f2_merge %] [% FOREACH t IN f1_to_f2_merge.keys.sort; merge = f1_to_f2_merge.$t %] [% END %]
Old ID Old name Merged into Merged term name
[% t %][% f1_term_hash.$t.name.0 %][% merge %][% f2_term_hash.$merge.name.0 %]
[% ELSE %]

None

[% END %]

Term changes

[% IF ! term_changes %]

None

[% ELSIF level == 's' %]

[% term_changes.size %] terms edited.

[% ELSIF level == 'm' %]

KEY: 'A' : added, 'D' : deleted, 'C' : changed (for properties with only one value)

[% FOREACH a IN term_change_attribs; %] [% END %] [% IF term_changes.size > 10 %] [% FOREACH a IN term_change_attribs %] [% END %] [% END %] [% FOREACH t IN term_changes.keys.sort %] [% FOREACH a IN term_change_attribs %] [% END; ## end FOREACH a IN term_change_attribs %] [% END; ## end FOREACH t IN term_changes.keys.sort; %]
Changes in term-related data
Term ID[% a %]
Term ID[% a %]
[% IF primary.url_prefix; %][% t %]
[% f2_term_hash.$t.name.0 %]
[% ELSE; %][% t %]
[% f2_term_hash.$t.name.0 %][% END; %]
[% IF term_changes.$t.$a; IF single_value_attribs.$a; IF full_details; IF term_changes.$t.$a.f1; %][% term_changes.$t.$a.f1.0 %][% END; IF term_changes.$t.$a.f1 && term_changes.$t.$a.f2; '
'; END; IF term_changes.$t.$a.f2; %][% term_changes.$t.$a.f2.0 %][% END; ELSE; ## ! full_details IF term_changes.$t.$a.f1 && term_changes.$t.$a.f2; %]C[% ELSIF term_changes.$t.$a.f1; %]D[% ELSIF term_changes.$t.$a.f2; %]A[% END; END; ELSE; # not single value attrib IF full_details; IF term_changes.$t.$a.f1; %][% term_changes.$t.$a.f1.join('
') %] [% END; IF term_changes.$t.$a.f1 && term_changes.$t.$a.f2; '
'; END; IF term_changes.$t.$a.f2; %][% term_changes.$t.$a.f2.join('
') %] [% END; ELSE; ## ! full_details txt = ""; title = a _ ": "; IF term_changes.$t.$a.f1; txt = txt _ term_changes.$t.$a.f1.size _ " D"; title = title _ term_changes.$t.$a.f1.size _ " removed"; END; IF term_changes.$t.$a.f1 && term_changes.$t.$a.f2; txt = txt _ ', '; title = title _ ', '; END; IF term_changes.$t.$a.f2; txt = txt _ term_changes.$t.$a.f2.size _ " A"; title = title _ term_changes.$t.$a.f2.size _ " added"; END; %][% txt %][% END; END; ELSE; ## no term_changes %] [% END; %]
[% ELSE; # level = 'l', two_col_layout %]
Changes in term-related data
File 1 ([% f1_date || 'date unknown' %], [% f1_cvs || 'CVS revision unknown' %]) File 2 ([% f2_date || 'date unknown' %], [% f2_cvs || 'CVS revision unknown' %])
[% FOREACH t IN term_changes.keys.sort %]
[% IF primary.url_prefix; %][% t %] : [% f2_term_hash.$t.name.0 %][% ELSE; %][% t %] : [% f2_term_hash.$t.name.0 %][% END; %]
[% FOREACH a IN term_change_attribs; IF term_changes.$t.$a; IF term_changes.$t.$a.f1; '' _ a _ '
'; IF single_value_attribs.$a; '' _ term_changes.$t.$a.f1.0 _ '
'; ELSE; # not single value attrib '' _ term_changes.$t.$a.f1.sort.join('
') _ '
'; END; END; END; END; %]
[% FOREACH a IN term_change_attribs; IF term_changes.$t.$a; IF term_changes.$t.$a.f2; '' _ a _ '
'; IF single_value_attribs.$a; '' _ term_changes.$t.$a.f2.0 _ '
'; ELSE; # not single value attrib '' _ term_changes.$t.$a.f2.sort.join('
') _ '
'; END; END; END; END; ## end FOREACH a IN term_change_attribs %]
[% END; ## end FOREACH t IN term_changes.keys.sort; %] [% END; %]
[% IF other && (other.f2_only || other.f1_only || other.both); %]

Other Stanza Types

[% IF other.f2_only %]

New Stanzas

[% FOREACH s_type IN other.f2_only.keys.sort; FOREACH t IN other.f2_only.$s_type.keys.sort %] [% END; END %]
Stanza type ID name
[% s_type %] [% t %] [% other.f2_only.$s_type.$t.name || '' %]
[% END %] [% IF other.f1_only %]

Stanzas removed

[% FOREACH s_type IN other.f1_only.keys.sort; FOREACH t IN other.f1_only.$s_type.keys.sort %] [% END; END %]
Stanza type ID name
[% s_type %] [% t %] [% other.f1_only.$s_type.$t.name || '' %]
[% END %] [% IF other.both %]

Stanzas Edited

[% FOREACH s_type IN other.both.keys.sort; FOREACH t IN other.both.$s_type.keys.sort %] [% END; END %]
Stanza type ID name
[% s_type %] [% t %] [% other.both.$s_type.$t.name || '' %]
[% END %]
[% END; %]

File Stats

[% sign = '+'; FOREACH o IN ontology_list.keys %] [% END %]
Term counts for the old and new files
Ontology Old file New file Change
[% o.replace('_', ' ') %] [% IF f1_stats.by_ns.$o %] [% f1_stats.by_ns.$o.total %]
[% f1_stats.by_ns.$o.def %] ([% f1_stats.by_ns.$o.def_percent %]%) defined [% ELSE %] - [% END %]
[% IF f2_stats.by_ns.$o %] [% f2_stats.by_ns.$o.total %]
[% f2_stats.by_ns.$o.def %] ([% f2_stats.by_ns.$o.def_percent %]%) defined [% ELSE %] - [% END %]
[% IF delta.$o > 0; sign ; END; delta.$o %]
Obsolete [% f1_stats.obs %]
([% f1_stats.obs_percent %]% of total)
[% f2_stats.obs %]
([% f2_stats.obs_percent %]% of total)
[% IF delta.obs > 0; sign; END; delta.obs %] ([% IF delta.obs_percent > 0; sign; END; delta.obs_percent %]%)
Totals [% f1_stats.extant %]
[% f1_stats.def_not_obs %] ([% f1_stats.def_extant_percent %]%) defined
[% f1_stats.total %] inc. obsoletes
[% f2_stats.extant %]
[% f2_stats.def_not_obs %] ([% f2_stats.def_extant_percent %]%) defined
[% f2_stats.total %] inc. obsoletes
[% IF delta.total > 0; sign; END; delta.total %] ([% IF delta.total_percent > 0; sign; END; delta.total_percent %]%)
[% IF f1_only || f1_obsoletes || f1_to_f2_split %]

File Errors

[% IF f1_only %]

Terms lost

[% FOREACH t IN f1_only.keys.sort %] [% END %]
ID name namespace
[% t %] [% f1_term_hash.$t.name.0 %] [% f1_term_hash.$t.namespace.0 || '' %]
[% END; IF f1_obsoletes %]

Terms resurrected from obsolete-dom

[% FOREACH t IN f1_obsoletes.keys.sort %] [% END %]
ID name namespace
[% t %][% f2_term_hash.$t.name.0 %][% (f2_term_hash.$t.namespace.0 || 'unknown' ) %]
[% END; IF f1_to_f2_split %]

Term splits

[% FOREACH t IN f1_to_f2_split.keys.sort; split = f1_to_f2_split.$t %] [% END %]
Source term ID Source term name Split term ID Split term name
[% split %][% f1_term_hash.$split.name.0 %][% t %][% f2_term_hash.$t.name.0 %]
[% END %]
[% END %] [% END; ## end no_ontology_changes %] [% IF report_info_url %]

Ontology report info

[% END %]
[% INCLUDE footer.tmpl %]