Class: FuzzyFileFinder::CharacterRun

Inherits:
Struct
  • Object
show all
Defined in:
lib/diakonos/vendor/fuzzy_file_finder.rb

Overview

Used internally to represent a run of characters within a match. This is used to build the highlighted version of a file name.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#insideObject

Returns the value of attribute inside

Returns:

  • (Object)

    the current value of inside



46
47
48
# File 'lib/diakonos/vendor/fuzzy_file_finder.rb', line 46

def inside
  @inside
end

#stringObject

Returns the value of attribute string

Returns:

  • (Object)

    the current value of string



46
47
48
# File 'lib/diakonos/vendor/fuzzy_file_finder.rb', line 46

def string
  @string
end

Instance Method Details

#to_sObject



47
48
49
50
51
52
53
# File 'lib/diakonos/vendor/fuzzy_file_finder.rb', line 47

def to_s
  if inside
    "(#{string})"
  else
    string
  end
end