阅读背景:

如何在Ruby中使用模块覆盖静态类方法?

来源:互联网 
module Imodule
  ???
end

class Some
  include Imodule

  def self.imethod
    puts "original"
  end
end

Some.imethod
# => "overrided"
module Imodule
  ???
end

class Some
  include 



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: