Class: LLT::Form::Preposition

Inherits:
Uninflectable show all
Defined in:
lib/llt/form/preposition.rb

Instance Attribute Summary

Attributes inherited from LLT::Form

#casus, #classification, #comparison_sign, #ending, #extension, #genus, #index, #inflection_class, #modus, #numerus, #particle, #persona, #place, #prefix, #sexus, #stem, #stems, #string, #suffix, #tempus

Instance Method Summary collapse

Methods inherited from Uninflectable

#initialize, #segments, #stem

Methods inherited from LLT::Form

#functions, #init_functions, #initialize, #segmentized, #to_s

Constructor Details

This class inherits a constructor from LLT::Form::Uninflectable

Instance Method Details

#init_keysObject



4
5
6
# File 'lib/llt/form/preposition.rb', line 4

def init_keys
  i{ string takes_4th takes_6th }
end

#needs?(arg) ⇒ Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/llt/form/preposition.rb', line 12

def needs?(arg)
  valency.include?(arg)
end

#takes_4th?Boolean

Returns:

  • (Boolean)


23
24
25
# File 'lib/llt/form/preposition.rb', line 23

def takes_4th?
  @takes_4th
end

#takes_6th?Boolean

Returns:

  • (Boolean)


27
28
29
# File 'lib/llt/form/preposition.rb', line 27

def takes_6th?
  @takes_6th
end

#valenciesObject



16
17
18
19
20
21
# File 'lib/llt/form/preposition.rb', line 16

def valencies
  v = []
  v << 4 if @takes_4th
  v << 6 if @takes_6th
  v
end

#valencyObject



8
9
10
# File 'lib/llt/form/preposition.rb', line 8

def valency
  @valency ||= valencies
end