Exception: Myaso::UnknownWord

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/myaso.rb

Overview

The UnknownWord exception is raised when Tagger considers an unknown word.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(word) ⇒ UnknownWord

Returns a new instance of UnknownWord.


27
28
29
# File 'lib/myaso.rb', line 27

def initialize(word)
  @word = word
end

Instance Attribute Details

#wordObject (readonly)

Returns the value of attribute word


24
25
26
# File 'lib/myaso.rb', line 24

def word
  @word
end

Instance Method Details

#to_sObject


32
33
34
# File 'lib/myaso.rb', line 32

def to_s
  'unknown word "%s"' % word
end