class DbAgent::Viewpoint::TypeCheck

Forces typechecking on all child relations.

Attributes

child[R]
db[R]

Public Class Methods

new(db, child = nil) click to toggle source
# File lib/db_agent/viewpoint/typecheck.rb, line 6
def initialize(db, child = nil)
  @db = db
  @child = child || DbAgent::Viewpoint::Base.new(db)
end

Public Instance Methods

method_missing(name, *args, &bl) click to toggle source
Calls superclass method
# File lib/db_agent/viewpoint/typecheck.rb, line 12
def method_missing(name, *args, &bl)
  return super unless args.empty? && bl.nil?
  child.send(name).with_typecheck
end