Class: TimePatterns::SymbToken

Inherits:
Object
  • Object
show all
Defined in:
lib/todo_time_patterns/tokens.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value, start_index) ⇒ SymbToken

Returns a new instance of SymbToken.



36
37
38
39
# File 'lib/todo_time_patterns/tokens.rb', line 36

def initialize(value, start_index)
  @value = value
  @start_index = start_index
end

Instance Attribute Details

#start_indexObject (readonly)

Returns the value of attribute start_index.



34
35
36
# File 'lib/todo_time_patterns/tokens.rb', line 34

def start_index
  @start_index
end

#valueObject (readonly)

Returns the value of attribute value.



33
34
35
# File 'lib/todo_time_patterns/tokens.rb', line 33

def value
  @value
end

Instance Method Details

#to_sObject



41
42
43
# File 'lib/todo_time_patterns/tokens.rb', line 41

def to_s
  "{symbol}"
end