|
@@ -122,24 +122,24 @@ public func bf_getCurrentViewController() -> UIViewController? {
|
|
|
|
|
|
*/
|
|
|
public func BFLog<T>( _ type : Int = 0, _ file:String = #file, _ line:Int = #line, message: T) {
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+ let dateFmt = DateFormatter()
|
|
|
+ dateFmt.dateFormat = "HH:mm:ss:SSSS"
|
|
|
+ let file = (file as NSString).lastPathComponent;
|
|
|
+ let msg = "\(file) (L:\(line)) \(message)"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
+#if DEBUG
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
+ print("ww-\(dateFmt.string(from: Date())) \(msg)");
|
|
|
|
|
|
|
|
|
-
|
|
|
+#endif
|
|
|
}
|
|
|
|
|
|
|