我有一个看起来像传递任意参数方法
def SomeMethod (*args)
m = if args.length > 0 then
self.method(:method1)
else
self.method(:method2)
end
m.call ... #need to either pipe all arguments aside from the first
#and in other cases substitute the first argument
end
实际结构是痘痘更复杂的地方要调用的方法是不同的实例,并在某些情况下,我不得不管的方法以免第一,在其他情况下所有的参数我不得不与另一个值代替第一个参数