def get_bugs(bugs, fields = ::Bugzilla::Bug::FIELDS_SUMMARY)
      params = {}

      if bugs.kind_of?(Array) then
        params['ids'] = bugs
      elsif bugs.kind_of?(Integer) ||
          bugs.kind_of?(String) then
        params['ids'] = [bugs]
      else
        raise ArgumentError, sprintf("Unknown type of arguments: %s", bugs.class)
      end
      unless fields.nil? then
        unless (fields - ::Bugzilla::Bug::FIELDS_ALL).empty? then
          raise ArgumentError, sprintf("Invalid fields: %s", (::Bugzilla::Bug::FIELDS_ALL - fields).join(' '))
        end
        params['include_fields'] = fields
      end

      result = get(params)

      if fields.nil? || fields == ::Bugzilla::Bug::FIELDS_ALL then
        get_comments(bugs).each do |id, c|
          result['bugs'].each do |r|
            if r['id'].to_s == id then
              r['comments'] = c['comments']
              r['comments'] = [] if r['comments'].nil?
              break
            end
          end
        end 
      end

      # 'bugs' is only in interests.
      # XXX: need to deal with 'faults' ?
      result['bugs']
    end
def get_bugs(bugs, fields = ::Bugzilla::Bug::FIELDS_SUMMARY)
      params = {}

      if bugs.kind_of?(Array) then
        params['ids'] = bugs
      elsif bugs.kind_of?(Integer) ||
          bugs.kind_of?(String) then
        params['ids'] = [bugs]
      else
        raise ArgumentError, sprintf("Unknown type of arguments: %s", bugs.class)
      end
      unless fields.nil? then
        unless (fields - ::Bugzilla::Bug::FIELDS_ALL).empty? then
          raise ArgumentError, sprintf("Invalid fields: %s", (::Bugzilla::Bug::FIELDS_ALL - fields).join(' '))
        end
        params['include_fields'] = fields
      end

      result = get(params)

      if fields.nil? || fields == ::Bugzilla::Bug::FIELDS_ALL then
        get_comments(bugs).each do |id, c|
          result['bugs'].each do |r|
            if r['id'].to_s == id then
              r['comments'] = c['comments']
              r['comments'] = [] if r['comments'].nil?
              break
            end
          end
        end 
      end

      # 'bugs' is only in interests.
      # XXX: need to deal with 'faults' ?
      result['bugs']
    end
=begin rdoc

==== Bugzilla::Bug#get_bugs(bugs, fields = Bugzilla::Bug::FIELDS_SUMMARY)

Get the _bugs_ information from Bugzilla. either of String
or Numeric or Array would be acceptable for _bugs_. you can
specify the fields you want to look up with _fields_.

FWIW this name conflicts to Bugzilla API but this isn's a
primitive method since get_bugs method in WebService API is
actually deprecated.

=end