-
-
Save fitomad/27dfcebf41fac7abef7886f9e6416fda to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class WebLogger | |
{ | |
/** | |
Envía el texto al servidor mediante | |
una petición HTTP | |
*/ | |
public func post(_ message: String) -> Void | |
{ | |
print("POST /logging \(message)") | |
} | |
} | |
public class CoreDataLogger | |
{ | |
/** | |
Inserta un registro en la base | |
de datos manejada por Core Data | |
*/ | |
public func insert(_ message: String) -> Void | |
{ | |
print("INSERT INTO LOG \(message)" ) | |
} | |
} | |
public class FileLogger | |
{ | |
/** | |
Escribe en el sistema de archivos | |
del dispositivo | |
*/ | |
public func write(_ message: String) -> Void | |
{ | |
print("APPEND \(message)") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment