diff --git a/includes/cache.inc b/includes/cache.inc
index 9b60a7e..baac22e 100644
--- a/includes/cache.inc
+++ b/includes/cache.inc
@@ -280,6 +280,22 @@ interface DrupalCacheInterface {
   function set($cid, $data, $expire = CACHE_PERMANENT);
 
   /**
+   * Store multiple items in the persistent cache.
+   *
+   * @param $items
+   *   An array of cache items in the form array($cid => $data)
+   * @param $expire
+   *   One of the following values:
+   *   - CACHE_PERMANENT: Indicates that the item should never be removed unless
+   *     explicitly told to using cache_clear_all() with a cache ID.
+   *   - CACHE_TEMPORARY: Indicates that the item should be removed at the next
+   *     general cache wipe.
+   *   - A Unix timestamp: Indicates that the item should be kept at least until
+   *     the given time, after which it behaves like CACHE_TEMPORARY.
+   */
+  function setMultiple(Array $items, $expire = CACHE_PERMANENT);
+
+  /**
    * Delete an item from the cache.
    *
    * @param $cid
@@ -463,6 +479,12 @@ class DrupalDatabaseCache implements DrupalCacheInterface {
     }
   }
 
+  function setMultiple(Array $items, $expire = CACHE_PERMANENT) {
+    foreach ($items as $cid => $data) {
+      $this->set($cid, $data, $expire);
+    }
+  }
+
   function delete($cid) {
     db_delete($this->bin)
       ->condition('cid', $cid)
diff --git a/modules/simpletest/tests/cache.test b/modules/simpletest/tests/cache.test
index 1235269..8396af7 100644
--- a/modules/simpletest/tests/cache.test
+++ b/modules/simpletest/tests/cache.test
@@ -152,6 +152,21 @@ class CacheSavingCase extends CacheTestCase {
     $this->assertTrue(isset($cached->data) && $cached->data == $test_object, t('Object is saved and restored properly.'));
   }
 
+  /**
+   * Test the saving of multiple objects.
+   */
+  function testSetMultiple() {
+    $items = array(
+      'cid_1' => 1,
+      'cid_2' => 2,
+    );
+    cache()->setMultiple($items);
+    $cids = array_keys($items);
+    $cached = cache()->getMultiple($cids);
+    $this->assertTrue($cached['cid_1']->data == $items['cid_1']);
+    $this->assertTrue($cached['cid_2']->data == $items['cid_2']);
+  }
+
   /*
    * Check or a variable is stored and restored properly.
    **/
