Class: Yanagi::Result

Inherits:
Struct
  • Object
show all
Defined in:
lib/yanagi/cyrillic.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#confidenceObject

Returns the value of attribute confidence

Returns:

  • (Object)

    the current value of confidence



8
9
10
# File 'lib/yanagi/cyrillic.rb', line 8

def confidence
  @confidence
end

#notesObject

Returns the value of attribute notes

Returns:

  • (Object)

    the current value of notes



8
9
10
# File 'lib/yanagi/cyrillic.rb', line 8

def notes
  @notes
end

#sourceObject

Returns the value of attribute source

Returns:

  • (Object)

    the current value of source



8
9
10
# File 'lib/yanagi/cyrillic.rb', line 8

def source
  @source
end

#textObject

Returns the value of attribute text

Returns:

  • (Object)

    the current value of text



8
9
10
# File 'lib/yanagi/cyrillic.rb', line 8

def text
  @text
end

Instance Method Details

#==(other) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/yanagi/cyrillic.rb', line 17

def ==(other)
  if other.is_a?(String)
    text == other
  else
    super
  end
end

#inspectObject



25
26
27
# File 'lib/yanagi/cyrillic.rb', line 25

def inspect
  "#<Yanagi::Result text=#{text.inspect} source=#{source.inspect} confidence=#{confidence.inspect}>"
end

#to_sObject



9
10
11
# File 'lib/yanagi/cyrillic.rb', line 9

def to_s
  text.to_s
end

#to_strObject



13
14
15
# File 'lib/yanagi/cyrillic.rb', line 13

def to_str
  text.to_s
end