I want to add a treeview menu in the left side of my application like xcode treeview menu in the leftside. I didn't find any treeview ment element in the object container of xcode. Can anyone suggest me how to do it.I am using Xcode 9.3 and swift 4.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Hi there. I am developing a mac os application where i have to convert the data from server API to a zip file. The API is returning a zip file itself in encoded format of type Data, but i want to convert that data to a zip file and want to store in the disk.CODE:______ func DownloadExamZip(){
let request = NSMutableURLRequest(url: NSURL(string: "http://localhost:5000/api/DownloadExamZip/EX0000018/ST000000195/874059")! as URL)
request.httpMethod = "GET"
let AuthorizationToken = "Hidden"
request.setValue("application/x-www-form-urlencoded; charset=utf-8", forHTTPHeaderField: "Content-Type")
request.setValue(AuthorizationToken, forHTTPHeaderField: "Authorization")
let task = URLSession.shared.dataTask(with: request as URLRequest) { data, response, error in
do {
guard data != nil else {
print("data is nil")
return
}
//Here i want to convert the type data to a zip file
}
catch {
print("Error -> \(error)")
}
}
task.resume()
} Can anyone help me to convert that data into a zip file please. I also have to store that file in the disk.