I want to get the directory where I can create files and write logs to files in my swift app for iOS devices. I read here, https://stackoverflow.com/a/3763050/919280, that using Objective-C, there is a solution. I tried writing it in swift like this:
var appDir = NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSUserDomainMask, true)
But, NSLibraryDirectory and NSUserDomainMask do not seem to be present in Swift. What is the way to do this is Swift?