         return nil
     }
     
+    /// Execute a function for each element in the array.
+    ///
+    /// :param: function Function to run for each element
     func each(function: ElementCallback) {
         for item in self {
             function(item)
         }
     }
     
+    /// Execute a function for each index and element tuple in the array.
+    ///
+    /// :param: function Function to run for each index and element tuple
     func each(function: IndexedElementCallback) {
         for (index, item) in enumerate(self) {
             function(index, item)
         }
     }
     
+    /// Test if the array contains one or more elements.
+    ///
+    /// :param: items One or more elements to search for in the array. The array
+    ///   must contain all of the given elements for this method to return true
+    /// :returns: True if all of the given elements were found in the array,
+    ///   otherwise false
     func contains<T: Equatable>(items: T...) -> Bool {
         return items.every { self.indexOf($0) >= 0 }
     }
     
+    /// Test if any of the array elements pass a given condition.
+    ///
+    /// :param: test Function that takes an array element and returns true or
+    ///   false
+    /// :returns: True the first time an array element passes the test function,
+    ///   otherwise false
     func some(test: TestCallback) -> Bool {
         for item in self {
             if test(item) { return true }

        return nil
    }
    
    func indexOf(condition: Element -> Bool) -> Int? {
        for (index, element) in enumerate(self) {
            if condition(element) { return index }
        }

        return false
    }
    
    /// Test if all of the array elements pass a given condition.
    ///
    /// :param: test Function that takes an array element and returns true or
    ///   false
    /// :returns: True if every array element passes the test function,
    ///   otherwise false the first time an element fails the test
    func every(test: TestCallback) -> Bool {
        for item in self {
            if !test(item) { return false }
