Class: Header_source_record
- Inherits:
-
GEDCOMBase
- Object
- GEDCOMBase
- Header_source_record
- Defined in:
- lib/gedcom/header_source_record.rb
Overview
Internal representation of the GEDCOM SOUR record in a level 0 HEAD record. These SOUR records are not the same as level 0 SOUR records.
HEADER:=
0 HEAD {1:1}
1 SOUR <APPROVED_SYSTEM_ID> {1:1}
+1 VERS <VERSION_NUMBER> {0:1}
+1 NAME <NAME_OF_PRODUCT> {0:1}
+1 CORP <NAME_OF_BUSINESS> {0:1}
+2 <<ADDRESS_STRUCTURE>> {0:1}
+1 DATA <NAME_OF_SOURCE_DATA> {0:1}
+2 DATE <PUBLICATION_DATE> {0:1}
+2 COPR <COPYRIGHT_SOURCE_DATA> {0:1}
...
The SOURce system name identifies which system sent the data.
The attributes are all arrays for the level +1 tags/records.
-
Those ending in _ref are GEDCOM XREF index keys
-
Those ending in _record are array of classes of that type.
-
The remainder are arrays of attributes that could be present in this record.
Instance Attribute Summary collapse
-
#approved_system_id ⇒ Object
Returns the value of attribute approved_system_id.
-
#corporate_record ⇒ Object
Returns the value of attribute corporate_record.
-
#header_data_record ⇒ Object
Returns the value of attribute header_data_record.
-
#name ⇒ Object
Returns the value of attribute name.
-
#note_citation_record ⇒ Object
Returns the value of attribute note_citation_record.
-
#version ⇒ Object
Returns the value of attribute version.
Attributes inherited from GEDCOMBase
Instance Method Summary collapse
-
#initialize(*a) ⇒ Header_source_record
constructor
new sets up the state engine arrays @this_level and @sub_level, which drive the to_gedcom method generating GEDCOM output.
Methods inherited from GEDCOMBase
#changed, #changed?, #created?, #find, #locked?, no_tabs, #private?, #save, tabs, #to_db, #to_gedcom, #to_s, #token_to_s
Constructor Details
#initialize(*a) ⇒ Header_source_record
new sets up the state engine arrays @this_level and @sub_level, which drive the to_gedcom method generating GEDCOM output.
31 32 33 34 35 36 37 38 39 40 41 |
# File 'lib/gedcom/header_source_record.rb', line 31 def initialize(*a) super(*a) @this_level = [ [:print, "SOUR", :approved_system_id] ] @sub_level = [ #level + 1 [:print, "VERS", :version], [:print, "NAME", :name], [:walk, nil, :corporate_record], [:walk, nil, :header_data_record], [:walk, nil, :note_citation_record], ] end |
Instance Attribute Details
#approved_system_id ⇒ Object
Returns the value of attribute approved_system_id.
25 26 27 |
# File 'lib/gedcom/header_source_record.rb', line 25 def approved_system_id @approved_system_id end |
#corporate_record ⇒ Object
Returns the value of attribute corporate_record.
25 26 27 |
# File 'lib/gedcom/header_source_record.rb', line 25 def corporate_record @corporate_record end |
#header_data_record ⇒ Object
Returns the value of attribute header_data_record.
25 26 27 |
# File 'lib/gedcom/header_source_record.rb', line 25 def header_data_record @header_data_record end |
#name ⇒ Object
Returns the value of attribute name.
25 26 27 |
# File 'lib/gedcom/header_source_record.rb', line 25 def name @name end |
#note_citation_record ⇒ Object
Returns the value of attribute note_citation_record.
26 27 28 |
# File 'lib/gedcom/header_source_record.rb', line 26 def note_citation_record @note_citation_record end |
#version ⇒ Object
Returns the value of attribute version.
25 26 27 |
# File 'lib/gedcom/header_source_record.rb', line 25 def version @version end |