From 543e6094bf572fdd51300f9b6a7433f987560813 Mon Sep 17 00:00:00 2001 From: Kostiantyn Koval Date: Sat, 21 Nov 2015 18:31:40 +0100 Subject: [PATCH] rename --- Source/SpeedLog.swift | 4 ++-- Tests/SpeedLogTests.swift | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Source/SpeedLog.swift b/Source/SpeedLog.swift index a991fe0..0eec570 100644 --- a/Source/SpeedLog.swift +++ b/Source/SpeedLog.swift @@ -45,7 +45,7 @@ public struct SpeedLog { public static func print(items: Any..., separator: String = " ", terminator: String = "\n", _ file: String = __FILE__, _ function: String = __FUNCTION__, _ line: Int = __LINE__) { #if ENABLE_LOG - let prefix = printStringForMode(file, function: function, line: line) + let prefix = modePrefix(file, function: function, line: line) let stringItem = items.map {"\($0)"} .joinWithSeparator(separator) Swift.print("\(prefix)\(stringItem)", terminator: terminator) #endif @@ -57,7 +57,7 @@ extension SpeedLog { /** Creates an output string for the currect log Mode */ - static func printStringForMode(file: String, function: String, line: Int) -> String { + static func modePrefix(file: String, function: String, line: Int) -> String { var result: String = "" if mode.contains(.FileName) { let filename = file.lastPathComponent.stringByDeletingPathExtension diff --git a/Tests/SpeedLogTests.swift b/Tests/SpeedLogTests.swift index 9f8d58e..083a4cd 100644 --- a/Tests/SpeedLogTests.swift +++ b/Tests/SpeedLogTests.swift @@ -43,7 +43,7 @@ extension SpeedLogTests { func logForMode(mode: LogMode) -> String { SpeedLog.mode = mode - return SpeedLog.printStringForMode("File", function: "FuncA", line: 10) + return SpeedLog.modePrefix("File", function: "FuncA", line: 10) } }