Sha256: eb376e2473fe38abcc6b7775181b87d02ee41577b44ead9b395dc7beb8e33a0b

Contents?: true

Size: 343 Bytes

Versions: 4

Compression:

Stored size: 343 Bytes

Contents

module HentryConsumer
  class FormatRules
    REQUIRED = []
    UNIQUE   = [:uid, :bookmark]

    class << self
      def required?(format)
        REQUIRED.include? format
      end
      def can_have_many?(format)
        !unique?(format)
      end
      
      def unique?(format)
        UNIQUE.include? format
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
hentry_consumer-0.5.3 lib/hentry_consumer/format_rules.rb
hentry_consumer-0.5.2 lib/hentry_consumer/format_rules.rb
hentry_consumer-0.5.1 lib/hentry_consumer/format_rules.rb
hentry_consumer-0.5.0 lib/hentry_consumer/format_rules.rb