     
     typealias onCompleteHandler = (resp : Response, error: NSError?) -> Void
     typealias onBeginHandler = () -> Void
-    typealias onProcessHandler = (progress: Progress, error: NSError?) -> Void
+    typealias onProcessHandler = (progress: Progress) -> Void
+    typealias onDownloadCompleteHandler = (url: NSURL) -> Void
     
     private var completeHandler: onCompleteHandler? = nil
     private var beginHandler: onBeginHandler? = nil
     private var processHandler: onProcessHandler? = nil
+    private var downloadHandler: onDownloadCompleteHandler? = nil
     private let session: Session
     
     private var resumeData: NSData? = nil

    ///
    /// **Note** This hook should be set before response get ticked.
    /// Hooks set after response tick might not be called
    public func onProcess(processHandler: (progress: Progress, error: NSError?) -> Void) {
        if !self.ticked {
            self.processHandler = processHandler
        } else {

        return handler
    }
    
    var download_handler: onDownloadCompleteHandler? {
        self.condition.lock()
        let handler = self.downloadHandler
        self.condition.unlock()
        return handler
    }
    
    private func waitForComplete() {
        if OSAtomicCompareAndSwap32(1, 1, &self.completed) {
            return
