Sha256: 5f2ffb7d94eaa37eccc21e1429f601f2f26abeecab47871b9176b4a42a1ea5ec
Contents?: true
Size: 611 Bytes
Versions: 9
Compression:
Stored size: 611 Bytes
Contents
# frozen_string_literal: true module Panko class Attribute def self.create(name, alias_name: nil) alias_name = alias_name.to_s unless alias_name.nil? Attribute.new(name.to_s, alias_name) end def ==(attr) return name.to_sym == attr if attr.is_a? Symbol return name == attr.name && alias_name == attr.alias_name if attr.is_a? Panko::Attribute super end def hash name.to_sym.hash end def eql?(attr) self.==(attr) end def inspect "<Panko::Attribute name=#{name.inspect} alias_name=#{alias_name.inspect}>" end end end
Version data entries
9 entries across 9 versions & 1 rubygems