         
         return operation
     }
-    open func apiUpload(_ api:String,method:String,headerFields:[String:String]?,fileUrl:URL,complete:@escaping IPaURLResourceUIResultHandler) {
+    open func apiUpload(_ api:String,method:HttpMethod,headerFields:[String:String]?,fileUrl:URL,complete:@escaping IPaURLResourceUIResultHandler) {
         let operation = apiUploadOperation(api, method: method,headerFields: headerFields,fileUrl: fileUrl,complete:complete)
         self.operationQueue.addOperation(operation)
     }
-    open func apiUploadOperation(_ api:String,method:String,headerFields:[String:String]?,fileUrl:URL,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
+    open func apiUploadOperation(_ api:String,method:HttpMethod,headerFields:[String:String]?,fileUrl:URL,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
         return self.apiUploadOperation(api, method: method, headerFields: headerFields, file:fileUrl ,complete: complete)
     }
-    open func apiUpload(_ api:String,method:String,headerFields:[String:String]?,data:Data,complete:@escaping IPaURLResourceUIResultHandler) {
+    open func apiUpload(_ api:String,method:HttpMethod,headerFields:[String:String]?,data:Data,complete:@escaping IPaURLResourceUIResultHandler) {
         let operation = apiUploadOperation(api, method: method, headerFields: headerFields, data: data, complete: complete)
         self.operationQueue.addOperation(operation)
     }
     
-    open func apiUploadOperation(_ api:String,method:String,headerFields:[String:String]?,data:Data,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
+    open func apiUploadOperation(_ api:String,method:HttpMethod,headerFields:[String:String]?,data:Data,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
         return self.apiUploadOperation(api, method: method, headerFields: headerFields,file:data, complete: complete)
     }
-    open func apiUpload(_ api:String,method:String,headerFields:[String:String]?,params:[String:Any],file:IPaMultipartFile,complete:@escaping IPaURLResourceUIResultHandler) {
+    open func apiUpload(_ api:String,method:HttpMethod,headerFields:[String:String]?,params:[String:Any],file:IPaMultipartFile,complete:@escaping IPaURLResourceUIResultHandler) {
         let operation = self.apiUploadOperation(api, method: method, headerFields: headerFields, params:params, file:file, complete: complete)
         self.operationQueue.addOperation(operation)
     }
-    open func apiUploadOperation(_ api:String,method:String,headerFields:[String:String]?,params:[String:Any],file:IPaMultipartFile,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
+    open func apiUploadOperation(_ api:String,method:HttpMethod,headerFields:[String:String]?,params:[String:Any],file:IPaMultipartFile,complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
         return self.apiUploadOperation(api, method: method, headerFields: headerFields, params: params, files: [file], complete: complete)
     }
-    open func apiUpload(_ api:String,method:String,headerFields:[String:String]?,params:[String:Any],files:[IPaMultipartFile],complete:@escaping IPaURLResourceUIResultHandler) {
+    open func apiUpload(_ api:String,method:HttpMethod,headerFields:[String:String]?,params:[String:Any],files:[IPaMultipartFile],complete:@escaping IPaURLResourceUIResultHandler) {
         let extractedExpr = apiUploadOperation(api, method: method,headerFields: headerFields, params:params, files: files, complete: complete)
         let operation = extractedExpr
         self.operationQueue.addOperation(operation)
     }
-    open func apiUploadOperation(_ api:String,method:String,headerFields:[String:String]?,params:[String:Any],files:[IPaMultipartFile],complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
+    open func apiUploadOperation(_ api:String,method:HttpMethod,headerFields:[String:String]?,params:[String:Any],files:[IPaMultipartFile],complete:@escaping IPaURLResourceUIResultHandler) -> IPaURLRequestUploadOperation {
         
         let tempFilePath = (NSTemporaryDirectory() as NSString).appendingPathComponent("IPaURLResponseUITemp\(UUID().uuidString)")
         let boundary:String = ProcessInfo.processInfo.globallyUniqueString

import IPaNetworkState
public typealias IPaURLResourceUIResultHandler = ((Result<(URLResponse?,Any?),Error>) ->())
open class IPaURLResourceUI : NSObject {
    
    @objc open var baseURL:String! = ""
    @objc open var removeNSNull:Bool = true

        }
        return apiDataOperation(with: request,complete:complete)
    }
    open func apiUpload(_ api:String,method:HttpMethod,headerFields:[String:String]?,json:Any,complete:@escaping IPaURLResourceUIResultHandler) throws {
        let operation = try apiUploadOperation(api, method: method,headerFields:headerFields, json: json, complete: complete)
        self.operationQueue.addOperation(operation)
    }
    open func apiUploadOperation(_ api:String,method:HttpMethod,headerFields:[String:String]?,json:Any,complete:@escaping IPaURLResourceUIResultHandler) throws -> IPaURLRequestOperation {

        do {
            let jsonData = try JSONSerialization.data(withJSONObject: json, options: JSONSerialization.WritingOptions(rawValue: 0))
