Sha256: 5735e2f0383505178649e08b3f7adf6dcdad57307b4133a23c6dd3cdac3afc28

Contents?: true

Size: 248 Bytes

Versions: 44

Compression:

Stored size: 248 Bytes

Contents

module Marty
  module EnumHelper
    def self.pg_enum?(klass:)
      return true if klass.is_a? Marty::PgEnum
      return true if Marty::PgEnum === klass
      return klass._pg_enum? if klass.respond_to?(:_pg_enum?)

      false
    end
  end
end

Version data entries

44 entries across 44 versions & 1 rubygems

Version Path
marty-5.1.3 app/helpers/marty/enum_helper.rb
marty-5.1.2 app/helpers/marty/enum_helper.rb
marty-5.1.1 app/helpers/marty/enum_helper.rb
marty-5.1.0 app/helpers/marty/enum_helper.rb
marty-3.1.0 app/helpers/marty/enum_helper.rb
marty-3.0.1 app/helpers/marty/enum_helper.rb
marty-4.0.0.rc2 app/helpers/marty/enum_helper.rb
marty-3.0.0 app/helpers/marty/enum_helper.rb
marty-2.9.3 app/helpers/marty/enum_helper.rb
marty-2.9.2 app/helpers/marty/enum_helper.rb
marty-2.9.1 app/helpers/marty/enum_helper.rb
marty-2.8.0 app/helpers/marty/enum_helper.rb
marty-2.7.3 app/helpers/marty/enum_helper.rb
marty-2.7.2 app/helpers/marty/enum_helper.rb
marty-2.7.1 app/helpers/marty/enum_helper.rb
marty-2.7.0 app/helpers/marty/enum_helper.rb
marty-2.6.8 app/helpers/marty/enum_helper.rb
marty-2.6.7 app/helpers/marty/enum_helper.rb
marty-2.6.6 app/helpers/marty/enum_helper.rb
marty-2.6.5 app/helpers/marty/enum_helper.rb