Yep
module Foo
def self.included(base)
base.extend(ClassMethods)
end
module ClassMethods
def some_method
# stuff
end
end
end
One possible note I should add – if the module is going to be ALL class methods – better off just using extend ModuleName in the Model and defining the methods directly in the module instead – rather than having a ClassMethods module inside the Module, a la
module ModuleName
def foo
# stuff
end
end