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
import Foundation | |
import SwiftUI | |
extension View { | |
func marque() -> some View { | |
modifier(HorizontalMarqueModifier()) | |
} | |
} |
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
import Foundation | |
protocol CountryEmojiResolver { | |
func emoji(for country: String) -> String | |
} | |
class StandartCoutryEmojiResolver: CountryEmojiResolver { | |
func emoji(for country: String) -> String { | |
let languageToFlag: [String: String] = [ |
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
protocol ObjectMerger { | |
func merge<T>(_ source: T, into dest: T, overwrites: Bool) | |
} | |
struct StandartObjectMerger: ObjectMerger { | |
func merge<T>(_ source: T, into dest: T, overwrites: Bool) { | |
guard let src = source as? NSObject else { | |
return |
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
protocol LempelZivMarkovUnarchiver { | |
func unarchive(url: URL) throws -> URL | |
} | |
class StandartLZMUnarchiver: LempelZivMarkovUnarchiver { | |
func unarchive(url: URL) throws -> URL { | |
let algorithm: Algorithm = .lzma | |
let fileManager = FileManager.default |
OlderNewer