class HecksAdapters::SQLDatabase::JoinTable
Represents a SQL Table
with information about object references
Public Class Methods
new(table, column)
click to toggle source
# File lib/join_table.rb, line 5 def initialize(table, column) @table = table @column = column end
Public Instance Methods
columns()
click to toggle source
# File lib/join_table.rb, line 14 def columns [@table.name, @column.name].map do |name| Column.new(name: name.singularize + '_id', type: 'String') end end
name()
click to toggle source
# File lib/join_table.rb, line 10 def name "#{@table.name}_#{@column.name}" end