Class: ThinkingSphinx::ActiveRecord::Association

Inherits:
Object
  • Object
show all
Defined in:
lib/thinking_sphinx/active_record/association.rb

Instance Method Summary collapse

Constructor Details

#initialize(column) ⇒ Association

Returns a new instance of Association.



4
5
6
# File 'lib/thinking_sphinx/active_record/association.rb', line 4

def initialize(column)
  @column = column
end

Instance Method Details

#stackObject



8
9
10
# File 'lib/thinking_sphinx/active_record/association.rb', line 8

def stack
  @column.__stack + [@column.__name]
end

#string?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/thinking_sphinx/active_record/association.rb', line 12

def string?
  @column.is_a?(String)
end

#to_sObject



16
17
18
# File 'lib/thinking_sphinx/active_record/association.rb', line 16

def to_s
  @column.to_s
end