 
 // MARK: - Error type
 
-public enum InvalidInputError: ErrorType, CustomStringConvertible {
+public enum UnboxValueError: ErrorType, CustomStringConvertible {
     public var description: String {
         switch self {
-        case .MissingKey(let key):
+        case .MissingValueForKey(let key):
             return "missing key (\(key))"
         case .InvalidValue(let key, let valueDescription):
             return "invalid value (\(valueDescription)) for key (\(key))"

            return
        }
        
        var inputErrors = [InvalidInputError]()
        
        for failure in failureInfo {
            if let failedValue: Any = failure.value {
                inputErrors.append(.InvalidValue(failure.key, "\(failedValue)"))
            }
            else {
                inputErrors.append(.MissingKey(failure.key))
            }
        }
        

        }
    }
    
    case InvalidInput([UnboxValueError])
    /// Thrown when a piece of data (NSData) could not be unboxed because it was considered invalid
    case InvalidData
    /// Thrown when a custom unboxing closure returned nil
