Class: LLT::Morphologizer::StemLookupStatementBuilder::ContractedForms::Contraction

Inherits:
Object
  • Object
show all
Defined in:
lib/llt/morphologizer/stem_lookup_statement_builder/contracted_forms.rb

Instance Method Summary collapse

Constructor Details

#initialize(position, contraction) ⇒ Contraction

Returns a new instance of Contraction.



24
25
26
27
# File 'lib/llt/morphologizer/stem_lookup_statement_builder/contracted_forms.rb', line 24

def initialize(position, contraction)
  @position    = position
  @contraction = contraction
end

Instance Method Details

#empty?Boolean

Returns:

  • (Boolean)


29
30
31
32
# File 'lib/llt/morphologizer/stem_lookup_statement_builder/contracted_forms.rb', line 29

def empty?
  # duck type, fulfilling the contract of the other component strings
  false
end

#to_sObject



34
35
36
# File 'lib/llt/morphologizer/stem_lookup_statement_builder/contracted_forms.rb', line 34

def to_s
  "#{@contraction} contracted at #{@position}"
end