Class: Interscript::Mapping
- Inherits:
-
Object
- Object
- Interscript::Mapping
- Defined in:
- lib/interscript/mapping.rb
Instance Attribute Summary collapse
-
#authority_id ⇒ Object
readonly
Returns the value of attribute authority_id.
-
#chain ⇒ Object
readonly
Returns the value of attribute chain.
-
#character_separator ⇒ Object
readonly
Returns the value of attribute character_separator.
-
#characters ⇒ Object
readonly
Returns the value of attribute characters.
-
#characters_hash ⇒ Object
readonly
Returns the value of attribute characters_hash.
-
#creation_date ⇒ Object
readonly
Returns the value of attribute creation_date.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#destination_script ⇒ Object
readonly
Returns the value of attribute destination_script.
-
#dictionary ⇒ Object
readonly
Returns the value of attribute dictionary.
-
#dictionary_hash ⇒ Object
readonly
Returns the value of attribute dictionary_hash.
-
#dictionary_trie ⇒ Object
readonly
Returns the value of attribute dictionary_trie.
-
#downcase ⇒ Object
readonly
Returns the value of attribute downcase.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#language ⇒ Object
readonly
Returns the value of attribute language.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#notes ⇒ Object
readonly
Returns the value of attribute notes.
-
#postrules ⇒ Object
readonly
Returns the value of attribute postrules.
-
#rules ⇒ Object
readonly
Returns the value of attribute rules.
-
#segmentation ⇒ Object
readonly
Returns the value of attribute segmentation.
-
#source_script ⇒ Object
readonly
Returns the value of attribute source_script.
-
#tests ⇒ Object
readonly
Returns the value of attribute tests.
-
#title_case ⇒ Object
readonly
Returns the value of attribute title_case.
-
#transcription ⇒ Object
readonly
Returns the value of attribute transcription.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
-
#word_separator ⇒ Object
readonly
Returns the value of attribute word_separator.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(system_code, options = {}) ⇒ Mapping
constructor
A new instance of Mapping.
- #load_and_serialize_system_mappings ⇒ Object
Constructor Details
#initialize(system_code, options = {}) ⇒ Mapping
Returns a new instance of Mapping.
35 36 37 38 39 40 41 |
# File 'lib/interscript/mapping.rb', line 35 def initialize(system_code, = {}) @system_code = system_code @depth = .fetch(:depth, 0).to_i @system_path = .fetch(:system_code, default_path) load_and_serialize_system_mappings end |
Instance Attribute Details
#authority_id ⇒ Object (readonly)
Returns the value of attribute authority_id.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def @authority_id end |
#chain ⇒ Object (readonly)
Returns the value of attribute chain.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def chain @chain end |
#character_separator ⇒ Object (readonly)
Returns the value of attribute character_separator.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def character_separator @character_separator end |
#characters ⇒ Object (readonly)
Returns the value of attribute characters.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def characters @characters end |
#characters_hash ⇒ Object (readonly)
Returns the value of attribute characters_hash.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def characters_hash @characters_hash end |
#creation_date ⇒ Object (readonly)
Returns the value of attribute creation_date.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def creation_date @creation_date end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def description @description end |
#destination_script ⇒ Object (readonly)
Returns the value of attribute destination_script.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def destination_script @destination_script end |
#dictionary ⇒ Object (readonly)
Returns the value of attribute dictionary.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def dictionary @dictionary end |
#dictionary_hash ⇒ Object (readonly)
Returns the value of attribute dictionary_hash.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def dictionary_hash @dictionary_hash end |
#dictionary_trie ⇒ Object (readonly)
Returns the value of attribute dictionary_trie.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def dictionary_trie @dictionary_trie end |
#downcase ⇒ Object (readonly)
Returns the value of attribute downcase.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def downcase @downcase end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def id @id end |
#language ⇒ Object (readonly)
Returns the value of attribute language.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def language @language end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def name @name end |
#notes ⇒ Object (readonly)
Returns the value of attribute notes.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def notes @notes end |
#postrules ⇒ Object (readonly)
Returns the value of attribute postrules.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def postrules @postrules end |
#rules ⇒ Object (readonly)
Returns the value of attribute rules.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def rules @rules end |
#segmentation ⇒ Object (readonly)
Returns the value of attribute segmentation.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def segmentation @segmentation end |
#source_script ⇒ Object (readonly)
Returns the value of attribute source_script.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def source_script @source_script end |
#tests ⇒ Object (readonly)
Returns the value of attribute tests.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def tests @tests end |
#title_case ⇒ Object (readonly)
Returns the value of attribute title_case.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def title_case @title_case end |
#transcription ⇒ Object (readonly)
Returns the value of attribute transcription.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def transcription @transcription end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def url @url end |
#word_separator ⇒ Object (readonly)
Returns the value of attribute word_separator.
7 8 9 |
# File 'lib/interscript/mapping.rb', line 7 def word_separator @word_separator end |
Class Method Details
.for(system_code, options = {}) ⇒ Object
43 44 45 |
# File 'lib/interscript/mapping.rb', line 43 def self.for(system_code, = {}) new(system_code, ) end |
Instance Method Details
#load_and_serialize_system_mappings ⇒ Object
47 48 49 50 51 52 |
# File 'lib/interscript/mapping.rb', line 47 def load_and_serialize_system_mappings if depth < 5 mappings = load_system_mappings serialize_system_mappings(mappings) end end |