Class: Termium::Abbreviation
- Inherits:
-
Shale::Mapper
- Object
- Shale::Mapper
- Termium::Abbreviation
- Includes:
- DesignationOperations
- Defined in:
- lib/termium/abbreviation.rb
Overview
For <abbreviation>
Constant Summary
Constants included from DesignationOperations
DesignationOperations::GENDER_CODE_MAPPING, DesignationOperations::PART_OF_SPEECH_CODE_MAPPING
Instance Method Summary collapse
Methods included from DesignationOperations
Instance Method Details
#deprecated ⇒ Object
30 31 32 |
# File 'lib/termium/abbreviation.rb', line 30 def deprecated parameter.map(&:abbreviation).include?("AE") end |
#to_h ⇒ Object
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/termium/abbreviation.rb', line 34 def to_h set = { "designation" => value, "type" => "abbreviation", "normative_status" => deprecated ? "deprecated" : "preferred" } # if geographical_area # set["geographical_area"] = geographical_area # end # if plurality # set["plurality"] = plurality # end set["gender"] = gender if gender set["part_of_speech"] = part_of_speech if part_of_speech set end |