class DMap::Associations::HasMany

Attributes

associations[RW]

Public Class Methods

associations() click to toggle source
# File lib/dmap/associations/hasn.rb, line 32
def self.associations; true; end
field() click to toggle source
# File lib/dmap/associations/hasn.rb, line 38
def self.field
  "has n, "
end
is_valid?(command=nil) click to toggle source
# File lib/dmap/associations/hasn.rb, line 42
def self.is_valid?(command=nil)
  (!command.nil? or command)
end
parent_name() click to toggle source
# File lib/dmap/associations/hasn.rb, line 34
def self.parent_name
  "HasMany"
end
validate(command=nil) click to toggle source
# File lib/dmap/associations/hasn.rb, line 46
def self.validate(command=nil)
  command = command.split('-')
  command[1] = nil if command[1].nil?
  {:fields => command[0].underscore.to_sym, :through => command[1]}
end