Class: Citation_event_type_record

Inherits:
GEDCOMBase show all
Defined in:
lib/gedcom/citation_event_type_record.rb

Overview

Source_citation_record has an EVEN tag. This is not an Event_record, but the event type that the source record records.

=SOURCE_CITATION:= (within another record, referencing a SOURCE_RECORD) -1 SOUR @<XREF:SOUR>@ 1:1 (pointer to source record) … n EVEN <EVENT_TYPE_CITED_FROM> 0:1 +1 ROLE <ROLE_IN_EVENT> 0:1 …

==EVENT_TYPE_CITED_FROM:= SIZE=1:15 <EVENT_ATTRIBUTE_TYPE>

A code that indicates the type of event which was responsible for the source entry being recorded. For example, if the entry was created to record a birth of a child, then the type would be BIRT regardless of the assertions made from that record, such as the mother's name or mother's birth date. This will allow a prioritized best view choice and a determination of the certainty associated with the source used in asserting the cited fact.

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

Attributes inherited from GEDCOMBase

#restriction

Instance Method Summary collapse

Methods inherited from GEDCOMBase

#changed, #changed?, #created?, #find, #locked?, no_tabs, #private?, #save, tabs, #to_db, #to_gedcom, #to_s, #to_s_ordered, #to_s_r, #token_to_s, #xref_check

Constructor Details

#initialize(*a) ⇒ Citation_event_type_record

new sets up the state engine arrays @this_level and @sub_level, which drive the to_gedcom method generating GEDCOM output.



33
34
35
36
37
38
39
40
# File 'lib/gedcom/citation_event_type_record.rb', line 33

def initialize(*a)
  super(*a)
  @this_level = [ [:print, "EVEN", :event_type ] ]
  @sub_level =  [ #level 1
                  [:print, "ROLE", :role],
                  [:walk, nil,    :note_citation_record ],
                ]
end

Instance Attribute Details

#event_typeObject

Returns the value of attribute event_type.



27
28
29
# File 'lib/gedcom/citation_event_type_record.rb', line 27

def event_type
  @event_type
end

#note_citation_recordObject

Returns the value of attribute note_citation_record.



28
29
30
# File 'lib/gedcom/citation_event_type_record.rb', line 28

def note_citation_record
  @note_citation_record
end

#roleObject

Returns the value of attribute role.



27
28
29
# File 'lib/gedcom/citation_event_type_record.rb', line 27

def role
  @role
end