class RBS::AST::Declarations::Module::Self
属性
args[R]
location[R]
name[R]
公共类方法
new(name:, args:, location:) 点击切换源代码
# File rbs-3.8.0/lib/rbs/ast/declarations.rb, line 153 def initialize(name:, args:, location:) @name = name @args = args @location = location end
公共实例方法
==(other) 点击切换源代码
# File rbs-3.8.0/lib/rbs/ast/declarations.rb, line 159 def ==(other) other.is_a?(Self) && other.name == name && other.args == args end
也别名为:eql?
hash() 点击切换源代码
# File rbs-3.8.0/lib/rbs/ast/declarations.rb, line 165 def hash self.class.hash ^ name.hash ^ args.hash ^ location.hash end
to_json(state = _ = nil) 点击切换源代码
# File rbs-3.8.0/lib/rbs/ast/declarations.rb, line 169 def to_json(state = _ = nil) { name: name, args: args, location: location }.to_json(state) end
to_s() 点击切换源代码
# File rbs-3.8.0/lib/rbs/ast/declarations.rb, line 177 def to_s if args.empty? name.to_s else "#{name}[#{args.join(", ")}]" end end