Class: Tc211::Termbase::Glossarist::Concept
- Inherits:
-
Glossarist::LocalizedConcept
- Object
- Glossarist::LocalizedConcept
- Tc211::Termbase::Glossarist::Concept
- Defined in:
- lib/tc211/termbase/glossarist/concept.rb
Instance Attribute Summary collapse
-
#dateAccepted ⇒ Object
Returns the value of attribute dateAccepted.
-
#status ⇒ Object
Returns the value of attribute status.
Instance Method Summary collapse
Instance Attribute Details
#dateAccepted ⇒ Object
Returns the value of attribute dateAccepted.
5 6 7 |
# File 'lib/tc211/termbase/glossarist/concept.rb', line 5 def dateAccepted @dateAccepted end |
#status ⇒ Object
Returns the value of attribute status.
5 6 7 |
# File 'lib/tc211/termbase/glossarist/concept.rb', line 5 def status @status end |
Instance Method Details
#register_info ⇒ Object
21 22 23 24 25 26 27 28 29 |
# File 'lib/tc211/termbase/glossarist/concept.rb', line 21 def register_info date_accepted = dates.find(&:accepted?) { "dateAccepted" => date_accepted&.date&.dup, "id" => uuid, "status" => entry_status, }.compact end |
#to_h(only_data: false) ⇒ Object
14 15 16 17 18 19 |
# File 'lib/tc211/termbase/glossarist/concept.rb', line 14 def to_h(only_data: false) data_hash = super() return data_hash if only_data data_hash.merge(register_info) end |
#uuid ⇒ Object
7 8 9 10 11 12 |
# File 'lib/tc211/termbase/glossarist/concept.rb', line 7 def uuid @uuid ||= ::Glossarist::Utilities::UUID.uuid_v5( ::Glossarist::Utilities::UUID::OID_NAMESPACE, to_h(only_data: true).to_yaml, ) end |