# File lib/vpim/rrule.rb, line 570
      def encode
        unless @freq
          raise ArgumentError, "Must specify FREQUENCY"
        end

        rrule = "FREQ=#{@freq}"

        [
          ["COUNT", @count],
          ["UNTIL", @until],
          # TODO...
        ].each do |k,v|
          if v
            rrule += ";#{k}=#{v}"
          end
        end
        rrule
      end