Class: Packr::Words::Item

Inherits:
Object
  • Object
show all
Defined in:
lib/packr/words.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(word, item) ⇒ Item

Returns a new instance of Item.



25
26
27
28
29
30
# File 'lib/packr/words.rb', line 25

def initialize(word, item)
  @word = word
  @index = 0
  @count = 0
  @encoded = ""
end

Instance Attribute Details

#countObject

Returns the value of attribute count.



23
24
25
# File 'lib/packr/words.rb', line 23

def count
  @count
end

#encodedObject

Returns the value of attribute encoded.



23
24
25
# File 'lib/packr/words.rb', line 23

def encoded
  @encoded
end

#indexObject

Returns the value of attribute index.



23
24
25
# File 'lib/packr/words.rb', line 23

def index
  @index
end

#replacementObject

Returns the value of attribute replacement.



23
24
25
# File 'lib/packr/words.rb', line 23

def replacement
  @replacement
end

Instance Method Details

#to_sObject



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

def to_s
  @word
end