         }
         return strippedFunction
     }
-    
 }

    
    static var logClass: Loggable.Type = SwiftyBeaver.self
    
    open class func logVerbose(_ message: String, filePath: String, function: String, line: Int) {
        
        logClass.verbose(message, filePath, self.convertFunction(function), line: line)
        
    }
    
    open class func logDebug(_ message: String, filePath: String, function: String, line: Int) {
        
        logClass.debug(message, filePath, self.convertFunction(function), line: line)
        
    }
    
    open class func logInfo(_ message: String, filePath: String, function: String, line: Int) {
        
        logClass.info(message, filePath, self.convertFunction(function), line: line)
        
    }
    
    open class func logWarning(_ message: String, filePath: String, function: String, line: Int) {
        
        logClass.warning(message, filePath, self.convertFunction(function), line: line)
        
    }
    
    open class func logError(_ message: String, filePath: String, function: String, line: Int) {
        
        logClass.error(message, filePath, self.convertFunction(function), line: line)
        
    }
    
    open class func convertFunction(_ function: String) -> String {
        var strippedFunction = function
        
        if let match = function.range(of: "\\w+:*[\\w*:*]*]", options: .regularExpression) {


protocol Loggable: class {
    
    static func verbose(_ msg: @autoclosure () -> Any, _ path: String, _ function: String, line: Int, context: Any?)
    static func debug(_ msg: @autoclosure () -> Any, _ path: String, _ function: String, line: Int, context: Any?)
    static func info(_ msg: @autoclosure () -> Any, _ path: String, _ function: String, line: Int, context: Any?)
    static func warning(_ msg: @autoclosure () -> Any, _ path: String, _ function: String, line: Int, context: Any?)
    static func error(_ msg: @autoclosure () -> Any, _ path: String, _ function: String, line: Int, context: Any?)
    
}

extension SwiftyBeaver: Loggable {}

@objc open class SBObjectiveCWrapper: NSObject {
    
    @objc class func _setLogClassForTesting(_ logClass: AnyObject) {
        self.logClass = logClass as! Loggable.Type
