blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
2
625
content_id
stringlengths
40
40
detected_licenses
listlengths
0
47
license_type
stringclasses
2 values
repo_name
stringlengths
5
116
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringclasses
643 values
visit_date
timestamp[ns]
revision_date
timestamp[ns]
committer_date
timestamp[ns]
github_id
int64
80.4k
689M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
16 values
gha_event_created_at
timestamp[ns]
gha_created_at
timestamp[ns]
gha_language
stringclasses
85 values
src_encoding
stringclasses
7 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
1 class
length_bytes
int64
4
6.44M
extension
stringclasses
17 values
content
stringlengths
4
6.44M
duplicates
listlengths
1
9.02k
2609ed5325fbafd587e7103113f6a22c668ebd44
4e2e6d344fc5adb28f5e41b50e2699d3aef931e6
/Sources/Utils/string/regexp/RegExp.swift
7b4bde03babe6f60eb79e7fa4d1db54a188f5b99
[ "MIT" ]
permissive
Joebayld/swift-utils
f4e3a7e530622cd8675f7dd10178014a65acd94d
8d123c63957ef44ebe2a53ecf42fc671e3763787
refs/heads/master
2021-01-16T21:30:23.007446
2017-08-14T06:36:36
2017-08-14T06:36:36
100,235,722
0
0
null
2017-08-14T06:32:02
2017-08-14T06:32:01
null
UTF-8
Swift
false
false
11,449
swift
import Foundation /** * Flag (Pattern) Description: * i - If set, matching will take place in a case-insensitive manner. * x - If set, allow use of white space and #comments within patterns * s - If set, a "." in a pattern will match a line terminator in the input text. By default, it will not. Note that a carriage-return / line-feed pair in text behave as a single line terminator, and will match a single "." in a regular expression pattern * m - Control the behavior of "^" and "$" in a pattern. By default these will only match at the start and end, respectively, of the input text. If this flag is set, "^" and "$" will also match at the start and end of each line within the input text. * Para - Controls the behavior of \b in a pattern. If set, word boundaries are found according to the definitions of word found in Unicode UAX 29, Text Boundaries. By default, word boundaries are identified by means of a simple classification of characters as either “word” or “non-word”, which approximates traditional regular expression behavior. The results obtained with the two options can be quite different in runs of spaces and other non-word characters. */ public class RegExp{ /** * Asserts if a match exists * NOTE: NSRegularExpression. https://developer.apple.com/library/mac/documentation/Foundation/Reference/NSRegularExpression_Class/index.html * NOTE: for simple implimentations: str.rangeOfString(pattern, options: .RegularExpressionSearch) != nil * EXAMPLE: RegExp.test("hello world","o.*o")//true * CAUTION: upgraded in swift 3, was-> str.rangeOfString(pattern, options: .RegularExpressionSearch) != nil */ static func test(_ str:String,_ pattern:String)->Bool{ return str.range(of: pattern, options:.regularExpression) != nil//or do something like this: return RegExpParser.match(pattern,options).count > 0 } /** * NOTE: NSRegularExpression. (has overview of the regexp syntax supported) https://developer.apple.com/library/mac/documentation/Foundation/Reference/NSRegularExpression_Class/index.html * NOTE: NSRegularExpressionOptions: DotMatchesLineSeparators,CaseInsensitive,AnchorsMatchLines * EXAMPLE: RegExp.match("My name is Taylor Swift","My name is (.*)")//Swift * EXAMPLE: RegExp.match("hello world","(\\b\\w+\\b)")//hello, world * Example: RegExpParser.match("abc 123 abc 123 abc 123 xyz", "[a-zA-Z]{3}")//["abc", "abc", "abc", "xyz"] * TODO: ⚠️️ Probably return optional array? * TODO: Then if it is outof bound return eigther an empty array or nil * TODO: Then only do substringwithrange if NSRange is not NSOutOfBoundRange type */ static func match(_ text:String, _ pattern:String, _ options: NSRegularExpression.Options = NSRegularExpression.Options.caseInsensitive) -> [String] { return matches(text, pattern).map { (text as NSString).substring(with: $0.range)} } /** * Similar to Exec in other languages * NOTE: NSRegExp uses the ICU regexp syntax: http://userguide.icu-project.org/strings/regexp * NOTE: Use this method when doing named capturing group or location of matches * NOTE: use this call to get the capturing group: (str as NSString).substringWithRange(match.rangeAtIndex(1)) capturing groups from index (1 - n) * NOTE: use an "enum" if you need named capturing groups. like: enum FolderTaskParts:Int{ case folder = 1, content } * NOTE: its also possible to find number of matches this way: regex.numberOfMatchesInString(text options:[] NSMakeRange(0, nsString.length)) * TODO: ⚠️️ Figure out how to do numbered capturing groups ($n - n is a digit. Back referencing to a capture group. n must be >= 0 and not greater than ) maybe with \$2 \$3 etc? * TODO: Research how to deal with swift unicode chars, emojis etc: see this: http://stackoverflow.com/questions/25882503/how-can-i-use-nsregularexpression-on-swift-strings-with-variable-width-unicode-c * EXAMPLE: * let str = "blue:0000FF green:00FF00 red:FF0000" * RegExp.matches(str, "(\\w+?)\\:([A-Z0-9]+?)(?: |$)").forEach { * Swift.print("match.numberOfRanges: " + "\($0.numberOfRanges)")/*The first item is the entire match*/ * let content = (str as NSString).substringWithRange($0.rangeAtIndex(0))/*the entire match*/ * let name = $0.value(str, 1)/*capturing group 1*/ * let value = $0.value(str, 2)/*capturing group 2*/ * }//Outputs: name: green, value: 00FF00...and so on */ static func matches(_ text:String!, _ pattern:String!, _ options:NSRegularExpression.Options = NSRegularExpression.Options.caseInsensitive) -> [NSTextCheckingResult] { do { let regex = try NSRegularExpression(pattern: pattern, options: options) let nsString = text as NSString let results = regex.matches(in: text,options: [], range: NSMakeRange(0, nsString.length)) return results } catch let error as NSError { print("invalid regex: \(error.localizedDescription)") return [] } } /** * Replaces all matches with the replacment string * Returns Value A string with matching regular expressions replaced by the template string. * NOTE: you can use this call replaceMatchesInString to modify the original string, must use nsmutablestring to do this * NOTE: ⚠️️ NSRegularExpression has lots of good info -> https://developer.apple.com/library/mac/documentation/Foundation/Reference/NSRegularExpression_Class/index.html * IMPORTANT: ⚠️️ by using "$1" or "$2" etc you can replace with the match * PARAM: string The string to search for values within. * PARAM: options: The matching options to use. See NSMatchingOptions for possible values. * PARAM: range: The range of the string to search. * PARAM: replacement: The substitution template used when replacing matching instances. * TODO: ⚠️️ The PARAM: text should be inout, maybe? * EXAMPLE: RegExp.replace("<strong>Hell</strong>o, <strong>Hell</strong>o, <strong>Hell</strong>o", "<\\/?strong>", "*")//Output: "*Hell*o, *Hell*o, *Hell*o" * EXAMPLE: RegExp.replace("yeah yeah","(\\b\\w+\\b)", "bla")//bla bla */ static func replace(_ str:String,_ pattern:String,_ replacement:String,_ options:NSRegularExpression.Options = NSRegularExpression.Options.caseInsensitive)->String{ do { let stringlength = str.characters.count let regex = try NSRegularExpression(pattern:pattern , options: options) let modString = regex.stringByReplacingMatches(in: str, options: [], range: NSMakeRange(0, stringlength), withTemplate: replacement) return modString } catch let error as NSError { print("invalid regex: \(error.localizedDescription)") return "" } } typealias Replacer = (_ match:String)->String?//if nil is returned then replacer closure didnt want to replace the match /** * New, replaces with a closure * TODO: ⚠️️ Try to performance test if accumulative substring is faster (you += before the match + the match and so on) * EXAMPLE: Swift.print("bad wolf, bad dog, Bad sheep".replace(pattern: "\\b([bB]ad)\\b"){return $0.isLowerCased ? $0 : $0.lowercased()})//bad wolf, bad dog, bad sheep */ static func replace(_ str:String, pattern:String, options:NSRegularExpression.Options = NSRegularExpression.Options.caseInsensitive,replacer:Replacer) -> String{ // Swift.print("RegExp.replace") var str = str RegExp.matches(str, pattern).reversed().forEach() { let range:NSRange = $0.rangeAt(1) // Swift.print("range: " + "\(range)") let stringRange:Range<String.Index> = str.stringRange(str, range.location, len: range.length) let match:String = str.substring(with: stringRange)//TODO: reuse the stringRange to get the subrange here // Swift.print("match: " + "\(match)") if let replacment:String = replacer(match) { str.replaceSubrange(stringRange, with: replacment) } } return str } /** * Extracts associated capture groups from the RegExp.matches result * TODO: ⚠️️ Would be great if .rawValue was done inside this method, can be done with <T> possibly look at the apple docs about enumerations * EXAMPLE: RegExp.value(fullString,match,StatusParts.second.rawValue) * TODO: ⚠️️ you should check if there is content in the range first, if ther eis not return nilor error */ static func value(_ str:String, _ result:NSTextCheckingResult, _ key:Int)->String{ return (str as NSString).substring(with: result.rangeAt(key)) } /** * New, finds first index of pattern in string */ static func search(_ input:String, _ pattern:String,_ options: NSRegularExpression.Options = NSRegularExpression.Options.caseInsensitive) -> Int?{ guard let range = input.range(of: pattern, options:.regularExpression) else{return nil} return input.distance(from:input.startIndex,to:range.lowerBound) } /** * Coming soon */ static func exec(){ //TODO: ⚠️️ research enumerateMatches, it takes a method and enumerate all matches. //NSRegularExpression.replacementString has an offset, which I think you can use } // static func replaceMatches<T: Sequence>(in source:String, matches:T, using replacer:(Match) -> String?) -> String where T.Iterator.Element : Match { // // "str".matches("(\\w+?)\\:([A-Z0-9]+?)(?: |$)").forEach { // Swift.print("match.numberOfRanges: " + "\($0.numberOfRanges)")/*The first item is the entire match*/ // let content = (str as NSString).substringWithRange($0.rangeAtIndex(0))/*the entire match*/ // let name = $0.value("", 1)/*capturing group 1*/ // // (str as NSString).substring(with: result.rangeAt(key)) // // } // // var result = "" // var lastRange:StringRange = source.startIndex ..< source.startIndex // for match in matches { // result += source.substring(with: lastRange.upperBound ..< match.range.lowerBound) // if let replacement = replacer(match) { // result += replacement // } else { // result += source.substring(with: match.range) // } // lastRange = match.range // } // result += source.substring(from: lastRange.upperBound) // return result // } // // /** Replaces all occurances of the pattern using supplied replacer function. - parameters: - source: String to be matched to the pattern - replacer: Function that takes a match and returns a replacement. If replacement is nil, the original match gets inserted instead - returns: A string, where all the occurances of the pattern were replaced */ // static func replaceAll(_ source:String, replacer:(Match) -> String?) -> String { // let matches = findAll(in: source) // return replaceMatches(in: source, matches: matches, using: replacer) // } } extension NSTextCheckingResult{ func value(_ str:String, _ key:Int)->String{//Convenience return RegExp.value(str, self, key) } }
[ -1 ]
0238261d01b9157c51087306d86ebad9ba922c53
8fa0d6f0643eafa1f0a99dcdd8be3954f7d5b352
/Example App/Example App/ViewController.swift
7324e249a6d48c89a139d7d22ccb9c5ccaeb69d6
[]
no_license
gwmccull/swift-tutorial
2d86e9a5da87b84eb05ec01245eb30ec4fbcfa5a
c2feb32a726c8990ac3732fa58fd6512900ed23e
refs/heads/master
2021-01-01T04:06:14.543002
2016-05-03T03:36:59
2016-05-03T03:36:59
57,939,118
0
0
null
null
null
null
UTF-8
Swift
false
false
704
swift
// // ViewController.swift // Example App // // Created by Garrett McCullough on 2/28/15. // Copyright (c) 2015 GWM. All rights reserved. // import UIKit class ViewController: UIViewController { @IBOutlet weak var myLabel: UILabel! @IBAction func buttonPressed(sender: AnyObject) { myLabel.text = "it worked!" } override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. println("hello world") } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
[ 277693 ]
79712b2942226d706e9ab49ae05353e4971c7ab6
f42ae53ae2f0a07c722fc1a539ebe6e6b4dd5a42
/EmojiReader/example/EmojiTableViewCell.swift
f7a9793182a6c473a0d3a24a2762f65342f9a4e1
[]
no_license
Darkhan17/swift
b5fd56e5d76674093adf8358c9969cae5d4daa26
acbee61a70b5879eac589b6c40e2ace233e555a9
refs/heads/master
2023-04-29T12:45:37.992198
2021-05-22T12:58:05
2021-05-22T12:58:05
369,808,390
0
0
null
null
null
null
UTF-8
Swift
false
false
765
swift
// // EmojiTableViewCell.swift // example // // Created by Khamitov Darkhan on 5/20/21. // import UIKit class EmojiTableViewCell: UITableViewCell { @IBOutlet weak var emojiLabel: UILabel! @IBOutlet weak var nameLabel: UILabel! @IBOutlet weak var descriptionLabel: UILabel! override func awakeFromNib() { super.awakeFromNib() // Initialization code } func set (object: Emoji){ self.emojiLabel.text = object.emoji self.nameLabel.text = object.name self.descriptionLabel.text = object.description } override func setSelected(_ selected: Bool, animated: Bool) { super.setSelected(selected, animated: animated) // Configure the view for the selected state } }
[ 281985, 300802, 211843, 300801, 227845, 206342, 36743, 327181, 333837, 282897, 334226, 311704, 329880, 336160, 281636, 278567, 283048, 211370, 287022, 313138, 282934, 278583, 310839, 381622, 327241, 358868, 214104, 358876, 294623, 336737, 213100, 165871, 222835, 222836, 113529, 305661, 300799 ]
06e96dfbc4023d3295a18395f357f44d1e9cbf5e
9437d7f0e0a46223c79f220b523fdd62f9698746
/SomeTests/AppDelegate.swift
7494ad91cfde23ebc42eff6be16cf064bc3f3a87
[]
no_license
mushikago/SomeTests
631ee536148b8b4e31851ad466635cf1a1776a37
56b50494f6d9a1c97208a95b97c86ddec4102b5b
refs/heads/master
2016-09-06T18:11:56.695880
2015-06-10T18:28:53
2015-06-10T18:28:53
37,215,051
0
0
null
null
null
null
UTF-8
Swift
false
false
2,163
swift
// // AppDelegate.swift // SomeTests // // Created by Tetsuya Shiraishi on 2015/06/09. // Copyright (c) 2015年 Tetsuya Shiraishi. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. } func applicationDidEnterBackground(application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(application: UIApplication) { // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 229388, 294924, 278542, 229391, 327695, 278545, 229394, 278548, 229397, 229399, 229402, 278556, 229405, 278559, 229408, 278564, 294950, 229415, 229417, 237613, 229422, 360496, 229426, 237618, 229428, 286774, 229432, 319544, 204856, 286776, 286791, 237640, 278605, 286797, 311375, 163920, 237646, 196692, 319573, 311383, 278623, 319590, 311400, 278635, 303212, 278639, 278648, 131192, 237693, 327814, 131209, 417930, 303241, 311436, 303244, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 278760, 237807, 303345, 286962, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 287032, 155966, 278849, 319809, 319810, 319814, 319818, 311628, 229709, 287054, 319822, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 279010, 287202, 279015, 172520, 319978, 279020, 172526, 279023, 311791, 172529, 279027, 319989, 164343, 180727, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 287238, 320007, 172552, 172550, 303623, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 172618, 303690, 33357, 287309, 279124, 172634, 262752, 311911, 189034, 295533, 189039, 189040, 352880, 295538, 172655, 189044, 287349, 172656, 172660, 287355, 287360, 295553, 287365, 311942, 303751, 295557, 352905, 279178, 287371, 311946, 311951, 287377, 311957, 287381, 221850, 287386, 164509, 287390, 295583, 230045, 172705, 287394, 303773, 303780, 172702, 287398, 172707, 287400, 279208, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 279231, 287423, 328384, 287427, 312006, 107208, 107212, 172748, 287436, 172751, 287440, 295633, 172755, 303827, 279255, 172760, 279258, 287450, 213724, 189149, 303835, 303838, 279267, 312035, 295654, 279272, 312048, 230128, 312050, 230131, 205564, 303871, 230146, 295685, 230154, 33548, 312077, 295695, 295701, 369433, 230169, 295707, 328476, 295710, 230175, 303914, 279340, 205613, 279353, 230202, 312124, 222018, 295755, 377676, 148302, 287569, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303985, 328563, 303987, 279413, 303991, 303997, 295806, 295808, 304005, 295813, 320391, 213895, 304009, 304007, 304011, 230284, 304013, 213902, 279438, 295822, 295825, 189329, 304019, 189331, 279445, 58262, 279452, 410526, 279461, 279462, 304042, 213931, 230327, 304055, 287675, 304063, 238528, 304065, 189378, 213954, 156612, 295873, 213963, 312272, 304084, 304090, 320481, 320490, 304106, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 197645, 295949, 230413, 320528, 140312, 238620, 197663, 304164, 189479, 304170, 238641, 312374, 238652, 238655, 230465, 238658, 296004, 336964, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 296040, 361576, 205931, 296044, 164973, 205934, 279661, 312432, 279669, 189562, 337018, 279679, 279683, 222340, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 165038, 238766, 230576, 304311, 230592, 279750, 312518, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 279781, 304360, 279788, 320748, 279790, 304370, 296189, 320771, 312585, 296202, 296205, 230674, 320786, 230677, 296213, 230679, 296215, 230681, 320792, 214294, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 222525, 296253, 296255, 312639, 230718, 296259, 378181, 230727, 238919, 296264, 320840, 296267, 296271, 222545, 230739, 312663, 337244, 222556, 230752, 312676, 230760, 173418, 230763, 410987, 230768, 296305, 312692, 230773, 279929, 181626, 304505, 304506, 181631, 312711, 296331, 288140, 230800, 288144, 304533, 337306, 288154, 288160, 173472, 288162, 288164, 279975, 304555, 370092, 279983, 288176, 279985, 173488, 312755, 296373, 279991, 312759, 288185, 337335, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 288210, 370130, 288212, 280021, 288214, 222676, 239064, 288217, 288218, 280027, 288220, 329177, 239070, 288224, 288226, 370146, 280036, 288229, 280038, 288230, 288232, 280034, 288234, 320998, 288236, 288238, 288240, 288242, 296435, 288244, 288250, 402942, 148990, 206336, 296446, 296450, 321022, 230916, 230919, 214535, 370187, 304651, 304653, 230940, 222752, 108066, 296486, 296488, 157229, 230961, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 288344, 280152, 239194, 280158, 403039, 370272, 181854, 239202, 312938, 280183, 280185, 280188, 280191, 280194, 116354, 280208, 280211, 288408, 280218, 280222, 190118, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 280260, 280264, 206536, 206539, 206541, 206543, 280276, 313044, 321239, 280283, 288478, 313055, 321252, 313066, 280302, 288494, 280304, 313073, 419570, 288499, 288502, 280314, 288510, 124671, 67330, 280324, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 280388, 304968, 280393, 280402, 313176, 280419, 321381, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 280487, 313258, 321458, 296883, 124853, 214966, 296890, 10170, 288700, 296894, 280515, 190403, 296900, 337862, 165831, 280521, 231379, 296921, 239586, 313320, 231404, 124913, 165876, 321528, 313340, 288764, 239612, 239617, 313347, 288773, 313358, 305176, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 321595, 378941, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 280671, 223327, 149601, 149599, 149603, 321634, 329830, 280681, 313451, 223341, 280687, 215154, 280691, 313458, 313464, 321659, 280702, 288895, 321670, 215175, 141446, 141455, 141459, 280725, 313498, 288936, 100520, 280747, 288940, 280755, 288947, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 280819, 157940, 182517, 125171, 280823, 280825, 280827, 280830, 280831, 280833, 280835, 125187, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 280891, 289087, 280897, 280900, 305480, 239944, 280906, 239947, 305485, 305489, 379218, 280919, 354653, 313700, 280937, 313705, 190832, 280946, 223606, 313720, 280956, 280959, 313731, 199051, 240011, 289166, 240017, 297363, 190868, 297365, 240021, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 305594, 289210, 281024, 289218, 289221, 289227, 281045, 281047, 215526, 166378, 305647, 281075, 174580, 281084, 240124, 305662, 305664, 240129, 305666, 240132, 223749, 305668, 281095, 223752, 338440, 150025, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 199262, 338528, 338532, 281190, 199273, 281196, 158317, 19053, 313973, 281210, 297594, 158347, 133776, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 297671, 158409, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 207661, 289593, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 183172, 158596, 338823, 322440, 314249, 240519, 183184, 240535, 289687, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 281567, 289762, 322534, 297961, 281581, 183277, 322550, 134142, 322563, 175134, 322599, 322610, 314421, 281654, 314427, 207937, 314433, 314441, 207949, 322642, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 289912, 248995, 306341, 306344, 306347, 306354, 142531, 199877, 289991, 306377, 249045, 363742, 363745, 298216, 330988, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 298306, 380226, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 290171, 314747, 306555, 290174, 298365, 224641, 281987, 298372, 314756, 281990, 224647, 265604, 298377, 314763, 142733, 298381, 224657, 306581, 314779, 314785, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 191992, 290298, 151036, 290302, 282111, 290305, 175621, 192008, 323084, 257550, 282127, 290321, 282130, 323090, 282133, 290325, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 282261, 298651, 323229, 282269, 323231, 298655, 61092, 282277, 306856, 282295, 324766, 282300, 323260, 323266, 282310, 323273, 282319, 306897, 241362, 282328, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 282410, 241450, 306988, 306991, 315184, 323376, 315190, 241464, 282425, 159545, 298811, 307009, 413506, 241475, 307012, 148946, 315211, 282446, 307027, 315221, 282454, 315223, 241496, 323414, 241498, 307035, 307040, 282465, 110433, 241509, 110438, 298860, 110445, 282478, 282481, 110450, 315251, 315249, 315253, 315255, 339838, 282499, 315267, 315269, 241544, 282505, 241546, 241548, 298896, 282514, 298898, 44948, 298901, 241556, 282520, 241560, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 178273, 36779, 241581, 282542, 241583, 323504, 241586, 282547, 241588, 290739, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 299006, 282623, 315397, 241669, 282632, 282639, 290835, 282645, 241693, 282654, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 315482, 217179, 315483, 192605, 233567, 299105, 200801, 217188, 299109, 307303, 315495, 356457, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 307338, 233613, 241813, 307352, 299164, 184479, 299167, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 323763, 176311, 184503, 307385, 307386, 258235, 176316, 307388, 307390, 299200, 184512, 307394, 307396, 299204, 184518, 323784, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 282893, 291089, 282906, 291104, 233766, 176435, 307508, 168245, 307510, 332086, 151864, 307512, 315701, 307515, 282942, 307518, 151874, 282947, 282957, 323917, 110926, 233808, 323921, 315733, 323926, 233815, 315739, 323932, 299357, 242018, 242024, 299373, 315757, 250231, 315771, 242043, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 283033, 291226, 242075, 291231, 61855, 283042, 291238, 291241, 127403, 127405, 291247, 127407, 299440, 299444, 127413, 283062, 291254, 127417, 291260, 283069, 127421, 127424, 127429, 127431, 176592, 315856, 315860, 176597, 283095, 127447, 299481, 176605, 242143, 291299, 242152, 291305, 127466, 176620, 291314, 291317, 135672, 233979, 291323, 291330, 283142, 135689, 233994, 127497, 291341, 233998, 234003, 234006, 127511, 152087, 283161, 234010, 135707, 242202, 135710, 242206, 242208, 291361, 242220, 291378, 234038, 152118, 234041, 70213, 111193, 284245, 242275, 299620, 242279, 168562, 184952, 135805, 291456, 135808, 299655, 373383, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 299684, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 225998, 299726, 226002, 226005, 119509, 226008, 242396, 299740, 201444, 299750, 283368, 234219, 283372, 226037, 283382, 234231, 316151, 234236, 226045, 234239, 242431, 209665, 234242, 242436, 234246, 226056, 234248, 291593, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 283421, 234269, 234272, 234274, 152355, 234278, 299814, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 283452, 160572, 234302, 234307, 242499, 234309, 234313, 316233, 316235, 234316, 283468, 234319, 242511, 234321, 234324, 201557, 234329, 234333, 308063, 234336, 234338, 242530, 349027, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 234356, 177011, 234358, 234362, 226171, 291711, 234368, 234370, 291714, 291716, 234373, 226182, 234375, 226185, 308105, 234379, 234384, 234388, 234390, 226200, 234393, 209818, 308123, 234396, 324504, 234398, 291742, 324508, 234401, 291747, 291748, 234405, 291750, 234407, 324518, 324520, 291754, 324522, 226220, 291756, 234414, 324527, 291760, 234417, 201650, 324531, 226230, 234422, 324536, 275384, 234428, 291773, 226239, 324544, 234431, 234434, 324546, 242623, 226245, 234437, 234439, 324548, 234443, 291788, 193486, 275406, 193488, 234446, 234449, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 234487, 324599, 234490, 234493, 234496, 316416, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 234519, 234520, 316439, 234523, 234526, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 234543, 234546, 275508, 234549, 300085, 300088, 234556, 234558, 316479, 234561, 316483, 234563, 308291, 234568, 234570, 316491, 234572, 300108, 234574, 300115, 234580, 234581, 275545, 234585, 242777, 234590, 234593, 234595, 234597, 300133, 234601, 300139, 234605, 234607, 160879, 275569, 234610, 300148, 234614, 398455, 234618, 275579, 234620, 144506, 234623, 226433, 234627, 275588, 234629, 234634, 234636, 177293, 234640, 275602, 234643, 226453, 275606, 308373, 275608, 234647, 234650, 234648, 308379, 283805, 324757, 119967, 234653, 234657, 300189, 324768, 242852, 283813, 234661, 300197, 234664, 275626, 234667, 316596, 308414, 234687, 316610, 300226, 234692, 308420, 308418, 283844, 300229, 283850, 300234, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 161003, 300267, 300270, 300272, 120053, 300278, 275703, 316663, 300284, 275710, 300287, 292097, 300289, 300292, 300294, 275719, 177419, 300299, 283917, 242957, 275725, 177424, 300301, 349464, 283939, 259367, 283951, 292143, 300344, 226617, 283963, 243003, 226628, 283973, 300357, 177482, 283983, 316758, 357722, 316766, 218464, 292192, 316768, 292197, 316774, 243046, 218473, 284010, 136562, 324978, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 316811, 226699, 316814, 226703, 300433, 234899, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 284076, 144812, 144814, 284084, 144820, 284087, 292279, 144826, 144828, 144830, 144832, 284099, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 218597, 292329, 300523, 259565, 259567, 300527, 308720, 226802, 316917, 308727, 292343, 300537, 316947, 308757, 308762, 284191, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 284213, 194101, 284215, 194103, 284218, 226877, 284223, 284226, 243268, 284228, 226886, 284231, 128584, 292421, 284234, 366155, 276043, 317004, 284238, 226895, 284241, 194130, 284243, 276052, 276053, 300628, 317015, 292433, 235097, 243290, 284251, 284249, 284253, 300638, 284255, 284247, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 276086, 284278, 292470, 292473, 284283, 276093, 284286, 276095, 284288, 292479, 276098, 284290, 325250, 284292, 292485, 292481, 284297, 317066, 284299, 317068, 276109, 284301, 284303, 276114, 284306, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 276137, 317098, 284329, 284331, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 276160, 358080, 284354, 358083, 276166, 284358, 358089, 276170, 284362, 276175, 284368, 276177, 284370, 317138, 284372, 358098, 284377, 276187, 284379, 284381, 284384, 284386, 358116, 276197, 317158, 284392, 325353, 284394, 358122, 284397, 276206, 284399, 358128, 358126, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 284418, 317187, 358146, 317191, 284428, 300816, 300819, 317207, 284440, 186139, 300828, 300830, 276255, 300832, 284449, 300834, 325408, 227109, 317221, 358183, 186151, 276268, 300845, 194351, 243504, 300850, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 153417, 284499, 276308, 284502, 317271, 178006, 276315, 292700, 284511, 227175, 292715, 300912, 284529, 292721, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 276365, 284564, 358292, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 284585, 317353, 276395, 292776, 292784, 276402, 161718, 358326, 276410, 276411, 358330, 276418, 276425, 301009, 301011, 301013, 292823, 358360, 301015, 301017, 292828, 276446, 153568, 276448, 276452, 276455, 292839, 292843, 276460, 276464, 178161, 276466, 227314, 276472, 325624, 317435, 276476, 276479, 276482, 276485, 276490, 292876, 276496, 317456, 317458, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 243762, 309298, 325685, 325689, 276539, 325692, 235579, 235581, 178238, 276544, 284739, 292934, 276553, 243785, 350293, 350295, 194649, 227418, 309337, 194654, 227423, 350302, 194657, 227426, 276579, 194660, 350308, 227430, 276583, 292968, 350313, 276586, 309354, 350316, 309348, 276590, 301167, 227440, 350321, 284786, 276595, 301163, 350325, 350328, 292985, 301178, 292989, 292993, 317570, 350339, 301185, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 276638, 350366, 153765, 284837, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 309450, 301258, 276685, 276689, 309462, 301272, 276699, 309468, 194780, 309471, 301283, 317672, 276713, 317674, 325867, 243948, 194801, 227571, 309491, 309494, 243960, 227583, 276735, 227587, 276739, 211204, 276742, 227596, 325910, 342298, 309530, 276766, 211232, 317729, 276775, 211241, 325937, 276789, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 276843, 293227, 276848, 293232, 186744, 211324, 227709, 317833, 178572, 285070, 285077, 178583, 227738, 317853, 276896, 317858, 342434, 285093, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 317951, 309764, 301575, 121352, 236043, 317963, 342541, 55822, 113167, 277011, 317971, 309779, 309781, 55837, 227877, 227879, 293417, 227882, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 129603, 318020, 301636, 301639, 301643, 285265, 399955, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 277106, 121458, 170618, 170619, 309885, 309888, 277122, 227975, 285320, 277128, 301706, 318092, 326285, 318094, 334476, 277136, 277139, 227992, 285340, 318108, 227998, 318110, 137889, 383658, 285357, 318128, 277170, 342707, 154292, 277173, 293555, 318132, 285368, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 137946, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 293666, 285474, 228135, 318248, 277291, 293677, 318253, 285489, 293685, 285494, 301880, 285499, 301884, 293696, 310080, 277314, 277317, 277322, 277329, 162643, 310100, 301911, 301913, 277337, 301921, 400236, 236397, 162671, 326514, 310134, 277368, 236408, 15224, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 293811, 293817, 293820, 203715, 326603, 293849, 293861, 228327, 228328, 228330, 318442, 228332, 277486, 326638, 318450, 293876, 293877, 285686, 302073, 285690, 244731, 121850, 293882, 302075, 293887, 277504, 277507, 277511, 277519, 293908, 293917, 293939, 318516, 277561, 277564, 7232, 310336, 293956, 277573, 228422, 310344, 277577, 293960, 277583, 203857, 293971, 310359, 236632, 277594, 138332, 277598, 285792, 277601, 203872, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 285817, 367737, 285821, 302205, 285824, 392326, 285831, 253064, 302218, 285835, 294026, 162964, 384148, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 285862, 277671, 302248, 64682, 277678, 228526, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 285958, 228617, 138505, 318742, 204067, 277798, 130345, 277801, 113964, 285997, 277804, 277807, 285999, 113969, 277811, 318773, 318776, 277816, 286010, 277819, 294204, 417086, 277822, 286016, 302403, 294211, 384328, 277832, 277836, 294221, 326991, 277839, 277842, 277847, 277850, 179547, 277853, 146784, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 351619, 294276, 310659, 327046, 277892, 253320, 310665, 277894, 277898, 318858, 277903, 310672, 277905, 351633, 277908, 277917, 310689, 277921, 130468, 228776, 277928, 277932, 310703, 277937, 130486, 310710, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 64966, 245191, 163272, 310727, 302534, 277959, 277963, 302541, 277966, 302543, 310737, 277971, 286169, 228825, 163290, 277978, 310749, 277981, 277984, 310755, 277989, 277991, 187880, 277995, 286188, 310764, 278000, 228851, 310772, 278003, 278006, 40440, 212472, 278009, 286203, 40443, 228864, 40448, 286214, 228871, 302603, 65038, 302614, 286233, 302617, 286240, 146977, 294435, 187939, 40484, 40486, 294439, 286248, 40488, 286246, 294440, 294443, 294445, 40491, 310831, 40499, 40502, 212538, 40507, 40511, 40513, 228933, 40521, 286283, 40525, 40527, 228944, 212560, 400976, 40533, 147032, 40537, 278109, 40541, 40544, 40548, 40550, 286312, 286313, 40552, 40554, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 310925, 286354, 278163, 302740, 122517, 278168, 327333, 229030, 212648, 278188, 302764, 278192, 319153, 278196, 319171, 302789, 294599, 278216, 294601, 302793, 278227, 229076, 319187, 286420, 286425, 319194, 278235, 229086, 278238, 286432, 294625, 294634, 302838, 319226, 286460, 171774, 278274, 302852, 278277, 302854, 294664, 311048, 352008, 319243, 311053, 302862, 319251, 294682, 278306, 188199, 294701, 278320, 319280, 319290, 229192, 302925, 188247, 237409, 294776, 360317, 294785, 327554, 40840, 40851, 294803, 188312, 294811, 319390, 294817, 319394, 40865, 294821, 309346, 294831, 180142, 188340, 40886, 319419, 294844, 294847, 309350, 309352, 393177, 294876, 294879, 294883, 294890, 311279, 278513, 237555, 278516, 311283, 278519, 237562 ]
8a48540fad79eb598cd21de15141db1eaa83356a
0af14f85bcafec64cbe956400f580bbe927b03a0
/Sources/GeoTrackKit/Core/Map/DefaultMapZoom.swift
76ef926da26bbf92be64b9a022f2fd0ad421c3ab
[ "CC-BY-3.0", "MIT" ]
permissive
intere/GeoTrackKit
d8a38a9e18510bb4f59987181fb5f7b8741cfa7d
6c49588f0be6570b4b980db9998939bb446341a4
refs/heads/develop
2023-09-04T04:47:54.529312
2023-03-17T05:52:58
2023-03-17T05:52:58
72,934,331
57
12
MIT
2023-08-24T02:45:31
2016-11-05T15:20:01
Swift
UTF-8
Swift
false
false
2,113
swift
// // DefaultMapZoom.swift // GeoTrackKit // // Created by Internicola, Eric on 3/14/17. // // import CoreLocation import MapKit /// This is an implementation of the default map zooming. It basically just states that you should always /// zoom to fit the points (whenever a redraw on the map is requested) and it calculates a zoom region /// that has a very tiny amount of padding around the points open class DefaultMapZoom: ZoomDefining { /// Yes, let's zoom in public var shouldZoom: Bool { return true } /// initializer public init() { } /// Provides a zoom region for the provided points /// /// - Parameter points: The points to calculate the zoom region for. /// - Returns: The zoom region that allows you to see all of the points. public func zoomRegion(for points: [CLLocation]) -> MKCoordinateRegion { return getZoomRegion(points) } /// helper that will figure out what region on the map should be visible, based on your current points. /// /// - Parameter points: the points to analyze to determine the zoom window. /// - Returns: A zoom region. func getZoomRegion(_ points: [CLLocation]) -> MKCoordinateRegion { var region = MKCoordinateRegion() var maxLat: CLLocationDegrees = -90 var maxLon: CLLocationDegrees = -180 var minLat: CLLocationDegrees = 90 var minLon: CLLocationDegrees = 180 for point in points { maxLat = max(maxLat, point.coordinate.latitude) maxLon = max(maxLon, point.coordinate.longitude) minLat = min(minLat, point.coordinate.latitude) minLon = min(minLon, point.coordinate.longitude) } region.center.latitude = (maxLat + minLat) / 2 region.center.longitude = (maxLon + minLon) / 2 region.span.latitudeDelta = maxLat - minLat + 0.01 region.span.longitudeDelta = maxLon - minLon + 0.01 if points.count < 4 { region.span.latitudeDelta = 0.0005 region.span.longitudeDelta = 0.001 } return region } }
[ -1 ]
6406a9f3329ecda7babcb5c4108ad7b110b1c661
30f3ae0e43c4b9a34ec3b995190c6fb87c02abfd
/tableViewDataSourceDemo/ALNTableViewCell.swift
30e6b8460a1b4ea3c49d1dd86351cf9bd30f89a3
[]
no_license
LiMaoAtCD/tableViewDataSourceDemo
8793ef77a972d301fd75b109a1282fecfddb5cab
5fff42119885d151fb4d1bf3c11a4dc525ef9c66
refs/heads/master
2021-05-30T08:11:46.149749
2015-12-18T14:59:15
2015-12-18T14:59:15
null
0
0
null
null
null
null
UTF-8
Swift
false
false
537
swift
// // ALNTableViewCell.swift // tableViewDataSourceDemo // // Created by AlienLi on 15/12/18. // Copyright © 2015年 MarcoLi. All rights reserved. // import UIKit class ALNTableViewCell: UITableViewCell { @IBOutlet weak var title: UILabel! override func awakeFromNib() { super.awakeFromNib() // Initialization code } override func setSelected(selected: Bool, animated: Bool) { super.setSelected(selected, animated: animated) // Configure the view for the selected state } }
[ 211843, 225159, 418826, 302475, 227219, 276390, 199212, 327344, 282934, 281014, 276406, 299965, 299968, 142532, 379078, 282576, 273105, 393173, 282584, 228188, 226782, 155614, 155243, 375532, 113524, 222838, 230522, 285694 ]
912d5279168aea4358d1da838344e73db4fd0475
aa784887392f32c5192942f0eb382d8137abbe91
/TestRxSwift-101/TestRxSwift-101/TranditionalViewController.swift
3814fda56cbdde86766dc5d2d28b308fcb92f630
[]
no_license
HanShoujun/TestThingsWithSwift
9b8825ed2972bd1a054ef7177d7a3dc9b8c0a971
23e0e67a88d63e1b95c58efedc5a43bc0e176312
refs/heads/master
2020-06-04T13:07:41.386432
2019-08-29T08:11:55
2019-08-29T08:11:55
192,032,953
0
0
null
null
null
null
UTF-8
Swift
false
false
1,702
swift
// // TranditionalViewController.swift // TestRxSwift-101 // // Created by hsj on 2019/6/23. // Copyright © 2019 hsj. All rights reserved. // import UIKit class TranditionalViewController: UIViewController { @IBOutlet weak var tableView: UITableView! let viewModel = MusicViewModel() override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view. tableView.dataSource = self tableView.delegate = self } /* // MARK: - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation override func prepare(for segue: UIStoryboardSegue, sender: Any?) { // Get the new view controller using segue.destination. // Pass the selected object to the new view controller. } */ } extension TranditionalViewController: UITableViewDataSource { func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return viewModel.data.count } func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { let cell = tableView.dequeueReusableCell(withIdentifier: "musicCell")! let model = viewModel.data[indexPath.row] cell.textLabel?.text = model.name cell.detailTextLabel?.text = model.singer return cell } } extension TranditionalViewController: UITableViewDelegate { func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { tableView.deselectRow(at: indexPath, animated: true) let model = viewModel.data[indexPath.row] print(model) } }
[ -1 ]
cb028ebc3f7710ce760219ffbd81d2bfbee46460
ba97b1c34e282cc74cfe78eee1aa2752ff067df5
/LongestPalindrome2.playground/Contents.swift
47510bc5989e00a3c2c562a0876a13b083bfe2db
[]
no_license
ampyf/LeetPlayground
614d0e3dd21946a070c572c53ff3b27b1deb9dd6
e601f094b29a1610fcbf989e9544b16c4e27822d
refs/heads/master
2021-01-22T23:01:03.734677
2017-04-06T15:31:17
2017-04-06T15:31:17
85,599,247
0
0
null
null
null
null
UTF-8
Swift
false
false
4,398
swift
//: Playground - noun: a place where people can play import UIKit /* func isPalindrome(s: [Character]) -> Bool { let lastIdx = s.count - 1 let midPoint = Int(floor(Double(s.count/2))) for i in 0...midPoint { if s[i] != s[lastIdx-i] { return false } } return true } func isPalindrome(s: [Character]) -> Bool { let lastIdx = s.count - 1 let midPoint = Int(floor(Double(s.count/2))) let s1End = midPoint > 0 ? midPoint-1 : 0 let s2Start = midPoint <= 0 ? 0 : (s.count % 2 == 0 ? midPoint : midPoint+1) // print ("\(s.count) \(midPoint) \(s1End) \(s2Start)") let s1 = Array(s[0...s1End]) let s2 = Array(Array(s[s2Start...lastIdx]).reversed()) // print ("\(s1) \(s2)") return s1 == s2 } */ /* public class Solution { public String longestPalindrome(String s) { String result = ""; for(int i=0; i<s.length(); i++){ String str = palindrome(s, i, i); if(result.length() < str.length()) result = str; str = palindrome(s, i, i+1); if(result.length() < str.length()) result = str; } return result; } String palindrome(String s, int left, int right){ while(left>=0 && right<s.length() && s.charAt(left) == s.charAt(right)){ left--; right++; } return s.substring(left+1,right); } } */ func palindrome(_ sArray: [Character], l: Int, r : Int) -> [Character] { var left = l, right = r while left >= 0 && right < sArray.count && sArray[left] == sArray[right] { left -= 1 right += 1 } return Array(sArray[left...right]) } func longestPalindrome(_ s: String) -> String { print ("here") if s.characters.count == 0 { return "" } let sArray = Array(s.characters) var longestPalindrome = [Character]() for i in 0..<sArray.count { var temp = palindrome(sArray, l: i, r: i) if temp.count > longestPalindrome.count { longestPalindrome = temp } temp = palindrome(sArray, l: i, r: i+1) if temp.count > longestPalindrome.count { longestPalindrome = temp } } print (String(longestPalindrome)) return String(longestPalindrome) } longestPalindrome("cbbd") /* func longestPalindrome(_ s: String) -> String { let sArray = Array(s.characters) var longestPalindrome = [Character]() for length in (1...sArray.count).reversed() { for i in 0...sArray.count-length { let subarray = Array(sArray[i..<i+length]) if subarray.count > longestPalindrome.count { if isPalindrome(s: subarray) { longestPalindrome = subarray } } else { return String(longestPalindrome) } } } return String(longestPalindrome) } */ /* func longestPalindrome(_ s: String) -> String { let sArray = Array(s.characters) let count = sArray.count var longestPalindrome = [Character]() for i in 0..<count { var workingArray = [Character]() for j in i..<count { workingArray.append(sArray[j]) if isPalindrome(s: workingArray) { if workingArray.count > longestPalindrome.count { longestPalindrome = workingArray } } } } return String(longestPalindrome) } */ //longestPalindrome("babad") //longestPalindrome("civilwartestingwhetherthatnaptionoranynartionsoconceivedandsodedicatedcanlongendureWeareqmetonagreatbattlefiemldoftzhatwarWehavecometodedicpateaportionofthatfieldasafinalrestingplaceforthosewhoheregavetheirlivesthatthatnationmightliveItisaltogetherfangandproperthatweshoulddothisButinalargersensewecannotdedicatewecannotconsecratewecannothallowthisgroundThebravelmenlivinganddeadwhostruggledherehaveconsecrateditfaraboveourpoorponwertoaddordetractTgheworldadswfilllittlenotlenorlongrememberwhatwesayherebutitcanneverforgetwhattheydidhereItisforusthelivingrathertobededicatedheretotheulnfinishedworkwhichtheywhofoughtherehavethusfarsonoblyadvancedItisratherforustobeherededicatedtothegreattdafskremainingbeforeusthatfromthesehonoreddeadwetakeincreaseddevotiontothatcauseforwhichtheygavethelastpfullmeasureofdevotionthatweherehighlyresolvethatthesedeadshallnothavediedinvainthatthisnationunsderGodshallhaveanewbirthoffreedomandthatgovernmentofthepeoplebythepeopleforthepeopleshallnotperishfromtheearth")
[ -1 ]
02e4307777488e769ac307677d396faa882a21a4
3f456dd69d33eec3043cf9951aa90ddbf8207834
/FactoryWeather/Common/Utilities/Conditions.swift
fbaaa41e81082fb46b8ed2e9be473113b896a7b9
[]
no_license
matej494/FactoryWeather
91a4916933a02d6f65a2cfa4ad35fc50cd5d3824
dd5ba37d11c0791deb973431d6c05d8594ed18c3
refs/heads/develop
2020-03-26T05:40:36.656740
2019-01-22T09:00:28
2019-01-22T09:00:28
144,568,748
1
0
null
2019-01-22T09:00:30
2018-08-13T11:10:56
Swift
UTF-8
Swift
false
false
649
swift
// // Conditions.swift // FactoryWeather // // Created by Matej Korman on 22/08/2018. // Copyright © 2018 Matej Korman. All rights reserved. // import Foundation struct Conditions: OptionSet { let rawValue: Int static let humidity = Conditions(rawValue: 1) static let windSpeed = Conditions(rawValue: 2) static let pressure = Conditions(rawValue: 4) static let all: Conditions = [.humidity, .windSpeed, .pressure] mutating func toggle(condition: Conditions) { if self.contains(condition) { self.remove(condition) } else { self.insert(condition) } } }
[ -1 ]
7874b1d5347a95004475bd5c12d5aba8ffdc3d80
439fc26947125eaeb8f3e9bdf55652d85b765513
/Peat/TagUserTableViewCell.swift
1a06e0219ae638772c18860a9a1867822847274a
[]
no_license
barthdamon/peat-ios
e3127ab49ec6e2dded23e1e8a241d6739c57c3ed
deadfc74cc9eaad5cf75fef34de860ffd9234d9a
refs/heads/master
2021-03-27T09:15:38.875332
2016-03-17T20:57:49
2016-03-17T20:57:49
42,903,530
0
0
null
null
null
null
UTF-8
Swift
false
false
922
swift
// // TagUserTableViewCell.swift // Peat // // Created by Matthew Barth on 2/25/16. // Copyright © 2016 Matthew Barth. All rights reserved. // import UIKit class TagUserTableViewCell: UITableViewCell { @IBOutlet weak var avatarImageView: UIImageView! @IBOutlet weak var usernameLabel: UILabel! @IBOutlet weak var nameLabel: UILabel! var user: User? func configureWithUser(user: User) { if let name = user.name, username = user.username { self.usernameLabel.text = username self.nameLabel.text = name } user.generateAvatarImage { (image) -> () in self.avatarImageView.contentMode = .ScaleAspectFill self.avatarImageView.image = image } self.backgroundColor = UIColor.whiteColor() self.user = user //do the thumbnail dance, needs to be refactored probly } func setTagged() { self.backgroundColor = UIColor.lightGrayColor() } }
[ -1 ]
3b9ad74ff7db407fe25644cd8fdb9daef918058a
69460dc10253b78d7f02e9d67384126d3baac8ae
/HypeCloudKit/HypeCloudKit/Helpers/UserError.swift
541b2262535554538f6411575c84273f6fd8b6dd
[]
no_license
maxpoff/HypeCloudKit
3f94868406621bbfa56661fd928f1793c55662fe
a623afa0d89170ef17c5bba8394da7627d6293b0
refs/heads/master
2020-12-28T09:16:09.588957
2020-02-06T22:12:56
2020-02-06T22:12:56
238,262,793
0
0
null
null
null
null
UTF-8
Swift
false
false
296
swift
// // UserError.swift // HypeCloudKit // // Created by Maxwell Poffenbarger on 2/6/20. // Copyright © 2020 Maxwell Poffenbarger. All rights reserved. // import Foundation enum UserError: LocalizedError { case ckError(Error) case noUserLoggedIn case couldNotUnwrap }
[ -1 ]
a38ebd70dd562e0cd33397ca5a3666f9d19eed76
a4c6f68702ceb1f70273dd94b970190ab4d80ec5
/Swift-Project-06/Swift-Project-06/AppDelegate.swift
4d6314f01c0e5e1edc3bbf2aabb74170dcb2a2fc
[]
no_license
NSMichael/SampleCode
484bf4ed94154ccf5e2f94838384f2f81ed01661
3537c3824298b46b63fc61961af0c4cfbe09af68
refs/heads/master
2021-01-19T03:49:01.308332
2017-03-30T07:41:51
2017-03-30T07:41:51
84,416,431
2
0
null
null
null
null
UTF-8
Swift
false
false
2,179
swift
// // AppDelegate.swift // Swift-Project-06 // // Created by 耿功发 on 2017/3/16. // Copyright © 2017年 Appcoda. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 294924, 229388, 278542, 229391, 327695, 278545, 229394, 278548, 229397, 229399, 229402, 352284, 229405, 278556, 278559, 229408, 278564, 294950, 229415, 229417, 327722, 237613, 229422, 360496, 229426, 237618, 229428, 311349, 286774, 286776, 319544, 286778, 204856, 229432, 352318, 286791, 237640, 286797, 278605, 311375, 163920, 237646, 196692, 319573, 311383, 278623, 278626, 319590, 311400, 278635, 303212, 278639, 131192, 278648, 237693, 303230, 327814, 303241, 131209, 417930, 303244, 311436, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 237807, 303345, 286962, 303347, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 295220, 287032, 155966, 319809, 319810, 278849, 319814, 311623, 319818, 311628, 229709, 319822, 287054, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 319879, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 287202, 279010, 279015, 172520, 319978, 279020, 172526, 311791, 279023, 172529, 279027, 319989, 172534, 180727, 164343, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 172550, 303623, 172552, 320007, 287238, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 213575, 172618, 303690, 33357, 287309, 303696, 279124, 172634, 262752, 172644, 311911, 189034, 295533, 172655, 172656, 352880, 295538, 189039, 172660, 287349, 189040, 189044, 287355, 287360, 295553, 172675, 295557, 311942, 303751, 287365, 352905, 311946, 279178, 287371, 311951, 287377, 172691, 287381, 311957, 221850, 287386, 230045, 172702, 287390, 303773, 172705, 287394, 172707, 303780, 164509, 287398, 205479, 279208, 287400, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 287423, 328384, 172737, 279231, 287427, 312005, 312006, 107208, 172748, 287436, 107212, 172751, 287440, 295633, 172755, 303827, 279255, 172760, 287450, 303835, 279258, 189149, 303838, 213724, 312035, 279267, 295654, 279272, 230128, 312048, 312050, 230131, 205564, 303871, 230146, 328453, 295685, 230154, 33548, 312077, 295695, 295701, 230169, 369433, 295707, 328476, 295710, 230175, 295720, 303914, 279340, 205613, 279353, 230202, 312124, 328508, 222018, 295755, 377676, 148302, 287569, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303981, 303985, 303987, 328563, 279413, 303991, 303997, 295806, 295808, 295813, 304005, 320391, 304007, 213895, 304009, 304011, 230284, 304013, 295822, 279438, 189325, 189329, 295825, 304019, 189331, 213902, 58262, 304023, 304027, 279452, 234648, 410526, 279461, 279462, 304042, 213931, 230327, 304055, 287675, 197564, 230334, 304063, 238528, 304065, 213954, 189378, 156612, 295873, 213963, 197580, 312272, 304084, 304090, 320481, 304106, 320490, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 230413, 295949, 197645, 320528, 140312, 295961, 238620, 197663, 304164, 304170, 304175, 238641, 312374, 238652, 238655, 230465, 238658, 336964, 132165, 296004, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 296040, 361576, 205931, 296044, 279661, 205934, 164973, 312432, 279669, 337018, 189562, 279679, 304258, 279683, 222340, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 238766, 165038, 230576, 238770, 304311, 230592, 312518, 279750, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 320740, 279781, 304360, 320748, 279788, 279790, 304370, 296189, 320771, 312585, 296202, 296205, 230674, 320786, 230677, 296213, 296215, 320792, 230681, 230679, 214294, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 296253, 222525, 296255, 312639, 230718, 296259, 378181, 296262, 230727, 238919, 296264, 320840, 296267, 296271, 222545, 230739, 312663, 222556, 337244, 230752, 312676, 230760, 173418, 148843, 410987, 230763, 230768, 296305, 312692, 230773, 304505, 304506, 181626, 279929, 181631, 148865, 312711, 312712, 296331, 288140, 288144, 230800, 304533, 337306, 288154, 288160, 173472, 288162, 288164, 279975, 304555, 370092, 279983, 173488, 288176, 279985, 312755, 296373, 312759, 337335, 288185, 279991, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 288210, 370130, 288212, 222676, 148946, 288214, 239064, 329177, 288217, 280027, 288220, 288218, 239070, 288224, 280034, 288226, 280036, 288229, 280038, 288230, 288232, 370146, 288234, 320998, 288236, 288238, 288240, 288242, 296435, 288244, 288250, 296446, 321022, 402942, 148990, 296450, 206336, 230916, 230919, 214535, 230923, 304651, 304653, 370187, 402969, 230940, 222752, 108066, 296486, 296488, 157229, 230961, 157236, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 288344, 280152, 239194, 280158, 403039, 370272, 181854, 239202, 370279, 312938, 280183, 280185, 280188, 280191, 116354, 280194, 280208, 280211, 288408, 280218, 280222, 419489, 190118, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 419522, 313027, 280260, 419525, 206536, 280264, 206539, 206541, 206543, 313044, 280276, 321239, 280283, 313052, 18140, 288478, 313055, 321252, 313066, 288494, 280302, 280304, 313073, 321266, 419570, 288499, 288502, 280314, 288510, 124671, 67330, 280324, 198405, 288519, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 280388, 337732, 304968, 280393, 280402, 173907, 313171, 313176, 42842, 280419, 321381, 296809, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 214944, 280487, 313258, 321458, 296883, 124853, 214966, 296890, 10170, 288700, 296894, 190403, 296900, 280515, 337862, 165831, 280521, 231379, 296921, 354265, 354270, 239586, 313320, 354281, 231404, 124913, 165876, 321528, 239612, 313340, 288764, 239617, 313347, 288773, 313358, 305176, 321560, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 321595, 378941, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 149599, 280671, 149601, 321634, 149603, 223327, 329830, 280681, 313451, 223341, 280687, 149618, 215154, 313458, 280691, 313464, 329850, 321659, 280702, 288895, 321670, 215175, 141446, 288909, 141455, 141459, 280725, 313498, 100520, 288936, 280747, 288940, 288947, 280755, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 125171, 157940, 280819, 182517, 280823, 280825, 280827, 280830, 280831, 280833, 125187, 280835, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 305464, 280891, 289087, 280897, 280900, 305480, 239944, 280906, 239947, 305485, 305489, 379218, 280919, 248153, 215387, 354653, 354656, 313700, 313705, 280937, 190832, 280946, 223606, 313720, 280956, 239997, 280959, 313731, 199051, 240011, 289166, 240017, 297363, 190868, 240021, 297365, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 289210, 305594, 281024, 289218, 289221, 289227, 436684, 281045, 281047, 215526, 166378, 305647, 281075, 174580, 240124, 281084, 305662, 305664, 240129, 305666, 305668, 223749, 330244, 281095, 223752, 150025, 338440, 240132, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 338528, 338532, 281190, 199273, 281196, 19053, 158317, 313973, 297594, 281210, 158347, 264845, 182926, 133776, 182929, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 297671, 158409, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 289593, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 158596, 183172, 338823, 322440, 314249, 240519, 183184, 289687, 240535, 224151, 297883, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 183260, 420829, 281567, 289762, 322534, 297961, 183277, 281581, 322550, 134142, 322563, 314372, 330764, 175134, 322599, 322610, 314421, 281654, 314427, 314433, 207937, 314441, 207949, 322642, 314456, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 289912, 248995, 306341, 306344, 306347, 322734, 306354, 142531, 199877, 289991, 306377, 289997, 249045, 363742, 363745, 298216, 330988, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 380226, 298306, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 290171, 314747, 306555, 298365, 290174, 224641, 281987, 298372, 314756, 281990, 224647, 265604, 298377, 314763, 142733, 298381, 314768, 224657, 306581, 314773, 314779, 314785, 314793, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 191992, 290298, 151036, 290302, 282111, 290305, 175621, 306694, 192008, 323084, 257550, 282127, 290321, 282130, 323090, 290325, 282133, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 28219, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 323176, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 282255, 282261, 175770, 298651, 282269, 323229, 298655, 323231, 61092, 282277, 306856, 282295, 323260, 282300, 323266, 282310, 323273, 282319, 306897, 241362, 306904, 282328, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 241450, 282410, 306988, 306991, 315184, 323376, 315190, 241464, 159545, 282425, 298811, 118593, 307009, 413506, 307012, 241475, 298822, 315211, 282446, 307027, 315221, 323414, 315223, 241496, 241498, 307035, 307040, 110433, 282465, 241509, 110438, 298860, 110445, 282478, 315249, 110450, 315251, 282481, 315253, 315255, 339838, 315267, 282499, 315269, 241544, 282505, 241546, 241548, 298896, 298898, 282514, 241556, 298901, 44948, 241560, 282520, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 36779, 241581, 282542, 241583, 323504, 241586, 282547, 241588, 290739, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 299003, 241661, 299006, 282623, 315396, 241669, 315397, 282632, 307211, 282639, 290835, 282645, 241693, 282654, 241701, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 307290, 217179, 315482, 192605, 315483, 233567, 299105, 200801, 217188, 299109, 307303, 315495, 356457, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 315524, 307338, 233613, 241813, 307352, 299164, 299167, 315552, 184479, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 323763, 184503, 176311, 299191, 307386, 258235, 307388, 307385, 307390, 176316, 299200, 184512, 307394, 299204, 307396, 184518, 307399, 323784, 233679, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 282893, 323854, 291089, 282906, 291104, 233766, 295583, 176435, 307508, 315701, 332086, 307510, 307512, 168245, 307515, 307518, 282942, 282947, 323917, 110926, 282957, 233808, 323921, 315733, 323926, 233815, 276052, 315739, 323932, 299357, 242018, 242024, 299373, 315757, 250231, 242043, 315771, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 315801, 283033, 242075, 291226, 194654, 61855, 291231, 283042, 291238, 291241, 127403, 127405, 291247, 299440, 127407, 299444, 127413, 283062, 291254, 127417, 291260, 283069, 127421, 127424, 299457, 127429, 127431, 127434, 315856, 176592, 127440, 315860, 176597, 283095, 127447, 299481, 127449, 176605, 242143, 127455, 127457, 291299, 340454, 127463, 242152, 291305, 127466, 176620, 127469, 127474, 291314, 291317, 127480, 135672, 291323, 233979, 127485, 291330, 127490, 283142, 127494, 127497, 233994, 135689, 127500, 291341, 233998, 127506, 234003, 127509, 234006, 127511, 152087, 283161, 242202, 234010, 135707, 135710, 242206, 242208, 291361, 242220, 291378, 152118, 234038, 234041, 315961, 70213, 242250, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 135808, 291456, 373383, 299655, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 299684, 135844, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 299726, 225998, 226002, 119509, 226005, 226008, 299740, 242396, 201444, 299750, 283368, 234219, 283372, 185074, 226037, 283382, 316151, 234231, 234236, 226045, 242431, 234239, 209665, 234242, 299778, 242436, 226053, 234246, 226056, 234248, 291593, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 234269, 283421, 234272, 234274, 152355, 299814, 234278, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 160572, 283452, 234302, 234307, 242499, 234309, 316233, 234313, 316235, 234316, 283468, 234319, 242511, 234321, 234324, 185173, 201557, 234329, 234333, 308063, 234336, 242530, 349027, 234338, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 177011, 234356, 234358, 234362, 226171, 234364, 291711, 234368, 291714, 234370, 291716, 234373, 316294, 201603, 226182, 308105, 234375, 226185, 234379, 324490, 234384, 234388, 234390, 324504, 234393, 209818, 308123, 324508, 234396, 291742, 226200, 234398, 234401, 291747, 291748, 234405, 291750, 234407, 324520, 324518, 324522, 234410, 291756, 291754, 226220, 324527, 291760, 234417, 201650, 324531, 234414, 234422, 226230, 324536, 275384, 234428, 291773, 242623, 324544, 234431, 234434, 324546, 324548, 234437, 226245, 234439, 226239, 234443, 291788, 234446, 275406, 193486, 234449, 316370, 193488, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 234487, 324599, 234490, 234493, 316416, 234496, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 316439, 234520, 234519, 234523, 234526, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 144430, 234543, 234546, 275508, 300085, 234549, 300088, 234553, 234556, 234558, 316479, 234561, 316483, 160835, 234563, 308291, 234568, 234570, 316491, 234572, 300108, 234574, 300115, 234580, 234581, 242777, 234585, 275545, 234590, 234593, 234595, 234597, 300133, 234601, 300139, 234605, 160879, 234607, 275569, 234610, 316530, 300148, 234614, 398455, 144506, 234618, 234620, 275579, 234623, 226433, 234627, 275588, 234629, 242822, 234634, 234636, 177293, 234640, 275602, 234643, 308373, 226453, 234647, 275606, 275608, 234650, 308379, 324757, 300189, 324766, 119967, 234653, 324768, 283805, 234657, 242852, 300197, 234661, 283813, 234664, 275626, 234667, 316596, 308414, 234687, 300223, 300226, 308418, 234692, 300229, 308420, 308422, 283844, 226500, 300234, 283850, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 300267, 161003, 300270, 300272, 120053, 300278, 275703, 316663, 300284, 275710, 300287, 292097, 300289, 161027, 300292, 300294, 275719, 234760, 177419, 300299, 242957, 300301, 283917, 177424, 349451, 275725, 349464, 415009, 283939, 259367, 292143, 283951, 300344, 226617, 243003, 283963, 226628, 300357, 283973, 177482, 283983, 316758, 357722, 316766, 316768, 292192, 218464, 292197, 316774, 243046, 218473, 284010, 136562, 324978, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 316811, 226699, 316814, 226703, 300433, 234899, 300436, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 144812, 284076, 144814, 227426, 144820, 374196, 284084, 292279, 284087, 144826, 144828, 144830, 144832, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 226787, 218597, 292329, 300523, 259565, 300527, 308720, 259567, 292338, 226802, 316917, 292343, 308727, 300537, 316933, 316947, 308757, 308762, 284191, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 194101, 284213, 316983, 194103, 284215, 308790, 284218, 226877, 292414, 284223, 284226, 284228, 292421, 226886, 284231, 128584, 243268, 284234, 366155, 317004, 276043, 284238, 226895, 284241, 194130, 284243, 300628, 284245, 292433, 284247, 317015, 235097, 243290, 276053, 284249, 284251, 300638, 284253, 284255, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 284278, 292470, 276086, 292473, 284283, 276093, 284286, 292479, 284288, 292481, 284290, 325250, 284292, 292485, 325251, 276095, 276098, 284297, 317066, 284299, 317068, 284301, 276109, 284303, 284306, 276114, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 284329, 317098, 284331, 276137, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 358080, 276160, 284354, 358083, 284358, 276166, 358089, 284362, 276170, 284365, 276175, 284368, 276177, 284370, 358098, 284372, 317138, 284377, 276187, 284379, 284381, 284384, 358114, 284386, 358116, 276197, 317158, 358119, 284392, 325353, 358122, 284394, 284397, 358126, 284399, 358128, 276206, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 358146, 317187, 284418, 317189, 317191, 284428, 300816, 300819, 317207, 284440, 300828, 300830, 276255, 300832, 325408, 300834, 317221, 227109, 358183, 186151, 276268, 300845, 243504, 300850, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 292681, 153417, 358224, 284499, 276308, 284502, 317271, 178006, 276315, 292700, 317279, 284511, 227175, 292715, 300912, 292721, 284529, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 276365, 317332, 358292, 284564, 399252, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 317353, 284585, 276395, 292776, 292784, 276402, 358326, 161718, 358330, 276410, 276411, 276418, 276425, 301009, 301011, 301013, 292823, 358360, 301017, 301015, 292828, 276446, 153568, 276448, 276452, 292839, 276455, 350186, 292843, 276460, 276464, 178161, 227314, 276466, 325624, 350200, 276472, 317435, 276476, 276479, 276482, 350210, 276485, 317446, 178181, 276490, 350218, 292876, 350222, 317456, 276496, 317458, 178195, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 178224, 243762, 309298, 325685, 325689, 235579, 325692, 235581, 178238, 276539, 276544, 243779, 325700, 284739, 292934, 243785, 276553, 350293, 350295, 309337, 194649, 227418, 350299, 350302, 227423, 350304, 178273, 309346, 194657, 194660, 350308, 309350, 309348, 292968, 309352, 309354, 301163, 350313, 350316, 227430, 301167, 276583, 350321, 276590, 284786, 276595, 350325, 252022, 227440, 350328, 292985, 301178, 350332, 292989, 301185, 292993, 350339, 317570, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 350366, 276638, 284837, 153765, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 301258, 309450, 276685, 309455, 276689, 309462, 301272, 276699, 194780, 309468, 309471, 301283, 317672, 317674, 325867, 243948, 194801, 309491, 227571, 309494, 243960, 276735, 227583, 227587, 276739, 211204, 276742, 227593, 227596, 325910, 309530, 342298, 211232, 317729, 276775, 211241, 325937, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 293227, 276843, 293232, 276848, 186744, 211324, 227709, 285061, 366983, 317833, 178572, 285070, 285077, 178583, 227738, 317853, 276896, 317858, 342434, 285093, 317864, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 129486, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 293370, 317951, 309764, 301575, 121352, 293387, 236043, 342541, 317963, 113167, 55822, 309779, 317971, 309781, 277011, 55837, 227877, 227879, 293417, 227882, 309804, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 219714, 129603, 301636, 318020, 301639, 301643, 277071, 285265, 399955, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 309871, 121458, 277106, 170618, 170619, 309885, 309888, 277122, 227975, 277128, 285320, 301706, 318092, 326285, 334476, 318094, 277136, 277139, 227992, 318108, 285340, 318110, 227998, 137889, 383658, 285357, 318128, 277170, 293555, 318132, 342707, 154292, 277173, 285368, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 342745, 137946, 342747, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 56045, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 285474, 293666, 228135, 318248, 277291, 318253, 293677, 285489, 301876, 293685, 285494, 301880, 285499, 301884, 310080, 293696, 277317, 277322, 293706, 277329, 162643, 310100, 301911, 301913, 277337, 301921, 400236, 236397, 162671, 326514, 310134, 236408, 15224, 277368, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 276579, 293811, 293817, 293820, 203715, 326603, 342994, 276586, 293849, 293861, 228327, 228328, 318442, 228330, 228332, 326638, 277486, 351217, 318450, 293876, 293877, 285686, 302073, 121850, 293882, 302075, 285690, 244731, 293887, 277504, 277507, 277511, 293899, 277519, 293908, 302105, 293917, 293939, 318516, 277561, 277564, 310336, 7232, 293956, 277573, 228422, 293960, 310344, 277577, 277583, 203857, 293971, 310355, 310359, 236632, 277594, 138332, 277598, 203872, 277601, 285792, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 367737, 285817, 302205, 285821, 392326, 285831, 253064, 294026, 302218, 285835, 162964, 384148, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 302241, 285862, 277671, 302248, 64682, 277678, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 310486, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 285958, 138505, 228617, 318742, 204067, 277798, 130345, 277801, 113964, 285997, 384302, 285999, 277804, 113969, 277807, 277811, 318773, 318776, 277816, 286010, 277819, 294204, 417086, 277822, 286016, 302403, 294211, 384328, 277832, 277836, 294221, 146765, 294223, 326991, 277839, 277842, 277847, 277850, 179547, 277853, 146784, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 351619, 294276, 310659, 327046, 277892, 253320, 310665, 318858, 277894, 277898, 277903, 310672, 351633, 277905, 277908, 277917, 310689, 277921, 130468, 228776, 277928, 277932, 310703, 277937, 310710, 130486, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 302534, 310727, 245191, 64966, 163272, 277959, 277963, 302541, 277966, 302543, 310737, 277971, 228825, 163290, 277978, 310749, 277981, 277984, 310755, 277989, 277991, 187880, 277995, 310764, 286188, 278000, 228851, 310772, 278003, 278006, 40440, 212472, 278009, 40443, 286203, 310780, 40448, 228864, 286214, 228871, 302603, 65038, 302614, 302617, 286233, 302621, 286240, 146977, 187936, 187939, 40484, 294435, 40486, 286246, 294440, 40488, 294439, 294443, 40491, 294445, 278057, 310831, 245288, 286248, 40499, 40502, 212538, 40507, 40511, 40513, 228933, 327240, 40521, 286283, 40525, 40527, 212560, 400976, 228944, 40533, 147032, 40537, 40539, 40541, 278109, 40544, 40548, 40550, 40552, 286312, 40554, 286313, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 294537, 310925, 286354, 278163, 302740, 122517, 278168, 179870, 327333, 229030, 212648, 278188, 302764, 278192, 319153, 278196, 302781, 319171, 302789, 294599, 278216, 294601, 302793, 343757, 212690, 319187, 286420, 278227, 229076, 286425, 319194, 278235, 278238, 229086, 286432, 294625, 294634, 302838, 319226, 286460, 278274, 302852, 278277, 302854, 294664, 311048, 352008, 319243, 311053, 302862, 319251, 294682, 278306, 188199, 294701, 319280, 278320, 319290, 229192, 302925, 188247, 280021, 188252, 237409, 294776, 360317, 294785, 327554, 360322, 40840, 40851, 294803, 188312, 294811, 237470, 319390, 40865, 319394, 294817, 294821, 311209, 180142, 343983, 294831, 188340, 40886, 319419, 294844, 294847, 237508, 393177, 294876, 294879, 294883, 393190, 294890, 311279, 278513, 237555, 311283, 278516, 278519, 237562 ]
a9715c9016f144244ed4d6fd528e6dfed1b36b90
4a85a5e1857c627f7393682ace7ae1e77e805566
/MovieLists/MovieLists/SceneDelegate.swift
08be122f2e46285728070cee81117c1d5bf708c8
[ "MIT" ]
permissive
zinminphyo/MovieAppWithCoreData
f7940bfd47ebf3aa207954b1a302979096047c80
abd0ec9b4e681fc40b83e1d11335b850ea27883c
refs/heads/master
2020-12-04T05:16:17.882956
2020-01-03T16:53:06
2020-01-03T16:53:06
231,628,299
0
0
null
null
null
null
UTF-8
Swift
false
false
2,543
swift
// // SceneDelegate.swift // MovieLists // // Created by Zin Min Phyoe on 1/3/20. // Copyright © 2020 Zin Min Phyoe. All rights reserved. // import UIKit class SceneDelegate: UIResponder, UIWindowSceneDelegate { var window: UIWindow? func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`. // If using a storyboard, the `window` property will automatically be initialized and attached to the scene. // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). guard let _ = (scene as? UIWindowScene) else { return } } func sceneDidDisconnect(_ scene: UIScene) { // Called as the scene is being released by the system. // This occurs shortly after the scene enters the background, or when its session is discarded. // Release any resources associated with this scene that can be re-created the next time the scene connects. // The scene may re-connect later, as its session was not neccessarily discarded (see `application:didDiscardSceneSessions` instead). } func sceneDidBecomeActive(_ scene: UIScene) { // Called when the scene has moved from an inactive state to an active state. // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive. } func sceneWillResignActive(_ scene: UIScene) { // Called when the scene will move from an active state to an inactive state. // This may occur due to temporary interruptions (ex. an incoming phone call). } func sceneWillEnterForeground(_ scene: UIScene) { // Called as the scene transitions from the background to the foreground. // Use this method to undo the changes made on entering the background. } func sceneDidEnterBackground(_ scene: UIScene) { // Called as the scene transitions from the foreground to the background. // Use this method to save data, release shared resources, and store enough scene-specific state information // to restore the scene back to its current state. // Save changes in the application's managed object context when the application transitions to the background. (UIApplication.shared.delegate as? AppDelegate)?.saveContext() } }
[ 393221, 163849, 393228, 393231, 393251, 352294, 344103, 393260, 393269, 213049, 376890, 385082, 16444, 393277, 376906, 327757, 254032, 286804, 368728, 254045, 368736, 180322, 376932, 286833, 286845, 286851, 417925, 262284, 360598, 286880, 286889, 377003, 377013, 164029, 327872, 180418, 377030, 377037, 180432, 377047, 418008, 385243, 418012, 377063, 327915, 205037, 393457, 393461, 393466, 418044, 336124, 385281, 336129, 262405, 180491, 336140, 164107, 262417, 368913, 262423, 377118, 377121, 262437, 254253, 336181, 262455, 393539, 262473, 344404, 213333, 418135, 262497, 418145, 262501, 213354, 246124, 262508, 262512, 213374, 385420, 262551, 262553, 385441, 385444, 262567, 385452, 262574, 393649, 385460, 262587, 344512, 262593, 336326, 360917, 369119, 328178, 328180, 328183, 328190, 254463, 328193, 98819, 164362, 328204, 328207, 410129, 393748, 377372, 188959, 385571, 377384, 197160, 33322, 352822, 270905, 197178, 418364, 188990, 369224, 270922, 385610, 352844, 385617, 352865, 262761, 352875, 344694, 352888, 336513, 377473, 336517, 344710, 385671, 148106, 377485, 352919, 98969, 336549, 344745, 361130, 336556, 434868, 164535, 336568, 164539, 328379, 328387, 352969, 418508, 385743, 385749, 189154, 369382, 361196, 418555, 344832, 336644, 344837, 344843, 328462, 361231, 394002, 336660, 418581, 418586, 434971, 369436, 262943, 369439, 418591, 418594, 336676, 418600, 418606, 271154, 328498, 369464, 361274, 328516, 336709, 328520, 336712, 361289, 328523, 336715, 361300, 213848, 426842, 361307, 197469, 361310, 254813, 361318, 344936, 361323, 361335, 328574, 369544, 361361, 222129, 345036, 386004, 345046, 386012, 386019, 386023, 328690, 435188, 328703, 328710, 418822, 377867, 328715, 386070, 336922, 345119, 377888, 328747, 214060, 345134, 345139, 361525, 361537, 377931, 197708, 189525, 156762, 402523, 361568, 148580, 345200, 361591, 386168, 361594, 410746, 214150, 345224, 386187, 337048, 345247, 361645, 337072, 345268, 337076, 402615, 361657, 402636, 328925, 165086, 165092, 328933, 222438, 328942, 386286, 386292, 206084, 115973, 328967, 345377, 345380, 353572, 345383, 263464, 337207, 345400, 378170, 369979, 386366, 337224, 337230, 337235, 263509, 353634, 337252, 402792, 345449, 99692, 271731, 378232, 337278, 271746, 181639, 353674, 181644, 361869, 181650, 181655, 230810, 181671, 181674, 181679, 181682, 337330, 181687, 370105, 181691, 181697, 361922, 337350, 181704, 337366, 271841, 329192, 361961, 329195, 116211, 337399, 402943, 337416, 329227, 419341, 419345, 329234, 419351, 345626, 419357, 345631, 419360, 370208, 394787, 419363, 370214, 419369, 394796, 419377, 419386, 206397, 214594, 419401, 353868, 419404, 173648, 419408, 214611, 419412, 403040, 345702, 222831, 370298, 353920, 403076, 345737, 198282, 403085, 403092, 345750, 419484, 345758, 345763, 419492, 345766, 419498, 419502, 370351, 419507, 337588, 419510, 419513, 419518, 403139, 337607, 419528, 419531, 419536, 272083, 394967, 419543, 419545, 345819, 419548, 181982, 419551, 345829, 419560, 337643, 419564, 337647, 370416, 141052, 337661, 337671, 362249, 362252, 395022, 362256, 321300, 395033, 345888, 116512, 362274, 378664, 354107, 354112, 247618, 329545, 345932, 354124, 247639, 337751, 370520, 313181, 354143, 354157, 345965, 345968, 345971, 345975, 182136, 403321, 1914, 354173, 395148, 247692, 337809, 247701, 329625, 436127, 436133, 247720, 337834, 362414, 337845, 190393, 247760, 346064, 346069, 329699, 354275, 190440, 247790, 354314, 346140, 337980, 436290, 395340, 378956, 436307, 338005, 329816, 100454, 329833, 329853, 329857, 329868, 411806, 329886, 346273, 362661, 100525, 387250, 379067, 387261, 256193, 395467, 346317, 411862, 411865, 411869, 411874, 379108, 411877, 387303, 395496, 346344, 338154, 387307, 346350, 338161, 436474, 321787, 379135, 411905, 411917, 43279, 379154, 395539, 387350, 387353, 338201, 182559, 338212, 248112, 362823, 436556, 321880, 362844, 379234, 354674, 182642, 321911, 420237, 379279, 272787, 354728, 338353, 338363, 338382, 272849, 248279, 256474, 182755, 338404, 338411, 330225, 248309, 199165, 248332, 330254, 199182, 199189, 420377, 330268, 191012, 412215, 330320, 199250, 191069, 346722, 248427, 191085, 338544, 191093, 346743, 330384, 346769, 150184, 174775, 248505, 174778, 363198, 223936, 355025, 273109, 264919, 338661, 338665, 264942, 330479, 363252, 338680, 207620, 264965, 191240, 338701, 256787, 199455, 396067, 346917, 396070, 215854, 355123, 355141, 355144, 338764, 330581, 330585, 387929, 355167, 265056, 265059, 355176, 355180, 355185, 330612, 330643, 412600, 207809, 379849, 347082, 396246, 330711, 248794, 248799, 347106, 437219, 257009, 265208, 330750, 199681, 379908, 338951, 330761, 330769, 330775, 248863, 158759, 396329, 404526, 396337, 330803, 396340, 339002, 388155, 339010, 347208, 248905, 330827, 330830, 248915, 183384, 412765, 339037, 257121, 322660, 265321, 330869, 248952, 420985, 330886, 330890, 347288, 248986, 44199, 380071, 339118, 249018, 339133, 126148, 322763, 330959, 330966, 265433, 265438, 388320, 363757, 339199, 175376, 175397, 208167, 273709, 372016, 437553, 347442, 175416, 396601, 208189, 437567, 175425, 437571, 437576, 437584, 331089, 396634, 175451, 437596, 429408, 175458, 208228, 175461, 175464, 265581, 331124, 175478, 249210, 175484, 175487, 249215, 175491, 249219, 249225, 249228, 249235, 175514, 175517, 396703, 396706, 175523, 355749, 396723, 388543, 380353, 216518, 339401, 339406, 339414, 249303, 413143, 339418, 339421, 249310, 339425, 249313, 339429, 339435, 249329, 69114, 372229, 339464, 249355, 208399, 175637, 134689, 339504, 265779, 421442, 413251, 265796, 265806, 224854, 224858, 339553, 257636, 224871, 372328, 257647, 372338, 339572, 224885, 224888, 224891, 224895, 126597, 224905, 11919, 224911, 224914, 126611, 224917, 224920, 126618, 208539, 224923, 224927, 224930, 224933, 257705, 224939, 224943, 257713, 224949, 257717, 257721, 224954, 257725, 224960, 257733, 224966, 224970, 257740, 224976, 257745, 257748, 224982, 257752, 224987, 257762, 224996, 225000, 339696, 225013, 225021, 339711, 257791, 225027, 257796, 339722, 257805, 225039, 257808, 249617, 225044, 167701, 372500, 257815, 225049, 257820, 225054, 184096, 397089, 257825, 225059, 339748, 225068, 257837, 413485, 225071, 225074, 257843, 225077, 257846, 225080, 397113, 225083, 397116, 257853, 225088, 225094, 225097, 323404, 257869, 257872, 225105, 339795, 397140, 225109, 257881, 225113, 257884, 257887, 225120, 413539, 225128, 257897, 225138, 339827, 257909, 372598, 225142, 257914, 257917, 225150, 257922, 380803, 225156, 339845, 257927, 225166, 397201, 225171, 380823, 225176, 225183, 184245, 372698, 372704, 372707, 356336, 380919, 393215, 372739, 405534, 266295, 266298, 217158, 421961, 200786, 356440, 217180, 430181, 266351, 356467, 266365, 192640, 266375, 381069, 225425, 250003, 225430, 250008, 356507, 225439, 135328, 192674, 225442, 438434, 225445, 225448, 438441, 225451, 258223, 225456, 430257, 225459, 225462, 225468, 389309, 225472, 225476, 389322, 225485, 225488, 225491, 266454, 225494, 225497, 225500, 225503, 225506, 356580, 225511, 217319, 225515, 225519, 381177, 397572, 389381, 356631, 356638, 356641, 356644, 356647, 266537, 389417, 356650, 356656, 332081, 307507, 340276, 356662, 397623, 332091, 225599, 332098, 201030, 348489, 332107, 151884, 430422, 348503, 332118, 332130, 250211, 340328, 250217, 348523, 348528, 332153, 356734, 389503, 332158, 438657, 250239, 332162, 348548, 356741, 332175, 160152, 373146, 373149, 356783, 266688, 324032, 201158, 127473, 217590, 340473, 324095, 324100, 324103, 324112, 340501, 324118, 324122, 340512, 332325, 324134, 381483, 356908, 324141, 324143, 356917, 324150, 324156, 168509, 348734, 324161, 324165, 356935, 348745, 381513, 324171, 324174, 324177, 389724, 332381, 373344, 340580, 348777, 381546, 119432, 340628, 184983, 373399, 340639, 258723, 332455, 332460, 332464, 332473, 381626, 332484, 332487, 332494, 357070, 357074, 332512, 332521, 340724, 332534, 348926, 389927, 152371, 398141, 127815, 357202, 389971, 357208, 136024, 389979, 430940, 357212, 357215, 439138, 201580, 201583, 349041, 340850, 201589, 381815, 430967, 324473, 398202, 340859, 324476, 430973, 119675, 324479, 340863, 324482, 324485, 324488, 185226, 381834, 324493, 324496, 324499, 430996, 324502, 324511, 422817, 324514, 201638, 373672, 324525, 5040, 111539, 324534, 5047, 324539, 324542, 398280, 349129, 340940, 340942, 209874, 340958, 431073, 398307, 340964, 209896, 201712, 209904, 349173, 381947, 201724, 349181, 431100, 431107, 349203, 209944, 209948, 250915, 250917, 169002, 357419, 209966, 209969, 209973, 209976, 209980, 209988, 209991, 431180, 209996, 349268, 177238, 250968, 210011, 373853, 341094, 210026, 210028, 210032, 349296, 210037, 210042, 210045, 349309, 160896, 349313, 152704, 210053, 210056, 349320, 259217, 373905, 210068, 210072, 210078, 210081, 210085, 210089, 210096, 210100, 324792, 210108, 357571, 210116, 210128, 333010, 210132, 333016, 210139, 210144, 218355, 251123, 218361, 275709, 275713, 242947, 275717, 275723, 333075, 349460, 333079, 251161, 349486, 349492, 415034, 251211, 210261, 365912, 259423, 374113, 251236, 374118, 234867, 390518, 357756, 374161, 112021, 349591, 357793, 333222, 210357, 259516, 415168, 366035, 415187, 366039, 415192, 415194, 415197, 415200, 333285, 415208, 366057, 366064, 415217, 415225, 423424, 415258, 415264, 366118, 415271, 349739, 144940, 415279, 415282, 349748, 415286, 210488, 415291, 415295, 333387, 333396, 374359, 333400, 366173, 333415, 423529, 423533, 333423, 210547, 415354, 267910, 267929, 333472, 333512, 358100, 366301, 333535, 366308, 366312, 431852, 399086, 366319, 210673, 366322, 399092, 366326, 333566, 268042, 210700, 366349, 210707, 399129, 333593, 333595, 210720, 366384, 358192, 210740, 366388, 358201, 399166, 325441, 366403, 325447, 341831, 341835, 341839, 341844, 415574, 358235, 341852, 350046, 399200, 399208, 268144, 358256, 358260, 399222, 325494, 186233, 333690, 243584, 325505, 333699, 399244, 333709, 333725, 333737, 382891, 358336, 333767, 358348, 333777, 219094, 399318, 358372, 350190, 350194, 333819, 350204, 350207, 325633, 325637, 350214, 333838, 350225, 350232, 333851, 350238, 374819, 350245, 350249, 350252, 178221, 350257, 350272, 243782, 350281, 374865, 252021, 342134, 374904, 268435, 333989, 333998, 334012, 350411, 350417, 350423, 350426, 334047, 350449, 375027, 358645, 350454, 350459, 350462, 350465, 350469, 325895, 268553, 194829, 350477, 268560, 350481, 350487, 350491, 350494, 325920, 350500, 350505, 358701, 391469, 350510, 358705, 358714, 358717, 383307, 358738, 334162, 383331, 383334, 391531, 383342, 334204, 268669, 194942, 391564, 366991, 342431, 375209, 326059, 342453, 334263, 326087, 358857, 195041, 334306, 334312, 104940, 375279, 162289, 416255, 350724, 186898, 342546, 350740, 342551, 334359, 342555, 334364, 416294, 350762, 252463, 358962, 334386, 334397, 252483, 219719, 399957, 244309, 334425, 326240, 375401, 334466, 334469, 391813, 162446, 326291, 342680, 342685, 260767, 342711, 244410, 260798, 334530, 260802, 350918, 154318, 342737, 391895, 154329, 416476, 64231, 113389, 342769, 203508, 375541, 342777, 391938, 391949, 375569, 375572, 375575, 375580, 162592, 334633, 326444, 383794, 326452, 326455, 375613, 244542, 375616, 326468, 244552, 342857, 326474, 326479, 326486, 416599, 342875, 244572, 326494, 326503, 433001, 326508, 400238, 326511, 211826, 211832, 392061, 351102, 252801, 260993, 400260, 342921, 342931, 252823, 400279, 392092, 400286, 359335, 211885, 400307, 351169, 359362, 351172, 170950, 187335, 326599, 359367, 359383, 359389, 383968, 343018, 359411, 261109, 261112, 244728, 383999, 261130, 261148, 359452, 261155, 261160, 359471, 375868, 384099, 384102, 384108, 367724, 326764, 187503, 343155, 384115, 212095, 384136, 384140, 384144, 384152, 384158, 384161, 351399, 384169, 367795, 384182, 384189, 384192, 343232, 351424, 244934, 367817, 244938, 384202, 253132, 326858, 343246, 384209, 146644, 351450, 384225, 343272, 351467, 359660, 384247, 351480, 384250, 351483, 343307, 384270, 359695, 261391, 253202, 261395, 384276, 384284, 245021, 384290, 245032, 171304, 384299, 351535, 245042, 326970, 384324, 343366, 212296, 212304, 367966, 343394, 343399, 367981, 343410, 155000, 327035, 245121, 245128, 253321, 155021, 384398, 245137, 245143, 245146, 245149, 343453, 245152, 245155, 155045, 245158, 40358, 245163, 114093, 327090, 343478, 359867, 384444, 146878, 327108, 327112, 384457, 327118, 359887, 359891, 343509, 368093, 155103, 343535, 343540, 368120, 343545, 409092, 359948, 359951, 245295, 359984, 400977, 400982, 179803, 138865, 155255, 155274, 368289, 245410, 425639, 245415, 425652, 425663, 155328, 245463, 155352, 155356, 212700, 155364, 245477, 155372, 245487, 212723, 245495, 409336, 155394, 155404, 245528, 155423, 360224, 155439, 204592, 155444, 155448, 417596, 384829, 384831, 360262, 155463, 155477, 376665, 155484, 261982, 425823, 155488, 376672, 155492, 327532, 261997, 376686, 262000, 262003, 425846, 262006, 147319, 262009, 327542, 262012, 155517, 155523, 155526, 360327, 376715, 155532, 262028, 262031, 262034, 262040, 262043, 155550, 262046, 262049, 262052, 327590, 155560, 155563, 155566, 327613, 393152, 311244, 212945, 393170, 155604, 155620, 253924, 155622, 253927, 327655, 360432, 393204, 360439, 253944, 393209, 155647 ]
64d306ee479e07fea0ca2a0ad38b3efdc006affb
38bee5d4669c820e263daaff063670455a8c3b09
/Draw2D/DrawKit/DrawPathView.swift
c7e77b6171322dca8ebea36e386c57ab46e52654
[]
no_license
DevCoop-code/iOS_Graphics
63e55b4bc546cc3cb039feff3be23ee4153400f9
3d2805197c33c455ce7eabbcb28c3621473ce740
refs/heads/master
2022-01-20T12:36:24.306434
2018-11-25T11:19:57
2018-11-25T11:19:57
null
0
0
null
null
null
null
UTF-8
Swift
false
false
978
swift
// // DrawPathView.swift // DrawKit // // Created by HanGyo Jeong on 2018. 8. 12.. // Copyright © 2018년 HanGyoJeong. All rights reserved. // import UIKit import QuartzCore @IBDesignable class DrawPathView: UIView { override func draw(_ rect: CGRect) { let context = UIGraphicsGetCurrentContext() guard let myContext = context else { return } myContext.setLineWidth(2.0) myContext.setStrokeColor(UIColor.blue.cgColor) myContext.move(to: CGPoint.init(x: 100, y: 100)) myContext.addLine(to: CGPoint.init(x: 150, y: 150)) myContext.addLine(to: CGPoint.init(x: 100, y: 200)) myContext.addLine(to: CGPoint.init(x: 50, y: 150)) myContext.addLine(to: CGPoint.init(x: 100, y: 100)) //Fill the color myContext.setFillColor(UIColor.red.cgColor) myContext.fillPath() myContext.strokePath() } }
[ -1 ]
88e178b5194c5f6c9c0abc7695592ea6d1e055f5
04461de9419ae709e3b079866bebed216513c3b7
/SheUp/SheUp/gunagchang/SheUpProtocol.swift
6c6ce56e62078697230027024f60dfa6eb9d65eb
[]
no_license
zouyaozhen1234/sheupLearnSwift
bebd74495eddde010a0bbbbfaeaf35172ca14a1e
5bb4574e1703805559beff7612d87c774504fc07
refs/heads/master
2021-04-06T16:47:01.990700
2018-03-09T08:14:51
2018-03-09T08:14:51
124,509,360
0
0
null
null
null
null
UTF-8
Swift
false
false
1,585
swift
// // SheUpProtocol.swift // SheUp // // Created by 名品导购网MPLife.com on 2018/1/15. // Copyright © 2018年 sweet. All rights reserved. // import UIKit import RxSwift import RxCocoa enum Result{ case ok(message:String) case empty case failed(message:String) } extension Result { var isValid : Bool { switch self { case .ok: return true default: return false } } } extension Result { var description : String { switch self { case let .ok (message): return message case.empty: return "" case let .failed(message): return message } } } extension Result { var textColor: UIColor { switch self { case .ok: return UIColor(red: 138.0/255.0, green: 221.0/255.0, blue: 109.0/255.0, alpha: 1.0) case.empty: return UIColor.black case.failed: return UIColor.red } } } extension Reactive where Base:UILabel { var validationResult: UIBindingObserver<Base,Result> { return UIBindingObserver(UIElement: base, binding: { (label, result) in label.textColor = result.textColor label.text = result.description }) } } extension Reactive where Base:UITextField{ var inputEnabled: UIBindingObserver<Base,Result> { return UIBindingObserver(UIElement: base, binding: { (textFiled, result) in textFiled .isEnabled = result.isValid }) } }
[ -1 ]
3158b0afcca6835acfe52eefbabf3e60b1cf079a
37a04b1d868ef8bb940bc5c47a4a8cfe1846c0c7
/DontWastApp/SceneDelegate.swift
6b2dc9108db4e6b8a467fbbaef15fb11aaaeedba
[]
no_license
evtdias/DontWasteApp
4547bd112183a3e7e111b4588e818852122dd3c6
a4830eae6d33edb1cffcd2138d30b5d80df9ad07
refs/heads/main
2023-07-12T19:46:01.387873
2021-08-12T20:00:05
2021-08-12T20:00:05
395,402,024
0
0
null
null
null
null
UTF-8
Swift
false
false
2,286
swift
// // SceneDelegate.swift // DontWastApp // // Created by user on 10/08/21. // import UIKit class SceneDelegate: UIResponder, UIWindowSceneDelegate { var window: UIWindow? func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`. // If using a storyboard, the `window` property will automatically be initialized and attached to the scene. // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). guard let _ = (scene as? UIWindowScene) else { return } } func sceneDidDisconnect(_ scene: UIScene) { // Called as the scene is being released by the system. // This occurs shortly after the scene enters the background, or when its session is discarded. // Release any resources associated with this scene that can be re-created the next time the scene connects. // The scene may re-connect later, as its session was not necessarily discarded (see `application:didDiscardSceneSessions` instead). } func sceneDidBecomeActive(_ scene: UIScene) { // Called when the scene has moved from an inactive state to an active state. // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive. } func sceneWillResignActive(_ scene: UIScene) { // Called when the scene will move from an active state to an inactive state. // This may occur due to temporary interruptions (ex. an incoming phone call). } func sceneWillEnterForeground(_ scene: UIScene) { // Called as the scene transitions from the background to the foreground. // Use this method to undo the changes made on entering the background. } func sceneDidEnterBackground(_ scene: UIScene) { // Called as the scene transitions from the foreground to the background. // Use this method to save data, release shared resources, and store enough scene-specific state information // to restore the scene back to its current state. } }
[ 393221, 163849, 393228, 393231, 393251, 352294, 344103, 393260, 393269, 213049, 376890, 385082, 393277, 376906, 327757, 254032, 368728, 254045, 180322, 376932, 286845, 286851, 417925, 262284, 360598, 377003, 377013, 164029, 327872, 180418, 377030, 377037, 377047, 418008, 418012, 377063, 327915, 205037, 393457, 393461, 393466, 418044, 385281, 262405, 180491, 336140, 164107, 262417, 368913, 262423, 377118, 377121, 262437, 254253, 336181, 262455, 393539, 262473, 344404, 213333, 418135, 270687, 262497, 418145, 262501, 213354, 246124, 262508, 262512, 213374, 385420, 393613, 262551, 262553, 385441, 385444, 262567, 385452, 262574, 393649, 385460, 262587, 344512, 262593, 360917, 369119, 328180, 328183, 328190, 254463, 328193, 328207, 410129, 393748, 262679, 377372, 188959, 385571, 377384, 197160, 33322, 352822, 270905, 197178, 418364, 188990, 369224, 270922, 385610, 352844, 385617, 352865, 262761, 352875, 344694, 352888, 336513, 377473, 385671, 148106, 213642, 377485, 352919, 98969, 344745, 361130, 336556, 385714, 434868, 164535, 164539, 328379, 328387, 352969, 344777, 418508, 385743, 385749, 139998, 189154, 369382, 361196, 418555, 344832, 336644, 344837, 344843, 328462, 361231, 394002, 336660, 418581, 418586, 434971, 369436, 262943, 369439, 418591, 418594, 336676, 418600, 418606, 369464, 361274, 328516, 336709, 328520, 336712, 361289, 328523, 336715, 361300, 213848, 426842, 361307, 197469, 361310, 254813, 361318, 344936, 361323, 361335, 328574, 369544, 361361, 222129, 345036, 115661, 386004, 345046, 386012, 386019, 386023, 328690, 435188, 328703, 328710, 418822, 377867, 328715, 361490, 386070, 271382, 336922, 345119, 377888, 214060, 345134, 345139, 361525, 386102, 361537, 377931, 345172, 189525, 402523, 361568, 148580, 345200, 361591, 386168, 361594, 410746, 214150, 345224, 386187, 345247, 361645, 345268, 402615, 361657, 402636, 328925, 165086, 66783, 165092, 328933, 222438, 328942, 386286, 386292, 206084, 328967, 345377, 345380, 353572, 345383, 337207, 345400, 378170, 369979, 386366, 337230, 337235, 263509, 353634, 337252, 402792, 271731, 378232, 337278, 271746, 181639, 353674, 181644, 361869, 181650, 181655, 230810, 181671, 181674, 181679, 181682, 337330, 181687, 370105, 181691, 181697, 361922, 337350, 181704, 337366, 271841, 329192, 361961, 329195, 116211, 337399, 402943, 337416, 329227, 419341, 419345, 329234, 419351, 345626, 419357, 345631, 419360, 370208, 394787, 419363, 370214, 419369, 394796, 419377, 419386, 214594, 419401, 353868, 419404, 173648, 419408, 214611, 419412, 403040, 345702, 370298, 353920, 403073, 403076, 345737, 198282, 403085, 403092, 345750, 419484, 345758, 345763, 419492, 345766, 419498, 419502, 370351, 419507, 337588, 419510, 419513, 419518, 403139, 337607, 419528, 419531, 419536, 272083, 394967, 419543, 419545, 345819, 419548, 419551, 345829, 419560, 337643, 419564, 337647, 370416, 337671, 362249, 362252, 395022, 362256, 321300, 345888, 362274, 378664, 354107, 345916, 354112, 370504, 329545, 345932, 370510, 354132, 247639, 337751, 370520, 313181, 182110, 354143, 354157, 345965, 345968, 345971, 345975, 403321, 1914, 354173, 395148, 247692, 337809, 247701, 436127, 436133, 247720, 337834, 362414, 337845, 190393, 247760, 346064, 346069, 419810, 329699, 354275, 190440, 354314, 346140, 436290, 395340, 378956, 436307, 338005, 100454, 329833, 329853, 329857, 329868, 411806, 329886, 346273, 362661, 100525, 387250, 379067, 387261, 256193, 395467, 346317, 411862, 256214, 411865, 411869, 411874, 379108, 411877, 387303, 346344, 395496, 338154, 387307, 346350, 338161, 387314, 436474, 379135, 411905, 411917, 379154, 395539, 387350, 387353, 338201, 338212, 395567, 248112, 362823, 436556, 321880, 362844, 379234, 354674, 321911, 420237, 379279, 272787, 354728, 338353, 338382, 272849, 248279, 256474, 182755, 338404, 338411, 330225, 248309, 248332, 330254, 199189, 420377, 330268, 191012, 330320, 199250, 191069, 346722, 248427, 338544, 346736, 191093, 346743, 346769, 150184, 174775, 248505, 174778, 363198, 223936, 355025, 273109, 355029, 264919, 256735, 264942, 363252, 338680, 264965, 338701, 256787, 363294, 396067, 346917, 396070, 215854, 355123, 355141, 355144, 338764, 355151, 330581, 330585, 387929, 355167, 265056, 265059, 355176, 355180, 355185, 412600, 207809, 379849, 347082, 396246, 330711, 248794, 248799, 437219, 257009, 265208, 199681, 338951, 330761, 330769, 330775, 248863, 396329, 347178, 404526, 396337, 330803, 396340, 339002, 388155, 339010, 347208, 248905, 330827, 248915, 183384, 339037, 412765, 257121, 265321, 248952, 420985, 330890, 347288, 248986, 44199, 380071, 339118, 249018, 339133, 126148, 330959, 330966, 265433, 265438, 388320, 363757, 388348, 339199, 396552, 175376, 175397, 273709, 372016, 437553, 347442, 199989, 175416, 396601, 208189, 437567, 175425, 437571, 437576, 437584, 437588, 396634, 175451, 437596, 429408, 175458, 175461, 175464, 265581, 331124, 175478, 175487, 249215, 175491, 249219, 249225, 249228, 249235, 175514, 175517, 396703, 396706, 175523, 355749, 396723, 388543, 380353, 216518, 380364, 339406, 372177, 339414, 249303, 413143, 339418, 339421, 249310, 339425, 249313, 339429, 339435, 249329, 69114, 372229, 208399, 380433, 175637, 405017, 134689, 265779, 421442, 413251, 265796, 265806, 224854, 224858, 339553, 257636, 224871, 372328, 257647, 372338, 224885, 224888, 224891, 224895, 372354, 126597, 421509, 224905, 11919, 224911, 224914, 126611, 224917, 224920, 126618, 208539, 224923, 224927, 224930, 224933, 257705, 224939, 224943, 257713, 224949, 257717, 257721, 224954, 257725, 224960, 257733, 224966, 224970, 257740, 224976, 257745, 257748, 224982, 257752, 224987, 257762, 224996, 225000, 225013, 257788, 225021, 339711, 257791, 225027, 257796, 339722, 257802, 257805, 225039, 257808, 249617, 225044, 167701, 372500, 257815, 225049, 257820, 225054, 184096, 397089, 257825, 225059, 339748, 225068, 257837, 413485, 225071, 225074, 257843, 225077, 257846, 225080, 397113, 225083, 397116, 257853, 225088, 225094, 225097, 257869, 257872, 225105, 397140, 225109, 225113, 257881, 257884, 257887, 225120, 257891, 225128, 257897, 225138, 257909, 225142, 372598, 257914, 257917, 225150, 257922, 380803, 225156, 339845, 257927, 225166, 397201, 225171, 380823, 225176, 225183, 372698, 372704, 372707, 356336, 380919, 393215, 372739, 405534, 266295, 266298, 421961, 200786, 356440, 217180, 430181, 266351, 356467, 266365, 192640, 266375, 381069, 225425, 250003, 225430, 250008, 356507, 250012, 225439, 135328, 192674, 225442, 438434, 225445, 438438, 225448, 438441, 356521, 225451, 258223, 225456, 430257, 225459, 225462, 225468, 389309, 225472, 372931, 225476, 430275, 389322, 225485, 225488, 225491, 266454, 225494, 225497, 225500, 225503, 225506, 225511, 217319, 225515, 225519, 381177, 397572, 389381, 381212, 356638, 356641, 356644, 356647, 266537, 389417, 356650, 356656, 332081, 340276, 356662, 397623, 332091, 225599, 348489, 332107, 151884, 430422, 348503, 332118, 250201, 250203, 250211, 340328, 250217, 348523, 348528, 332153, 356734, 389503, 332158, 438657, 332162, 389507, 348548, 356741, 332175, 160152, 373146, 340380, 373149, 70048, 356783, 266688, 324032, 201158, 340452, 127473, 217590, 340473, 324095, 324100, 324103, 324112, 340501, 324118, 324122, 340512, 332325, 324134, 381483, 356908, 324141, 324143, 356917, 324150, 324156, 168509, 348734, 324161, 324165, 356935, 348745, 381513, 324171, 324174, 324177, 389724, 332381, 373344, 340580, 348777, 381546, 340628, 184983, 373399, 258723, 332455, 332460, 389806, 332464, 332473, 381626, 332484, 332487, 332494, 357070, 357074, 332512, 340724, 332534, 373499, 348926, 389927, 348979, 348983, 398141, 357202, 389971, 357208, 389979, 430940, 357212, 357215, 439138, 349041, 340850, 381815, 430967, 324473, 398202, 340859, 324476, 430973, 119675, 324479, 340863, 324482, 373635, 324485, 324488, 185226, 381834, 324493, 324496, 324499, 430996, 324502, 324511, 422817, 324514, 201638, 398246, 373672, 324525, 5040, 111539, 324534, 5047, 324539, 324542, 398280, 349129, 340942, 209874, 340958, 431073, 398307, 340964, 209896, 201712, 209904, 349173, 381947, 201724, 349181, 431100, 431107, 349203, 209944, 209948, 357411, 250917, 169002, 357419, 209966, 209969, 209973, 209976, 209980, 209988, 209991, 431180, 209996, 349268, 177238, 250968, 210011, 373853, 341094, 210026, 210028, 210032, 349296, 210037, 210042, 210045, 349309, 152704, 349313, 160896, 210053, 210056, 349320, 259217, 373905, 210068, 210072, 210078, 210081, 210085, 210089, 210096, 210100, 324792, 210108, 357571, 210116, 210128, 210132, 333016, 210139, 210144, 218355, 218361, 275709, 128254, 275713, 242947, 275717, 275723, 333075, 349460, 349486, 349492, 415034, 210261, 365912, 259423, 374113, 251236, 374118, 390518, 357756, 374161, 112021, 349591, 357793, 333222, 259516, 415168, 366035, 415187, 366039, 415192, 415194, 415197, 415200, 333285, 415208, 366057, 366064, 415217, 415225, 423424, 415258, 415264, 366118, 415271, 382503, 349739, 144940, 415279, 415282, 415286, 210488, 415291, 415295, 349762, 333396, 374359, 333400, 366173, 423529, 423533, 210547, 415354, 333440, 267910, 267929, 259789, 366301, 333535, 153311, 366308, 366312, 431852, 399086, 366319, 210673, 366322, 399092, 366326, 333566, 268042, 210700, 366349, 210707, 399129, 333595, 210720, 366384, 358192, 210740, 366388, 358201, 325441, 366403, 325447, 341831, 341839, 341844, 415574, 358235, 350046, 399200, 399208, 268144, 358256, 358260, 399222, 325494, 333690, 325505, 399244, 333709, 333725, 333737, 382891, 382898, 350153, 358348, 333777, 219094, 399318, 358372, 350190, 350194, 333819, 350204, 350207, 325633, 325637, 350214, 219144, 268299, 333838, 350225, 186388, 350232, 333851, 350238, 350241, 374819, 350245, 350249, 350252, 178221, 350257, 350260, 350272, 243782, 350281, 350286, 374865, 252021, 342134, 374904, 268435, 333998, 334012, 260299, 211161, 375027, 358645, 268553, 268560, 432406, 325920, 194854, 358701, 391469, 358705, 358714, 358717, 383307, 358738, 383331, 383334, 391531, 383342, 334204, 268669, 194942, 391564, 366991, 334224, 342431, 375209, 375220, 334263, 326087, 358857, 195041, 334312, 104940, 375279, 416255, 350724, 186898, 342546, 350740, 342551, 342555, 416294, 350762, 252463, 358962, 334397, 358973, 252483, 219719, 399957, 334425, 326240, 375401, 334466, 334469, 391813, 162446, 342680, 342685, 260767, 342711, 244410, 260798, 334530, 260802, 350918, 154318, 342737, 391895, 154329, 416476, 64231, 113389, 203508, 375541, 342777, 391938, 391949, 375569, 375572, 375575, 375580, 162592, 334633, 326444, 383794, 375613, 244542, 260925, 375616, 342857, 416599, 342875, 244572, 433001, 400238, 211826, 211832, 392061, 351102, 252801, 260993, 351105, 400260, 211846, 342921, 342931, 252823, 400279, 392092, 400286, 252838, 359335, 211885, 252846, 400307, 351169, 359362, 351172, 170950, 187335, 326599, 359367, 359383, 359389, 383968, 343018, 261109, 261112, 244728, 383999, 261130, 261148, 359452, 211999, 261155, 261160, 261166, 359471, 375868, 343132, 384099, 384102, 384108, 367724, 187503, 343155, 384115, 212095, 351366, 384136, 384140, 384144, 351382, 384152, 384158, 384161, 351399, 384169, 367795, 244917, 384182, 367801, 384189, 384192, 351424, 343232, 367817, 244938, 384202, 253132, 384209, 146644, 351450, 384225, 359650, 343272, 351467, 359660, 384247, 351480, 384250, 351483, 351492, 384270, 359695, 261391, 253202, 261395, 384276, 384284, 245021, 384290, 253218, 245032, 171304, 384299, 351535, 245042, 326970, 384324, 212296, 212304, 367966, 343394, 367981, 343410, 155000, 327035, 245121, 245128, 253321, 155021, 384398, 245137, 245143, 245146, 245149, 245152, 245155, 155045, 245158, 114093, 327090, 343478, 359867, 384444, 327108, 327112, 384457, 359887, 359891, 368093, 155103, 343535, 343540, 368120, 409092, 253445, 359948, 359951, 245295, 359984, 343610, 400977, 400982, 179803, 155241, 155255, 155274, 368289, 245410, 425639, 425652, 425663, 155328, 245463, 155352, 155356, 155364, 245477, 155372, 245487, 212723, 409336, 155394, 155404, 245528, 155423, 360224, 155439, 204592, 155444, 155448, 417596, 384829, 360262, 155463, 155477, 376665, 155484, 261982, 425823, 155488, 376672, 155492, 327532, 261997, 376686, 262000, 262003, 425846, 262006, 147319, 262009, 327542, 262012, 155517, 155523, 155526, 360327, 376715, 155532, 262028, 262031, 262034, 262037, 262040, 262043, 155550, 253854, 262046, 262049, 262052, 327590, 155560, 155563, 155566, 327613, 393152, 393170, 155604, 155620, 253924, 155622, 253927, 327655, 360432, 393204, 360439, 253944, 393209, 155647 ]
7936c1beb2a18b8571f7cbb7d070b01f52a82b56
471366094eebacc449426ec0d97a10e4ea1192d1
/PalmTree/Models/AddsData/HomeData/emplate/HomeAdpost.swift
27681312c943e1ef53361ea4f51176a937506af6
[]
no_license
zain-ali201/PalmtreeiOS
04f22e1cc426eaa1f3a1ee1cad36097df8f983fc
de5a0bb38fee290cc0ecf50061254bdf35f92e95
refs/heads/master
2023-02-25T15:45:00.811678
2021-02-01T14:22:15
2021-02-01T14:22:15
264,864,831
0
0
null
null
null
null
UTF-8
Swift
false
false
929
swift
// // HomeAdpost.swift // PalmTree // // Created by SprintSols on 10/24/20. // Copyright © 2019 apple. All rights reserved. // import Foundation struct HomeAdpost { var can_post : Bool! var verMsg : String! /** * Instantiate the instance using the passed dictionary values to set the properties values */ init(fromDictionary dictionary: [String:Any]){ can_post = dictionary["can_post"] as? Bool verMsg = dictionary["verified_msg"] as? String } /** * Returns all the available property values in the form of [String:Any] object where the key is the approperiate json key and the value is the value of the corresponding property */ func toDictionary() -> [String:Any] { var dictionary = [String:Any]() if can_post != nil{ dictionary["can_post"] = can_post } return dictionary } }
[ -1 ]
20ba03fc7bd176b6a812a14240f69bed9155c56e
0c39812aed933e9b3baf605ad6406e331e00a1f1
/Boardwalk/NibbedViewController.swift
a56bc39bc4fa8d822a9bf2df7462a6cd25229d5b
[]
no_license
Cereopsis/cereopsis-custom-presentation
74c252605c11ee7066efc2dc2ee94c650d71ecb7
c2cb0bcc5c8753b078e723f0ee961a22aa86234d
refs/heads/master
2020-05-25T16:38:17.057983
2016-07-31T20:29:17
2016-07-31T20:29:17
64,326,643
0
0
null
null
null
null
UTF-8
Swift
false
false
1,794
swift
/* The MIT License (MIT) Copyright (c) 2015 Cereopsis Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ import UIKit class NibbedViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() title = "Nibbed" let button = UIBarButtonItem(barButtonSystemItem: UIBarButtonSystemItem.action, target: self, action: #selector(second(_:))) navigationItem.rightBarButtonItem = button navigationItem.hidesBackButton = true } @IBAction func done(_ sender: AnyObject) { let _ = navigationController?.popViewController(animated: true) } @IBAction func second(_ sender: UIBarButtonItem) { let secondVc = SecondViewController(nibName: nil, bundle: nil) show(secondVc, sender: sender) } }
[ -1 ]
0ecf8729ce5810b30b4d5bb06f97e40ba7d54a34
ce347daab10742cf93a6334572679ec666149537
/Papr/Utils/Extentions/Rx/UIRefreshControl+Rx.swift
8cbeba0e7a6434806d147cdb244967629e10281d
[ "Apache-2.0" ]
permissive
turlodales/Papr
f5a8c67736c13967d2ddc980ee72f2a420bd634e
c9464b1bf95f2144b96fc68dcc474186c24c855f
refs/heads/develop
2022-12-18T08:58:00.405251
2020-09-17T16:39:34
2020-09-17T16:39:34
289,716,488
0
0
Apache-2.0
2020-09-17T16:49:13
2020-08-23T15:44:25
null
UTF-8
Swift
false
false
801
swift
// // UIRefreshControl+Rx.swift // Papr // // Created by Joan Disho on 05.01.20. // Copyright © 2020 Joan Disho. All rights reserved. // import Foundation import RxSwift import RxCocoa extension Reactive where Base: UIRefreshControl { func isRefreshing(in collectionView: UICollectionView) -> Binder<Bool> { return Binder(self.base) { refreshControl, refresh in if refresh { refreshControl.beginRefreshing() collectionView.setContentOffset( CGPoint(x: 0, y: -refreshControl.frame.size.height), animated: true ) } else { refreshControl.endRefreshing() collectionView.setContentOffset(.zero, animated: true) } } } }
[ -1 ]
8e1da47546d5118155252b21d7ea8f8ed94c2663
6a11548449bc6d2af3405012af2fa31092046613
/Collector/CollectorTableViewController.swift
21ce6d532cec4c0229f9ff89bb0f0ae7f25d584e
[]
no_license
anares/Collector
9df5a44dc76cd06e9357c8b6dfbb36b396b00f11
31e9dc47c2e9019067c923da4c8acac136dd46a8
refs/heads/master
2020-03-14T13:33:04.804881
2018-04-30T23:23:01
2018-04-30T23:23:01
131,635,415
0
0
null
null
null
null
UTF-8
Swift
false
false
2,056
swift
// // CollectorTableViewController.swift // Collector // // Created by Ivaylo Yosifov on 30/4/18. // Copyright © 2018 Ivaylo Yosifov. All rights reserved. // import UIKit class CollectorTableViewController: UITableViewController { var items : [Item] = [] override func viewDidLoad() { super.viewDidLoad() } override func viewWillAppear(_ animated: Bool) { getItems() } func getItems() { if let context = (UIApplication.shared.delegate as? AppDelegate)?.persistentContainer.viewContext { if let coreDataStuff = try? context.fetch(Item.fetchRequest()) as? [Item] { if let coreDataItems = coreDataStuff { items = coreDataItems tableView.reloadData() } } } } override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { // #warning Incomplete implementation, return the number of rows return items.count } override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) let item = items[indexPath.row] cell.textLabel?.text = item.title if let imageData = item.image { cell.imageView?.image = UIImage(data: imageData) } return cell } override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { return true } override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { if editingStyle == .delete { if let context = (UIApplication.shared.delegate as? AppDelegate)?.persistentContainer.viewContext { let item = items[indexPath.row] context.delete(item) getItems() } } } }
[ -1 ]
2974c80f7efe8e3c6120a4ebb8fb1704dc39dc8b
bc9166114f55a5821be3f09206f8578ec1b43304
/Movie/Movie/AppDelegate.swift
8c06633b77ea9897e602bb8aba817d7bb6e4550d
[]
no_license
quenca/ios-recruiting-brazil
eb2529c56b4736d4897c3ac8239321e0d85ece0e
56036c1053e9db0de1f69bf1783b1f0fa2f42f51
refs/heads/master
2022-01-18T23:22:07.494036
2019-07-23T12:10:30
2019-07-23T12:10:30
156,137,693
0
0
null
2018-11-05T00:08:29
2018-11-05T00:08:29
null
UTF-8
Swift
false
false
4,812
swift
// // AppDelegate.swift // Movie // // Created by Gustavo Pereira Teixeira Quenca on 19/07/19. // Copyright © 2019 Gustavo Pereira Teixeira Quenca. All rights reserved. // import UIKit import CoreData @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. UINavigationBar.appearance().barTintColor = UIColor(red: 203/255.0, green: 175/255.0, blue: 93/255.0, alpha: 1.0) UINavigationBar.appearance().tintColor = UIColor.white return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. // Saves changes in the application's managed object context before the application terminates. self.saveContext() } // MARK: - Core Data stack lazy var persistentContainer: NSPersistentContainer = { /* The persistent container for the application. This implementation creates and returns a container, having loaded the store for the application to it. This property is optional since there are legitimate error conditions that could cause the creation of the store to fail. */ let container = NSPersistentContainer(name: "Movie") container.loadPersistentStores(completionHandler: { (storeDescription, error) in if let error = error as NSError? { // Replace this implementation with code to handle the error appropriately. // fatalError() causes the application to generate a crash log and terminate. You should not use this function in a shipping application, although it may be useful during development. /* Typical reasons for an error here include: * The parent directory does not exist, cannot be created, or disallows writing. * The persistent store is not accessible, due to permissions or data protection when the device is locked. * The device is out of space. * The store could not be migrated to the current model version. Check the error message to determine what the actual problem was. */ fatalError("Unresolved error \(error), \(error.userInfo)") } }) return container }() // MARK: - Core Data Saving support func saveContext () { let context = persistentContainer.viewContext if context.hasChanges { do { try context.save() } catch { // Replace this implementation with code to handle the error appropriately. // fatalError() causes the application to generate a crash log and terminate. You should not use this function in a shipping application, although it may be useful during development. let nserror = error as NSError fatalError("Unresolved error \(nserror), \(nserror.userInfo)") } } } }
[ 243717, 294405, 320008, 163848, 320014, 313360, 288275, 289300, 322580, 290326, 329747, 139803, 229408, 306721, 322080, 229411, 322083, 296483, 306726, 309287, 308266, 292907, 322092, 217132, 40495, 316465, 288306, 322102, 324663, 164408, 308281, 322109, 286783, 313409, 315457, 349765, 320582, 288329, 242250, 196177, 241746, 344661, 231000, 212571, 287323, 300124, 309342, 325220, 306790, 290409, 322666, 296043, 310378, 152685, 311914, 307310, 334446, 292466, 307315, 314995, 314487, 291450, 314491, 222846, 288383, 318599, 312970, 311444, 239252, 294038, 311449, 323739, 300194, 298662, 233638, 233644, 286896, 300208, 234677, 294070, 125111, 286389, 321212, 309439, 284352, 296641, 235200, 302787, 242371, 284360, 321228, 319181, 298709, 284374, 182486, 189654, 320730, 241371, 311516, 357083, 179420, 322272, 317665, 298210, 165091, 311525, 288489, 290025, 229098, 307436, 304365, 323310, 125167, 313073, 286455, 306424, 322299, 302332, 319228, 319231, 184576, 309505, 241410, 311043, 366339, 309509, 318728, 125194, 234763, 321806, 125201, 296218, 313116, 326434, 237858, 300836, 313125, 295716, 289577, 125226, 133421, 317233, 241971, 316726, 318264, 201530, 313660, 159549, 287038, 218943, 292159, 182079, 288578, 301893, 234828, 292172, 379218, 300882, 321364, 243032, 201051, 230748, 258397, 294238, 298844, 300380, 291169, 199020, 293741, 319342, 292212, 316788, 244598, 124796, 196988, 317821, 303999, 243072, 314241, 242050, 313215, 305022, 325509, 293767, 316300, 322448, 306576, 308114, 319900, 298910, 313250, 308132, 316327, 306605, 316334, 324015, 200625, 324017, 300979, 316339, 322998, 296888, 316345, 67000, 300987, 319932, 310718, 292288, 317888, 323520, 312772, 214980, 298950, 306632, 310733, 289744, 310740, 235994, 286174, 315359, 240098, 323555, 236008, 319465, 248299, 311789, 326640, 203761, 320498, 188913, 314357, 288246, 309243, 300540, 310782 ]
64fd82b19a4bdab411170cb29f42297c6ef0b74b
6dc5252497ae59617037b4450871ea9e61106483
/MiniChallenge/MiniChallenge/Tools/ToolsViewController.swift
2a608a2ea7cfd795d74488d3ea23681b3f9455c4
[ "MIT" ]
permissive
LeoMosca/minichallenge
d9788ad9d9dd4dae89350fecd66f5a024aa7b841
32f588d7f1ffb6e26ed7834210bf3b24894c2eff
refs/heads/master
2020-08-07T07:51:11.081839
2019-10-25T14:01:19
2019-10-25T14:01:19
213,360,661
0
0
null
null
null
null
UTF-8
Swift
false
false
6,442
swift
// // ToolsViewController.swift // MiniChallenge // // Created by Aluno Mack on 09/10/19. // Copyright © 2019 Leo Mosca. All rights reserved. // import UIKit class ToolsViewController: UIViewController, UITableViewDelegate, UITableViewDataSource { @IBOutlet weak var toolsTableView: UITableView! var lang: Language = Language() var topicIndex = 0 var toolIndex = 0 override func viewDidLoad() { super.viewDidLoad() toolsTableView.delegate = self toolsTableView.dataSource = self // Do any additional setup after loading the view. } func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return (lang.topics?[topicIndex].tools?[toolIndex].content?.count ?? 0) + 1 } func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat { return 465 } func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { if(indexPath.row == 0){ if let cell = tableView.dequeueReusableCell(withIdentifier: "ToolCellHeader", for: indexPath) as? ToolsHeaderTableViewCell{ let toolitems = lang.topics?[topicIndex].tools?[toolIndex].content?.count ?? 0 let toolname = lang.topics?[topicIndex].tools?[toolIndex].name let tooldesc = lang.topics?[topicIndex].tools?[toolIndex].description let toolimage = lang.topics?[topicIndex].tools?[toolIndex].image cell.setHeader(toolname, tooldesc, toolitems, toolimage) return cell } } else{ //Se for um curso if (lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].type == "Curso"){ if let cell = tableView.dequeueReusableCell(withIdentifier: "ToolStudyCell", for: indexPath) as? ToolsStudyTableViewCell{ let courseAuthor = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].author let courseImage = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].image let courseLength = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].duration let courseRating = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].rating let courseSubheading = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].subtitle let courseTitle = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].title cell.setCourse(courseImage, courseTitle, courseSubheading, courseAuthor, courseLength, courseRating) return cell } } //Se for um artigo else if (lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].type == "Artigo"){ if let cell = tableView.dequeueReusableCell(withIdentifier: "ToolReadCell", for: indexPath) as? ToolsReadTableViewCell{ let articleImage = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].image let articleSource = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].author let articleSubheading = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].subtitle let articleTitle = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].title cell.setArticle(articleImage, articleTitle, articleSubheading, articleSource) return cell } } //Se for uma Documentação else{ if let cell = tableView.dequeueReusableCell(withIdentifier: "ToolWatchCell", for: indexPath) as? ToolsWatchTableViewCell{ let docImage = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].image let docSource = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].author let docSubheading = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].subtitle let docTitle = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].title cell.setDoc(docImage, docTitle, docSubheading, docSource) return cell } } } return UITableViewCell() } func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { print("Clicou no" + (lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].url ?? "nenhum")) let articleIndex = lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].id if let articleIndex = articleIndex { if let coreseen = CoreDataManager.sharedInstance.getLastSeen() { coreseen[0].lastSeen = Int16(articleIndex) CoreDataManager.sharedInstance.saveContext(); } else { CoreDataManager.sharedInstance.insertLastSeen(articleIndex) } } if (lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].url != nil){ guard let url = URL(string: lang.topics?[topicIndex].tools?[toolIndex].content?[indexPath.row - 1].url ?? "") else { return } if UIApplication.shared.canOpenURL(url) { UIApplication.shared.open(url, options: [:], completionHandler: nil) } } } /* // MARK: - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation override func prepare(for segue: UIStoryboardSegue, sender: Any?) { // Get the new view controller using segue.destination. // Pass the selected object to the new view controller. } */ }
[ -1 ]
e71a2a381963a6496b0b8a425cfe5af81d1f2098
d82cdd87489ca3bc0aa720cb649a3c76c323f70b
/Sources/OctopusKit/Components/Graphics/CameraComponent.swift
9072c8281c02ed358f84c01070aa6505f0b8750c
[ "Apache-2.0" ]
permissive
lukemorse/octopuskit
dd973e82d9edcba8db3254fc8433eba5a6abddab
334a8e0555e8566ab602723d6fd48035cbd488d9
refs/heads/master
2022-10-29T21:31:33.956642
2019-12-26T03:05:25
2019-12-26T03:05:25
null
0
0
null
null
null
null
UTF-8
Swift
false
false
9,127
swift
// // CameraComponent.swift // OctopusKit // // Created by [email protected] on 2017/10/27. // Copyright © 2019 Invading Octopus. Licensed under Apache License v2.0 (see LICENSE.txt) // // TODO: Tests import GameplayKit /// Manages the camera for the scene represented by the entity's `SpriteKitSceneComponent`, optionally tracking an specified node and limiting the camera position within the specified bounds. /// /// To allow the player to move the camera, use `CameraPanComponent` and `CameraZoomComponent`. /// /// **Dependencies:** `SpriteKitSceneComponent` public final class CameraComponent: SpriteKitAttachmentComponent<SKCameraNode> { public override var requiredComponents: [GKComponent.Type]? { [SpriteKitSceneComponent.self] } public var camera: SKCameraNode { didSet { if camera != oldValue { // Avoid redundancy. super.recreateAttachmentForCurrentParent() } } } /// The node that the camera should follow. Sets the `cameraNode`'s position to the node's position on every `update(deltaTime:)`. public var nodeToTrack: SKNode? { didSet { if nodeToTrack != oldValue { // Avoid redundant processing. resetTrackingConstraint() } } } /// Limits the camera node's position within this rectangle, if specified (in the parent (scene) coordinate space.) public var bounds: CGRect? { didSet { if bounds != oldValue { // Avoid redundant processing. resetBoundsConstraint() } } } /// If `true`, the `bounds` rectangle is inset by half of the scene's width and height on each edge, to ensure that the camera does not move the viewport to the blank area outside the scene's contents. /// /// - To properly ensure that the constraints are correctly updated after the camera's scale is changed, call `resetBoundsConstraint()`. public var insetBoundsByScreenSize: Bool { didSet { if insetBoundsByScreenSize != oldValue { // Avoid redundant processing. resetBoundsConstraint() } } } public fileprivate(set) var trackingConstraint: SKConstraint? public fileprivate(set) var boundsConstraint: SKConstraint? public init(cameraNode: SKCameraNode? = nil, nodeToTrack: SKNode? = nil, constrainToBounds bounds: CGRect? = nil, insetBoundsByScreenSize: Bool = false) { self.camera = cameraNode ?? SKCameraNode() self.nodeToTrack = nodeToTrack self.bounds = bounds self.insetBoundsByScreenSize = insetBoundsByScreenSize super.init() // NOTE: Property observers are not notified in init // Set constraints now even before the component is added to an entity, in case the specified `camera` node is already in a scene. resetConstraints() } public required init?(coder aDecoder: NSCoder) { fatalError("init(coder:) has not been implemented") } public override func createAttachment(for parent: SKNode) -> SKCameraNode? { return self.camera } public override func didAddToEntity(withNode node: SKNode) { super.didAddToEntity(withNode: node) guard let scene = coComponent(SpriteKitSceneComponent.self)?.scene else { OctopusKit.logForErrors.add("\(entity) missing SpriteKitSceneComponent – Cannot assign camera") return } // Issue warning if we're replacing another camera. // CHECK: Necessary? if scene.camera != nil && scene.camera != self.camera { OctopusKit.logForWarnings.add("\(scene) already has \(scene.camera) — Replacing with \(self.camera)") } scene.camera = self.camera resetConstraints() } public override func willRemoveFromEntity(withNode node: SKNode) { super.willRemoveFromEntity(withNode: node) guard let scene = coComponent(SpriteKitSceneComponent.self)?.scene else { return } // ℹ️ DESIGN: If the scene has a different camera by now, remove it anyway, since that would be the expected behavior when removing this component. if scene.camera !== self.camera { OctopusKit.logForWarnings.add("\(scene) has a different camera that is not associated with this component: \(scene.camera) — Removing") } scene.camera = nil } // MARK: - Constraints public func resetConstraints() { if self.nodeToTrack != nil { resetTrackingConstraint() } if self.bounds != nil { resetBoundsConstraint() } } public func resetTrackingConstraint() { // Remove existing tracking constraint, if any. if let existingTrackingConstraint = self.trackingConstraint, var constraints = camera.constraints, let indexToRemove = constraints.firstIndex(of: existingTrackingConstraint) { existingTrackingConstraint.enabled = false // CHECK: Necessary? constraints.remove(at: indexToRemove) } self.trackingConstraint = nil // Apply new tracking constraint, if applicable. if let nodeToTrack = self.nodeToTrack { // Constrain the camera to stay a constant distance of 0 points from the player node. self.trackingConstraint = SKConstraint.distance(SKRange.zero, to: nodeToTrack) } if let trackingConstraint = self.trackingConstraint { // Create a new constraints array if the node has none. if camera.constraints == nil { camera.constraints = [] } camera.constraints?.append(trackingConstraint) } } /// - Important: If `bounds` are specified, this method must be called again if the camera's scale is later changed. public func resetBoundsConstraint() { // Remove existing bounds constraint, if any. if let existingBoundsConstraint = self.boundsConstraint, var constraints = camera.constraints, let indexToRemove = constraints.firstIndex(of: existingBoundsConstraint) { existingBoundsConstraint.enabled = false // CHECK: Necessary? constraints.remove(at: indexToRemove) } self.boundsConstraint = nil // Apply new bounds constraint, if applicable. if let bounds = self.bounds { self.boundsConstraint = createBoundsConstraint(to: bounds) } if let boundsConstraint = self.boundsConstraint { // Create a new constraints array if the node has none. if camera.constraints == nil { camera.constraints = [] } camera.constraints?.append(boundsConstraint) } } public func createBoundsConstraint(to bounds: CGRect) -> SKConstraint { // TODO: Test and confirm various configurations. // TODO: Test `frame` vs. `size` etc. // DECIDE: Implement automatic recalculation when camera's scale changes? // CREDIT: Apple DemoBots Sample let xRange, yRange: SKRange if self.insetBoundsByScreenSize, let scene = camera.scene { let screenSize = scene.size // Constrain the camera to avoid it moving to the very edges of the scene. // First, work out the scaled size of the screen and camera. let scaledScreenSize = CGSize(width: screenSize.width * camera.xScale, height: screenSize.height * camera.yScale) let xInset = min(scaledScreenSize.width / 2, bounds.width / 2) let yInset = min(scaledScreenSize.height / 2, bounds.height / 2) // Use these insets to create a smaller inset rectangle within which the camera must stay. let insetBounds = bounds.insetBy(dx: xInset, dy: yInset) // Define an `SKRange` for each of the x and y axes to stay within the inset rectangle. xRange = SKRange(lowerLimit: insetBounds.minX, upperLimit: insetBounds.maxX) yRange = SKRange(lowerLimit: insetBounds.minY, upperLimit: insetBounds.maxY) } else { xRange = SKRange(lowerLimit: bounds.minX, upperLimit: bounds.maxX) yRange = SKRange(lowerLimit: bounds.minY, upperLimit: bounds.maxY) } // Constrain the camera within the inset rectangle. let boundsConstraint = SKConstraint.positionX(xRange, y: yRange) boundsConstraint.referenceNode = camera.parent return boundsConstraint } }
[ -1 ]
eed7db8741b655f487224fbe44c4a29bfdaaeb0a
a5d3a18e548fb709d7d51628e27c0c1943b96705
/NaruiUIComponents/Classes/Graph/NaruGraphItemView.swift
a193e024d5f8fa5ef3181dd3e556c7ea4cf91144
[ "MIT" ]
permissive
naruint/NaruiUIComponent
7a2e434b767551f64d3b83fc54059473ed7af6c5
50ae341e7ed84f2cd7e8bc3ed4cb1716526194bb
refs/heads/master
2023-08-07T18:18:41.190658
2021-03-23T01:32:51
2021-03-23T01:32:51
307,555,320
1
1
MIT
2021-09-24T08:00:01
2020-10-27T01:46:32
Swift
UTF-8
Swift
false
false
2,866
swift
// // NaruGraphItemView.swift // NaruiUIComponents // // Created by Changyeol Seo on 2020/11/12. // import UIKit import RxCocoa import RxSwift extension Notification.Name { static let naruGraphItemDidSelected = Notification.Name(rawValue: "naruGraphItemDidSelected_observer") } class NaruGraphItemView: UIView { var data:NaruGraphView.Data? = nil { didSet { DispatchQueue.main.async {[weak self]in guard let s = self else { return } let height = s.frame.height - s.weakDayLabel.frame.height - s.dayLabel.frame.height if let value = s.data?.value { let newHeigt = height * CGFloat(value) s.layoutBarHeight.constant = newHeigt } s.dayLabel.text = "\(s.data?.date.day ?? 0)" s.weakDayLabel.text = s.data?.date.dayWeakString } } } let disposeBag = DisposeBag() //MARK:- //MARK:IBOutlet @IBOutlet weak var buttonView: UIButton! @IBOutlet weak var layoutBarHeight: NSLayoutConstraint! @IBOutlet weak var imageView: UIImageView! @IBOutlet weak var weakDayLabel: UILabel! @IBOutlet weak var dayLabel: UILabel! //MARK:- //MARK:arrangeView override init(frame: CGRect) { super.init(frame: frame) arrangeView() } required init?(coder: NSCoder) { super.init(coder: coder) arrangeView() } func arrangeView() { guard let view = UINib( nibName: String(describing: NaruGraphItemView.self), bundle: Bundle(for: type(of: self))).instantiate(withOwner: self, options: nil).first as? UIView else { return } view.frame = bounds addSubview(view) view.frame = self.bounds view.autoresizingMask = [.flexibleHeight, .flexibleWidth] buttonView.setBackgroundImage(UIColor.yellow.image, for: .normal) buttonView.setBackgroundImage(UIColor.green.image, for: .selected) buttonView.rx.tap.bind { [unowned self](_) in NotificationCenter.default.post(name: .naruGraphItemDidSelected, object: self.data) buttonView.isSelected = true }.disposed(by: disposeBag) NotificationCenter.default.addObserver(forName: .naruGraphItemDidSelected, object: nil, queue: nil) { (noti) in if let obj = noti.object as? NaruGraphView.Data { if self.data?.date.day == obj.date.day { return } self.buttonView.isSelected = false } } } }
[ -1 ]
cfaba97724529717d6650de1fb28f4681c028bed
cf4b27790c4bf7a68707e9cdf846ef1d011cf029
/TDD_Calculate/State/OperationType.swift
574983e559ae407f3736c9d05c55cf5fc4b07d5b
[]
no_license
sky0926a/TDD-Calculator
8003b4add5f4a81c7c77ff8513a6d67c04bf51f7
da38845bb1a7dcb3747a1265afb9a9ab6874caaf
refs/heads/master
2020-05-02T03:13:13.251071
2019-06-25T05:27:29
2019-06-25T05:27:29
177,723,181
0
0
null
null
null
null
UTF-8
Swift
false
false
3,351
swift
// // OperationType.swift // TDD_Calculate // // Created by Jimmy Li on 2019/3/22. // Copyright © 2019 Jimmy Li. All rights reserved. // import UIKit enum OperationType: Int { case command case function case digital case result } extension OperationType { var titleColor: UIColor { switch self { case .command: return UIColor.white case .function: return UIColor.black case .digital: return UIColor.white case .result: return UIColor.white } } var backgroundColor: UIColor { switch self { case .command: return UIColor.theme.orange.apple case .function: return UIColor.theme.lightGary.apple case .digital: return UIColor.theme.darkGray.apple case .result: return UIColor.theme.orange.apple } } } enum PressType: String { /// + case addition = "+" /// - case subtraction = "-" /// × case multiplication = "×" /// ÷ case division = "÷" /// = case equal = "=" /// +/- case sign = "+/-" /// AC / C case clean = "AC" /// % case percentage = "%" /// . case digit = "." /// 0 case zero = "0" /// 1 case one = "1" /// 2 case two = "2" /// 3 case three = "3" /// 4 case four = "4" /// 5 case five = "5" /// 6 case six = "6" /// 7 case seven = "7" /// 8 case eight = "8" /// 9 case nine = "9" } extension PressType { var name: String { return rawValue } var operation: OperationType { switch self { case .addition, .subtraction, .division, .multiplication: return .command case .clean, .sign, .percentage: return .function case .equal: return .result default: return .digital } } var state: OperationState { switch self { case .addition: return OperationStateAddition() case .subtraction: return OperationStateSubtraction() case .division: return OperationStateDivision() case .multiplication: return OperationStateMultiplication() case .equal: return OperationStateEqual() case .sign: return OperationStateSign() case .clean: return OperationStateClean() case .percentage: return OperationStatePercentage() case .digit: return OperationStateDigit() case .zero: return OperationStateZero() case .one: return OperationStateOne() case .two: return OperationStateTwo() case .three: return OperationStateThree() case .four: return OperationStateFour() case .five: return OperationStateFive() case .six: return OperationStateSix() case .seven: return OperationStateSeven() case .eight: return OperationStateEight() case .nine: return OperationStateNight() } } }
[ -1 ]
fe7e6ad7a3d2c7d44b718024e28e81af6205fa7d
fb5b1504eb5b24abca61bcce4e8556a912738809
/build/src/Models/JourneyAggregateQueryFilter.swift
61f67d7e7d1c77b6cd863298e126ca95888edf08
[ "MIT" ]
permissive
MyPureCloud/platform-client-sdk-ios
135f1d124730ecc7e47e68df90a3215ba4ba6880
04ee2b0f5d3f8ad73078eb713427cb6f9e164dda
refs/heads/master
2023-08-17T05:03:39.340378
2023-08-15T06:49:56
2023-08-15T06:49:56
130,367,583
0
2
null
null
null
null
UTF-8
Swift
false
false
907
swift
// // JourneyAggregateQueryFilter.swift // // Generated by swagger-codegen // https://github.com/swagger-api/swagger-codegen // import Foundation public class JourneyAggregateQueryFilter: Codable { public enum ModelType: String, Codable { case and = "and" case or = "or" } /** Boolean operation to apply to the provided predicates and clauses */ public var type: ModelType? /** Boolean 'and/or' logic with up to two-levels of nesting */ public var clauses: [JourneyAggregateQueryClause]? /** Like a three-word sentence: (attribute-name) (operator) (target-value). */ public var predicates: [JourneyAggregateQueryPredicate]? public init(type: ModelType?, clauses: [JourneyAggregateQueryClause]?, predicates: [JourneyAggregateQueryPredicate]?) { self.type = type self.clauses = clauses self.predicates = predicates } }
[ -1 ]
87ba93826a2d25b23dc5d97327c08500ee89afad
d3c5591fab3fd78fed3a736e9e9740123b839de4
/pointerapp/AppointmentViewController.swift
1da3af85ab9dcc3fac099e6b7378a3cfa8f5d05a
[]
no_license
stephankreft/Pointer-Veterinary-Clinic---Estepona
85f6b43faeb84cfe53d1c07fa9831c74c1825a43
7af9825d9e26e160cb5966935833d1f86bafa30d
refs/heads/master
2021-01-10T03:46:01.848857
2016-02-10T12:57:16
2016-02-10T12:57:16
45,295,456
0
0
null
null
null
null
UTF-8
Swift
false
false
4,368
swift
// // AppointmentViewController.swift // pointerapp // // Created by stephan kreft on 16/10/2015. // Copyright © 2015 stephan kreft. All rights reserved. // import UIKit import Foundation class AppointmentViewController: UIViewController,NSURLConnectionDelegate{ @IBOutlet weak var btnSend: UIButton! @IBOutlet weak var firstNameText: UITextField! @IBOutlet weak var lastNameText: UITextField! @IBOutlet weak var phoneNumberText: UITextField! @IBOutlet weak var petsNameText: UITextField! @IBOutlet weak var messageText: UITextField! @IBOutlet weak var appointmentText: UITextField! @IBOutlet weak var emailAddressText: UITextField! override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view. // make buttons have rounded corners btnSend.layer.cornerRadius = 10 btnSend.clipsToBounds = true btnSend.layer.borderColor = UIColor.blackColor().CGColor btnSend.layer.borderWidth = 2 } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } /* // MARK: - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) { // Get the new view controller using segue.destinationViewController. // Pass the selected object to the new view controller. } */ override func viewWillAppear(animated: Bool) { navigationController?.navigationBarHidden = false super.viewWillAppear(animated) } @IBAction func cancelButtonTapped(sender: AnyObject) { self.dismissViewControllerAnimated(true, completion: nil) } @IBAction func sendMailTapped(sender: AnyObject) { let firstName : String = firstNameText.text! let lastName : String = lastNameText.text! let emailAddress : String = emailAddressText.text! let phoneNumber : String = phoneNumberText.text! let appointment : String = appointmentText.text! let petsName : String = petsNameText.text! let message : String = messageText.text! if( firstName.isEmpty || lastName.isEmpty || emailAddress.isEmpty || phoneNumber.isEmpty) { displayAlertMessage("First name , last name , email address and phone number are required!") return } let myUrl = NSURL(string: "http://pointerclinic.com/php/iosmail.php"); let request = NSMutableURLRequest(URL:myUrl!); request.HTTPMethod = "POST" let postString = "firstName=\(firstName)&lastName=\(lastName)&email=\(emailAddress)&phone=\(phoneNumber)&petsName=\(petsName)&message=\(message)&appointment=\(appointment)"; request.HTTPBody = postString.dataUsingEncoding(NSUTF8StringEncoding); let task = NSURLSession.sharedSession().dataTaskWithRequest(request) { data, response, error in if error != nil { return } } self.firstNameText.text = "" self.lastNameText.text = "" self.emailAddressText.text = "" self.phoneNumberText.text = "" self.petsNameText.text = "" self.appointmentText.text = "" self.messageText.text = "" self.displayAlertMessage("Thank you for contacting us. We will contact you shortly") task.resume() } func displayAlertMessage(userMessage: String){ let myAlert = UIAlertController (title: "Alert", message: userMessage, preferredStyle: UIAlertControllerStyle.Alert) let okAction = UIAlertAction(title: "OK", style: UIAlertActionStyle.Default, handler: nil) myAlert.addAction(okAction) self.presentViewController(myAlert, animated: true, completion: nil) } }
[ -1 ]
e0d8b64295d36389c148297d210b2e771e6ffe46
52fb55e397fa970e31e05abfc3b0d41e08e31fc9
/LYRefreshDemo/Refresh/LYRefreshEnum.swift
41952e7420b3e12a7a466f85bf4df8baa65e152d
[]
no_license
duanyanni/Refresh
85c7782f5afbc1dc54c032b1bac76bb537b3a833
a28b46424b9dc6236cc5ef0324b4a24dd249d82f
refs/heads/master
2021-06-22T05:41:16.530313
2017-08-17T10:11:40
2017-08-17T10:11:40
100,575,282
0
0
null
null
null
null
UTF-8
Swift
false
false
463
swift
// // LYRefreshEnum.swift // taoxinSwiftIphoneApp // // Created by d y n on 2017/8/16. // Copyright © 2017年 Xaelink. All rights reserved. // import Foundation //head 刷新状态 enum LYRefreshHeaderStatus { case normal, waitRefresh, refreshing, end } //footer 刷新状态 enum LYRefreshFooterStatus { case normal, waitRefresh, refreshing, loadover } //当前刷新对象 enum LYRefreshObject { case none, header,footer }
[ -1 ]
5375e65e0b935b55eea43f607c1baa102aeacd55
442530bdf4a73440a311792084a5b56eddf230d6
/Classwork/Lesson04/Lesson04.playground/section-1.swift
09c67aa29d2c8b98fbaa24ad881ae6fc275a8c40
[]
no_license
aliyounisGH/MOB-DC-01
3d6854630da9456aabfd8e8815f29c3e2b6efbb4
d78367fccc69a06e46afe1f5fda3d006dd4c7cc8
refs/heads/master
2021-01-22T13:30:14.334093
2015-03-23T16:45:08
2015-03-23T16:45:08
28,066,351
0
0
null
null
null
null
UTF-8
Swift
false
false
3,996
swift
// Lesson 04 playground import Foundation // TODO: Create two variables, name and age. Name is a string, age is an integer. var name:String = "Tedi" var age = 18 // TODO: Print "Hello {whatever the value of name is}, you are {whatever the value of age is} years old!" println("Hello \(name), you are \(age) years old") //"This is " + "interpolation." + name // TODO: Print “You can drink” below the above text if the user is above 21. If they are above 18, print “you can vote”. If they are above 16, print “You can drive” if age >= 21 { println("You can drink!") } else if age >= 18{ println("You can vote.") } else if age >= 16 { println("You can drive") } else if age >= 16 { println("You can't drive") } else { println("Grow up!") } // TODO: Print “you can drive” if the user is above 16 but below 18. It should print “You can drive and vote” if the user is above 18 but below 21. If the user is above 21, it should print “you can drive, vote and drink (but not at the same time!”. if age > 16 && age <= 18 { println("You can drive but you can't vote") } else if age > 18 || age > 21 { println("You can vote") } if age > 16 && age < 18 { println("You can drive but you can't vote") }else if age > 18 || age > 21 { println("You can vote") } // TODO: Print the first fifty multiples of seven minus one (e.g. the first three multiples are 7, 14, 21. The first three multiples minus one are 6, 13, 20) for i in 1...50 { var multiple = (7*i)-1 println(multiple) } for i in 1...50 { var multiple = 7 * i - 1 println(multiple) } for var i = 1; i < 50; ++i { println(7*i-1) } // TODO: Create a constant called number let number = 8 // TODO: Print whether the above number is even if number % 2 == 0 && number != 0 { println("This is an even number") } // TODO: The first fibonacci number is 0, the second is 1, the third is 1, the fourth is two, the fifth is 3, the sixth is 5, etc. The Xth fibonacci number is the sum of the X-1th fibonacci number and the X-2th fibonacci number. Print the 37th fibonacci number below var fibNum = 9, current = 0, next = 1, result = 0 for index in 0..<fibNum { //current val is 3 //temp value becomes 3 let tempVar = current //current value becomes next(5) current = next //next value becomes old current(temporoary) + new current(old next) next = tempVar + current result = tempVar } println("Fib num is \(result)") //............................................................ var fibNum1 = 9, current1 = 0, next1 = 1, finalResult = 0 for index in 0..<fibNum1 { //current val is 3 //temp value becomes 3 let tempVar1 = current1 //current value becomes next(5) current1 = next1 //next value becomes old current(temporary) + new current(old next) next1 = tempVar1 + current1 finalResult = tempVar1 } println("Fib num is \(finalResult)") // TODO: Print out "Hello {whatever the value of name is}, your name is {however long the string name is} characters long!. Use countElements() println("Hello \(name), your name is \(countElements(name)) characters long!.") // TODO: Print the sum of one hundred random numbers. Use rand() to generate random numbers. var sum = 20 for i in 1...100 { sum += String(rand()).toInt()! } println(sum) //another one var sum1 = 0 for i in 1...100 { sum1 += Int(rand()) } println(sum) // Bonus TO DO: Write a program that prints the numbers from 1 to 100. But for multiples of three print “Fizz” instead of the number and for the multiples of five print “Buzz”. For numbers which are multiples of both three and five print “FizzBuzz”. let fizz = 3 let buzz = 5 for var i = 1; i <= 100; ++i { if ((i % fizz) == 0 && (i % buzz) == 0) { println("FizzBuzz") } else if ((i % fizz) == 0) { println("Fizz") } else if ((i % buzz) == 0) { println("Buzz") } else { println("Number \(i)") } }
[ -1 ]
cf42bc2be684232cfa96c00eb7756c2c5f2ebaec
d8c610780b8c3a0809af9da0c0b8354b68e9c506
/HPIView/HPIView/TntView.swift
62ab90a5046eafa381ed727e4fdcd006fc8beafd
[ "MIT" ]
permissive
adamnemecek/SwiftTA
e8796489bc967ca76edd3c685cf9662b7e63cd14
f79dec17707d72e9c5e7ad7be9f4671e4103ba83
refs/heads/master
2020-03-26T02:59:15.360943
2018-12-11T00:56:44
2018-12-11T00:56:44
144,434,306
0
0
MIT
2018-08-12T03:17:37
2018-08-12T03:17:36
null
UTF-8
Swift
false
false
1,926
swift
// // TntView.swift // HPIView // // Created by Logan Jones on 7/18/18. // Copyright © 2018 Logan Jones. All rights reserved. // import AppKit class TntViewController: NSViewController { private var tntView: TntViewLoader! override func loadView() { let deafultFrame = NSRect(x: 0, y: 0, width: 640, height: 480) if false { /* Nothing to see here */ } else if let metal = MetalTntView(tntViewFrame: deafultFrame) { view = metal tntView = metal } else { let cocoa = CocoaTntView(frame: deafultFrame) view = cocoa tntView = cocoa } } func load<File>(contentsOf tntFile: File, from filesystem: FileSystem) throws where File: FileReadHandle { let map = try MapModel(contentsOf: tntFile) switch map { case .ta(let model): let palette = try Palette.standardTaPalette(from: filesystem) tntView?.load(model, using: palette) case .tak(let model): tntView?.load(model, from: filesystem) } } // The load methods without a filesystem are retained for HPIView support. // Consider this temporary. func load<File>(contentsOf tntFile: File, using palette: Palette) throws where File: FileReadHandle { let map = try MapModel(contentsOf: tntFile) switch map { case .ta(let model): tntView?.load(model, using: palette) case .tak(_): //tntView?.load(model, from: filesystem) print("!!! TAK TNT files are not supported for viewing when the complete filesystem is not available.") tntView?.clear() } } } protocol TntViewLoader { func load(_ map: TaMapModel, using palette: Palette) func load(_ map: TakMapModel, from filesystem: FileSystem) func clear() }
[ -1 ]
1f8ca48456deadb8a4783860af9bb39e73eeb813
535a459be700505a24b83beb97b62b77ca8f9c22
/Widget Extension/Views/RideWidgetEntryView.swift
22f33c6783751f42454f06a418461c1c5a34e4a2
[]
no_license
exyte/wwdc2020-tutorials
791c562c7eeaac1f483f1e794a96d088a43b0f33
d32c405404a982a1058177fb32b8cf96849e4dbc
refs/heads/master
2023-03-27T22:21:29.346827
2021-03-26T09:54:23
2021-03-26T09:54:23
304,249,408
19
7
null
null
null
null
UTF-8
Swift
false
false
4,337
swift
import SwiftUI struct RideWidgetEntryView: View { @Environment(\.widgetFamily) var family var entry: RideTimelineProvider.Entry var body: some View { switch entry.scooter != nil { case true: rideStatusView case false: emptyRideView } } var emptyRideView: some View { HStack { VStack(alignment: .leading, spacing: 15) { Image("scooter-yellow") .resizable() .aspectRatio(contentMode: .fit) .frame(width: 40, height: 40) Spacer() Text("RIDE") .foregroundColor(Color(red: 115 / 255, green: 85 / 255, blue: 7 / 255)) .font(Font.system(size: 16, weight: .bold, design: .rounded)) .padding([.top, .bottom], 15) .frame(maxWidth: .infinity) .background(Color(red: 248 / 255, green: 220 / 255, blue: 150 / 255)) .cornerRadius(16) } } .frame(maxWidth: .infinity, maxHeight: .infinity) .padding(15) .background(Color(red: 251 / 255, green: 236 / 255, blue: 197 / 255)) } var rideStatusView: some View { VStack(alignment: .leading, spacing: 15) { HStack(alignment: .center, spacing: 10) { HStack { Image("scooter-yellow") .resizable() .aspectRatio(contentMode: .fit) .frame(width: 40, height: 40) } Text("\(entry.scooter?.name ?? "")") .foregroundColor(Color(red: 58 / 255, green: 42 / 255, blue: 3 / 255)) .font(.system(size: 20, weight: .bold, design: .rounded)) } HStack(alignment: .bottom) { VStack(alignment: .leading, spacing: 5) { HStack(spacing: 5) { Image(systemName: "battery.100.bolt") .resizable() .aspectRatio(contentMode: .fit) .padding(EdgeInsets(top: 5, leading: 6, bottom: 5, trailing: 4)) .frame(width: 30, height: 30) .foregroundColor(.white) .background(getBatteryStatusColor(entry.remainingCharge)) .clipShape(Circle()) (Text("\(entry.remainingCharge)") + Text("%")) .foregroundColor(Color(red: 78 / 255, green: 57 / 255, blue: 4 / 255)) .font(Font.system(size: 16, weight: .semibold, design: .rounded)) } HStack(spacing: 5) { Image(systemName: "dollarsign.circle.fill") .resizable() .aspectRatio(contentMode: .fit) .frame(width: 30, height: 30) .foregroundColor(.green) Text(String(format: "%.0f", entry.cost)) .foregroundColor(Color(red: 78 / 255, green: 57 / 255, blue: 4 / 255)) .font(Font.system(size: 16, weight: .semibold, design: .rounded)) } } Spacer() if family == .systemMedium, entry.configuration.showTimer?.boolValue ?? true { Text(entry.startDate ?? Date(), style: .timer) .font(Font.system(size: 24, weight: .semibold, design: .rounded)) .foregroundColor(Color(red: 115 / 255, green: 85 / 255, blue: 7 / 255)) .multilineTextAlignment(.trailing) } } } .frame(maxWidth: .infinity, maxHeight: .infinity) .padding(15) .background(Color(red: 251 / 255, green: 236 / 255, blue: 197 / 255)) } func getBatteryStatusColor(_ charge: Int) -> Color { if charge >= 90 { return Color.green.opacity(0.7) } if charge < 90, charge >= 30 { return Color.yellow } return Color.red.opacity(0.7) } }
[ -1 ]
6eb588aba4554111275da7a9d891ce2eb1d9bfd5
c2cd3c4221dd76a8d5a1963ab744ec4df1c026cc
/GeneralPurposeTree.playground/Sources/Queue.swift
cec2b63ac5ea6c62da0dcd7b8871a7a01b590104
[]
no_license
lucaspedrazoli-data-structure/trees
19245f84590983b775268539db28c18f08531503
be99c0d172a3464d6e3f03e1439fe46447fc133d
refs/heads/master
2023-06-17T14:25:13.758887
2021-07-12T13:46:12
2021-07-12T13:46:12
293,568,712
0
0
null
null
null
null
UTF-8
Swift
false
false
907
swift
// Copyright (c) 2019 Razeware LLC // For full license & permission details, see LICENSE.markdown. // Copyright (c) 2019 Razeware LLC // For full license & permission details, see LICENSE.markdown. public struct Queue<T> { private var leftStack: [T] = [] private var rightStack: [T] = [] public init() {} public var isEmpty: Bool { leftStack.isEmpty && rightStack.isEmpty } public var peek: T? { !leftStack.isEmpty ? leftStack.last : rightStack.first } public private(set) var count = 0 @discardableResult public mutating func enqueue(_ element: T) -> Bool { count += 1 rightStack.append(element) return true } public mutating func dequeue() -> T? { if leftStack.isEmpty { leftStack = rightStack.reversed() rightStack.removeAll() } let value = leftStack.popLast() if value != nil { count -= 1 } return value } }
[ 210307 ]
713d75b4d59974176314ae756fa0be0ff2a71985
33c3c25dccc9c9020f0bf5540338eb43734a874f
/FoodPin/Controller/WalkthroughContentViewController.swift
3a2d9cae2bb0b96ae64b8a1084feca26fe6d8bd3
[]
no_license
DongyuZhang/FoodPin
74de63e1f49904ec4998e38b19d9e5b121aa783c
6a32ee2091110d86220db5f3b0b3233921b0c2ba
refs/heads/master
2020-03-29T17:45:07.124671
2018-10-16T03:33:43
2018-10-16T03:33:43
150,178,818
0
0
null
null
null
null
UTF-8
Swift
false
false
1,414
swift
// // WalkthroughContentViewController.swift // FoodPin // // Created by Dongyu Zhang on 10/2/18. // Copyright © 2018 AppCoda. All rights reserved. // import UIKit class WalkthroughContentViewController: UIViewController { @IBOutlet var headingLabel: UILabel! { didSet { headingLabel.numberOfLines = 0 } } @IBOutlet var subHeadingLabel: UILabel! { didSet { subHeadingLabel.numberOfLines = 0 } } @IBOutlet var contentImageView: UIImageView! var index = 0 var heading = "" var subHeading = "" var imageFile = "" override func viewDidLoad() { super.viewDidLoad() headingLabel.text = heading subHeadingLabel.text = subHeading contentImageView.image = UIImage(named: imageFile) // Do any additional setup after loading the view. } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } /* // MARK: - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation override func prepare(for segue: UIStoryboardSegue, sender: Any?) { // Get the new view controller using segue.destinationViewController. // Pass the selected object to the new view controller. } */ }
[ 356460 ]
7fdf6fed54e4048e0683b4f84ab02c17aaaa09a8
18f347534816976ea403c72bf91c1454145d98a8
/Sources/Nodal/View/NodeView.swift
8bc3663f5c19b5b3fbd4442b627b59a0fedd42b5
[]
no_license
JoeBakalor/Nodal
428b4d26f9dcf70619c198cafce49412172c463e
2e499e108e1fab986057d248c1a6232c721bdd0c
refs/heads/master
2021-02-18T06:40:26.864823
2020-11-13T22:22:13
2020-11-13T22:22:13
245,171,603
3
0
null
null
null
null
UTF-8
Swift
false
false
13,709
swift
// // NodeView.swift // // // Created by Joe Bakalor on 3/5/20. // import UIKit import Foundation import Combine open class NodeView: UIView { @Published var desiredCoordinates: CGPoint = .zero public var nodeID = UUID.init() public var panMode = false{ didSet { //TODO: This should be animated self.layoutSubviews() } } // Shape layers private let backgroundShape = CAShapeLayer() private var panModeRect: CGRect = .zero private var normalModeRect: CGRect = .zero var inputConnectors: [Connector] = [] var outputConnectors: [Connector] = [] var inputConnections: [Int: (CAShapeLayer, NodeView, Connector)] = [:] var outputConnections: [Int: (CAShapeLayer, NodeView, Connector)] = [:] var inputLabels: [UILabel] = [] var outputLabels: [UILabel] = [] //Need to be cancelled when deleting node var subs: [AnyCancellable] = [] // Model var nodeModel: NodeModel! required public init?(coder aDecoder: NSCoder) { super.init(coder: aDecoder) self.initView() } public override init(frame: CGRect) { super.init(frame: frame) self.initView() } // Used for full operation public convenience init<T: NodeOperation>(nodeOperation: T.Type){ self.init(frame: CGRect.zero) do { nodeModel = try NodeModel(nodeOperation: nodeOperation) } catch let error as NodalError { print(error) } catch let error { print(error) } if nodeOperation.numberInputs > 0 { for i in 0...nodeOperation.numberInputs - 1 { let connector = Connector(index: i, location: .INPUT) let label = UILabel() label.text = "0.0" inputConnectors.append(connector) inputLabels.append(label) // Display input values let sub = nodeModel.state.inputs[i].$value.sink { (value) in guard let val = value else { return } self.inputLabels[i].text = "\(val)" self.inputLabels[i].sizeToFit() } subs.append(sub) } } if nodeOperation.numberOutputs > 0 { for i in 0...nodeOperation.numberOutputs - 1 { let connector = Connector(index: i, location: .OUTPUT) let label = UILabel() outputConnectors.append(connector) outputLabels.append(label) // Display output values let sub = nodeModel.state.outputs[i].$value.sink { (value) in guard let val = value else { return } self.outputLabels[i].text = "\(val)" self.outputLabels[i].sizeToFit() } subs.append(sub) } } self.initView() } open func initView() { self.layer.addSublayer(backgroundShape) [inputConnectors, outputConnectors].forEach{ $0.forEach{ self.addSubview($0) } } [inputLabels, outputLabels].forEach{ $0.forEach { self.addSubview($0) } } } func cancelInputConnection(to ourConnector: Connector){ inputConnections.removeValue(forKey: ourConnector.index) nodeModel?.disconnect(inputIndex: ourConnector.index) } func newInputConnection(from connector: Connector, on nodeView: NodeView, to ourConnector: Connector, with connectionLayer: CAShapeLayer) throws { inputConnections[ourConnector.index] = (connectionLayer, nodeView, connector) do { try nodeModel?.connect(inputIndex: ourConnector.index, toOutputIndex: connector.index, ofNodeModel: nodeView.nodeModel) } catch let error as NodalError { throw error } catch _ { throw NodalError.UNEXPECTED } } func cancelOuptutConnection(from ourConnector: Connector){ outputConnections.removeValue(forKey: ourConnector.index) nodeModel?.disconnect(outputIndex: ourConnector.index) } func newOutputConnection(to connector: Connector, on nodeView: NodeView, from ourConnector: Connector, with connectionLayer: CAShapeLayer) throws { outputConnections[ourConnector.index] = (connectionLayer, nodeView, connector) do { try nodeModel?.connect(outputIndex: ourConnector.index, toInputIndex: connector.index, ofNodeModel: nodeView.nodeModel) } catch let error as NodalError { throw error } catch _ { throw NodalError.UNEXPECTED } } } //MARK: View layout extension NodeView{ override open func layoutSubviews() { super.layoutSubviews() normalModeRect = self.bounds panModeRect = CGRect( x: -7.5, y: -7.5, width: self.bounds.width + 15, height: self.bounds.height + 15) let H = panMode ? panModeRect.height : self.bounds.height let W = panMode ? panModeRect.width : self.bounds.width let inset = NodalConfiguration.connectorSize.width/2 let insetRect = CGRect( x: inset, y: 0, width: W - NodalConfiguration.connectorSize.width, height: H) let backgroundPath = UIBezierPath( roundedRect: insetRect, byRoundingCorners: .allCorners, cornerRadii: CGSize(width: 10, height: 10)) //Input connector positions if inputConnectors.count == 1 { inputConnectors[0].frame = CGRect( origin: CGPoint( x: 0, y: H/2 - (NodalConfiguration.connectorSize.width/2)), size: NodalConfiguration.connectorSize) inputLabels[0].sizeToFit() inputLabels[0].frame = CGRect( x: inputConnectors[0].frame.maxX, y: inputConnectors[0].frame.minY, width: inputLabels[0].frame.size.width, height: inputLabels[0].frame.size.height) print(inputConnectors[0].frame.origin) } else { let inputSpacing = (H - NodalConfiguration.connectorSize.width - 15)/CGFloat(inputConnectors.count - 1) inputConnectors .enumerated() .forEach{ $0.element.frame = CGRect( origin: CGPoint( x: 0, y: CGFloat($0.offset)*inputSpacing + (NodalConfiguration.connectorSize.width/2)), size: NodalConfiguration.connectorSize) inputLabels[$0.offset].sizeToFit() inputLabels[$0.offset].frame = CGRect( x: $0.element.frame.maxX, y: $0.element.frame.minY, width: inputLabels[$0.offset].frame.size.width, height: inputLabels[$0.offset].frame.size.height) } } //Output connector positions if outputConnectors.count == 1 { outputConnectors[0].frame = CGRect( origin: CGPoint( x: W - (NodalConfiguration.connectorSize.width), y: H/2 - (NodalConfiguration.connectorSize.width/2)), size: NodalConfiguration.connectorSize) outputLabels[0].sizeToFit() outputLabels[0].frame = CGRect( x: outputConnectors[0].frame.minX - outputLabels[0].frame.size.width, y: outputConnectors[0].frame.minY, width: outputLabels[0].frame.size.width, height: outputLabels[0].frame.size.height) } else { let outputSpacing = (H - NodalConfiguration.connectorSize.width - 15)/CGFloat(outputConnectors.count - 1) outputConnectors .enumerated() .forEach{ $0.element.frame = CGRect( origin: CGPoint( x: W - (NodalConfiguration.connectorSize.width), y: CGFloat($0.offset)*outputSpacing + (NodalConfiguration.connectorSize.width/2)), size: NodalConfiguration.connectorSize) outputLabels[$0.offset].sizeToFit() outputLabels[$0.offset].frame = CGRect( x: $0.element.frame.minX - outputLabels[$0.offset].frame.size.width, y: $0.element.frame.minY, width: outputLabels[$0.offset].frame.size.width, height: outputLabels[$0.offset].frame.size.height) } } backgroundShape.path = backgroundPath.cgPath backgroundShape.fillColor = NodalConfiguration.nodeColor.cgColor if panMode { backgroundShape.shadowColor = UIColor.black.cgColor backgroundShape.shadowOffset = CGSize(width: 5, height: 5) backgroundShape.shadowPath = backgroundShape.path backgroundShape.shadowOpacity = 0.85 } else { backgroundShape.shadowOpacity = 0.0 } let d = desiredCoordinates desiredCoordinates = d } } //MARK: Default touch handlers extension NodeView{ open override func hitTest(_ point: CGPoint, with event: UIEvent?) -> UIView? { var connector: Connector? = nil [inputConnectors, outputConnectors].forEach{ $0.forEach{ if $0.frame.contains(point){ connector = $0 } } } if let c = connector{ print("Selected connector \(c.index)") return nil//c } if self.frame.contains(convert(point, to: self.superview)){ return self } return nil } open override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) { self.panMode = true } open override func touchesEnded(_ touches: Set<UITouch>, with event: UIEvent?) { guard let newPosition = touches.first?.location(in: self) else { return } guard !isConnector(point: newPosition) else { return } self.desiredCoordinates = newPosition self.panMode = false } open override func touchesMoved(_ touches: Set<UITouch>, with event: UIEvent?) { guard let newPosition = touches.first?.location(in: self) else { return } guard !isConnector(point: newPosition) else { return } self.desiredCoordinates = newPosition } } //MARK: Custom touch handlers extension NodeView{ // open func touchMoved(_ point: CGPoint, with event: UIEvent?) -> UIView?{ var connector: UIView? = nil [inputConnectors, outputConnectors].forEach{ $0.forEach{ _ = $0.checkHover(point, with: event) if $0.frame.contains(point){ print("Hovering over connector with index: \($0.index)") connector = $0 } } } return connector } open func touchDown(_ point: CGPoint, with event: UIEvent?) -> Connector?{ var connector: Connector? = nil [inputConnectors, outputConnectors].forEach{ $0.forEach{ if $0.frame.contains(point){ print("Touch down on connector with index: \($0.index)") connector = $0 } } } return connector } open func touchUp(_ point: CGPoint, with event: UIEvent?) -> Connector?{ var connector: Connector? = nil [inputConnectors, outputConnectors].forEach{ $0.forEach{ if $0.frame.contains(point){ print("Touch up on connector with index: \($0.index)") connector = $0 $0.hoverMode = false } } } return connector } private func isConnector(point: CGPoint) -> Bool { var c: UIView? = nil [inputConnectors, outputConnectors].forEach{ $0.forEach{ if $0.frame.contains(point){ c = $0 } } } guard c == nil else { return true } return false } }
[ -1 ]
e6546985bf87a427e800084400e3062e6cfe9dd0
e89f1331e00978d9a8bb472850e8736774c8307c
/Table View/Table View/ViewController.swift
c3f83be1b919850de14c53ac406f9e6279a6df87
[]
no_license
tylerswartz/udemy_swift_apps
d6013da04366b11ebbfc19869dc4714ec377c1bd
da1aa9946b0550b0990828c3b642112962ec3de7
refs/heads/master
2021-01-10T02:27:00.692918
2015-12-20T21:40:41
2015-12-20T21:40:41
47,124,639
0
0
null
null
null
null
UTF-8
Swift
false
false
1,057
swift
// // ViewController.swift // Table View // // Created by Tyler Swartz on 10/18/15. // Copyright © 2015 swartz. All rights reserved. // import UIKit class ViewController: UIViewController, UITableViewDelegate { var cellContent = ["Tyler", "Jody"] override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. } func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return cellContent.count } func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { let cell = UITableViewCell(style: UITableViewCellStyle.Default, reuseIdentifier: "Cell") cell.textLabel?.text = cellContent[indexPath.row] return cell } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
[ -1 ]
e335f7b6dd1880cc7875a276c1dc637899304d9c
5f4ff89cd77f5e74ee05b91fefcf3ff6bbbf41a4
/ThreadSafe/ThreadSafe.swift
9ac13236182cc19682d873e5e5446b8e6373adef
[ "MIT" ]
permissive
leoture/AsynchronousSwift
64c8ae484ab4f06965fd6640e6feca386a02f1a6
49c4d368dfe9890717b4aa11aa31626f9b22d178
refs/heads/master
2021-05-09T14:05:02.857439
2018-03-29T09:26:27
2018-03-29T09:26:27
119,051,936
4
1
null
null
null
null
UTF-8
Swift
false
false
1,533
swift
// // Created by jordhan leoture on 05/02/2018. // Copyright (c) 2018 jordhan leoture. All rights reserved. // import Foundation private let internalQueueLabel = "AsynchronousSwift.ThreadSafe" public class ThreadSafe<VariableType> { fileprivate var wrapper: Wrapper<VariableType> private var callbacks: [(VariableType) -> Void] public let readOnly: ThreadSafeReadOnly<VariableType> public let readAndWrite: ThreadSafeReadAndWrite<VariableType> public init(_ variable: VariableType) { let internalQueue = DispatchQueue(label: internalQueueLabel, attributes: .concurrent) let _wrapper: Wrapper<VariableType> = Wrapper(value: variable) wrapper = _wrapper callbacks = [(VariableType) -> Void]() readOnly = ThreadSafeReadOnly<VariableType>(internalQueue: internalQueue, wrapper: _wrapper) readAndWrite = ThreadSafeReadAndWrite<VariableType>(internalQueue: internalQueue, wrapper: _wrapper) } public func unsafeValue() -> VariableType { return wrapper.value } public var value: VariableType { get { return readOnly.sync { $0 } } set { readAndWrite.async { value in value = newValue self.callbacks.forEach { $0(newValue) } } } } public func onChange(on queue: DispatchQueue = .global(), _ closure: @escaping (VariableType) -> Void) { callbacks.append({ value in queue.async { closure(value) } }) } } infix operator <- public func <-<VariableType>(left: ThreadSafe<VariableType>, right: VariableType) { left.value = right }
[ -1 ]
8cb851651b37565b0b47b33e3ce2fe1e7813a9f5
6306f9be8b0e86a47ddeeb5f6ab67bf7365cd1b6
/What Is It/ViewController.swift
2f84be366f177fcd6564b713debf4cb9ef06d649
[]
no_license
bencbernstein/whatisit
9d1beb0f2850a6453eea6dcf7fb0182a2edc845a
21fff2079d0c33dc7892439594e4497042ba154e
refs/heads/master
2021-01-21T10:46:43.109872
2017-03-01T17:17:12
2017-03-01T17:17:12
83,488,033
0
2
null
null
null
null
UTF-8
Swift
false
false
2,906
swift
// // ViewController.swift // What Is It // // Created by Benjamin Bernstein on 2/28/17. // Copyright © 2017 Burning Flowers. All rights reserved. // import UIKit class ViewController: UIViewController, UIImagePickerControllerDelegate, UINavigationControllerDelegate, UIGestureRecognizerDelegate { let watson = Watson() @IBOutlet weak var resultsLabel: UILabel! @IBOutlet weak var progressView: UIProgressView! @IBOutlet weak var tellMeButton: UIButton! @IBOutlet weak var image: UIImageView! @IBAction func pickImage(_ sender: UIButton) { let ImagePicker = UIImagePickerController() ImagePicker.delegate = self if sender.titleLabel?.text == "Photo Gallery" { ImagePicker.sourceType = UIImagePickerControllerSourceType.photoLibrary } else { ImagePicker.sourceType = .camera } self.present(ImagePicker, animated: true, completion: nil) } func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String : Any]) { image.image = info[UIImagePickerControllerOriginalImage] as? UIImage self.dismiss(animated: true) { self.tellMeButton.alpha = 1 self.resultsLabel.alpha = 0 } } @IBAction func tellMeWhatItIs(_ sender: Any) { let imageSmaller = image.image!.resized(withPercentage: 0.25) guard let image_data = UIImagePNGRepresentation(imageSmaller!) else { return } self.tellMeButton.alpha = 0 progressView.alpha = 1 self.resultsLabel.alpha = 1 self.resultsLabel.text = "I'm thinking, hang on!..." watson.uploadRequest(image: image_data, completion: { (returnClasses) in self.resultsLabel.text = self.watson.interpretResults(results: returnClasses) self.progressView.alpha = 0 }, progressCompletion: { (progress) in self.progressView.progress = Float(progress) }) } override func viewDidLoad() { super.viewDidLoad() tellMeButton.alpha = 0.0 resultsLabel.text = "Choose a picture to get started!" let gestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(handleTap(_:))) gestureRecognizer.delegate = self image.addGestureRecognizer(gestureRecognizer) image.isUserInteractionEnabled = true } func handleTap(_ gestureRecognizer: UITapGestureRecognizer) { let ImagePicker = UIImagePickerController() ImagePicker.delegate = self ImagePicker.sourceType = .camera self.present(ImagePicker, animated: true, completion: nil) } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
[ -1 ]
00ca5617e85670d58175f6204b0fd435d6755878
56ce6de4334971398f6f5bd5f757d3dc378fb5f0
/notebook/notebook/noteCell.swift
94f8f38dc545a3f93b4035886f609002559bfe7b
[]
no_license
myxixiya/notebook
41bdca61c46b6c71c36db7b88d43fa3ced8a19df
1662470687d81970dc1e5f7399a193acbaa25468
refs/heads/master
2021-06-19T23:07:35.965860
2017-06-22T04:03:38
2017-06-22T04:03:38
null
0
0
null
null
null
null
UTF-8
Swift
false
false
353
swift
// // noteCell.swift // notebook // // Created by Apple on 2017/5/21. // Copyright © 2017年 zhijian corporation. All rights reserved. // import UIKit class noteCell: UICollectionViewCell{ @IBOutlet weak var noteImage: UIImageView! @IBOutlet weak var Date: UILabel! override func awakeFromNib() { super.awakeFromNib() } }
[ -1 ]
ce3bf86ffba0aef46953fb01c8bb38ecfc790911
5cb7e9ebf21dfa04c54d6159281ab81015a766a7
/Yep/ViewControllers/Conversation/ConversationViewController+TextIndicator.swift
b0912909640ecfbb8378fa8c78a6507aa684c9d6
[ "MIT" ]
permissive
yuxiaoyick/Yep
fe9c77572fb2f376e8b5be0af5c6f4bfb387ad67
384ef243b5951a6b323e4ce4b5eb0259d33399cf
refs/heads/master
2020-12-03T10:40:37.588460
2016-09-08T08:10:11
2016-09-08T08:10:11
67,682,345
0
0
null
2016-09-08T08:06:36
2016-09-08T08:06:36
null
UTF-8
Swift
false
false
1,543
swift
// // ConversationViewController+TextIndicator.swift // Yep // // Created by NIX on 16/4/14. // Copyright © 2016年 Catch Inc. All rights reserved. // import UIKit import RealmSwift import YepKit import YepNetworking extension ConversationViewController { func promptSendMessageFailed(reason reason: Reason, errorMessage: String?, reserveErrorMessage: String) { if case .NoSuccessStatusCode(_, let errorCode) = reason where errorCode == ErrorCode.BlockedByRecipient { indicateBlockedByRecipient() } else { let message = errorMessage ?? reserveErrorMessage YepAlert.alertSorry(message: message, inViewController: self) } } private func indicateBlockedByRecipient() { SafeDispatch.async { [weak self] in if let conversation = self?.conversation { self?.indicateBlockedByRecipientInConversation(conversation) } } } private func indicateBlockedByRecipientInConversation(conversation: Conversation) { guard let realm = conversation.realm else { return } let message = Message() let messageID = "BlockedByRecipient." + NSUUID().UUIDString message.messageID = messageID message.blockedByRecipient = true message.conversation = conversation let _ = try? realm.write { realm.add(message) } updateConversationCollectionViewWithMessageIDs([messageID], messageAge: .New, scrollToBottom: true) } }
[ -1 ]
4f951661dafa48bf9a0e9183cab2b5b42a015ee2
e40afe6db8ad291b09052283fcc858c26064879f
/TodayNews/Classes/MicroHead/View/CollectionViewCell.swift
2df501998dfe32d534206d49f4c6e4b6b221e331
[ "MIT" ]
permissive
chenxiaopao/MyTodayNews
2811a0ac708942caf7f929e3f840cd162db10a08
b3c2e70263f1266188d5b0d58151fd295f178896
refs/heads/master
2020-03-19T12:18:01.989750
2018-06-07T23:27:51
2018-06-07T23:27:51
136,501,535
0
0
null
null
null
null
UTF-8
Swift
false
false
1,601
swift
// // CollectionViewCell.swift // TodayNews // // Created by 陈思斌 on 2018/5/5. // Copyright © 2018年 陈思斌. All rights reserved. // import UIKit import Kingfisher import SVProgressHUD class CollectionViewCell: UICollectionViewCell { @IBOutlet weak var thumbImgaeView: UIImageView! @IBOutlet weak var gifLabel: UILabel! var thumbImage = ThumbImage() { didSet { thumbImgaeView.kf.setImage(with: URL(string: thumbImage.urlString)!) gifLabel.isHidden = !(thumbImage.type == .gif) } } var thumb = ThumbImage() var largeImage = LargeImage() { didSet { thumbImgaeView.kf.setImage(with: URL(string: largeImage.urlString), progressBlock: { (receivedSize, totalSize) in let progress = Float(receivedSize/totalSize) SVProgressHUD.showProgress(progress) SVProgressHUD.setBackgroundColor(.clear) SVProgressHUD.setForegroundColor(UIColor.white) }) { (image, error, cacheType, url) in if image == nil{ self.thumbImgaeView.kf.setImage(with:URL(string: self.thumb.urlString) ) } SVProgressHUD.dismiss() } gifLabel.isHidden = true } } override func awakeFromNib() { super.awakeFromNib() // thumbImgaeView.layer.borderWidth = 1 // thumbImgaeView.layer.borderColor = UIColor.lightGray.cgColor thumbImgaeView.contentMode = .scaleAspectFit thumbImgaeView.sizeToFit() } }
[ -1 ]
312e1e6f3348ba20e2f2b0b31042ed030e2e2756
76e2e7957ea9f7645c43a9c0ec87e05dfcd55767
/ProgramacionSwift/18_inits.playground/Contents.swift
bb7a176c52ca708c5b01eab9b78b7f48bd5ad8f6
[]
no_license
martino2197/ios
739f3111f3df08af983e25bc2cd3e7ad5049cdc9
ea891ddee771f210beecf3dcba4209f92049cbc2
refs/heads/master
2022-11-27T18:12:14.588176
2020-08-09T01:22:05
2020-08-09T01:22:05
250,152,015
0
0
null
null
null
null
UTF-8
Swift
false
false
4,453
swift
import UIKit ///INICIALIZADORES struct Fahrenheit { //Darle un valor por defecto a todo es muy raro var temperature: Double // = 32 init() { self.temperature = 32 } } var f1 = Fahrenheit() struct Celsius{ var temperature: Double init(fromFarenheit fahrenheit: Double) { self.temperature = (fahrenheit - 32) / 1.8 } init(fromKelvin kelvin: Double) { self.temperature = kelvin - 273.15 } init(_ celsius: Double) { self.temperature = celsius } } let boillingPointOfWater = Celsius(fromFarenheit: 212) let freezingPointOfWater = Celsius(fromKelvin: 273.15) //Nombres, etiquetas y optionals struct Color{ let red, green, blue: Double init(red: Double, green: Double, blue: Double) { self.red = red self.green = green self.blue = blue } init(white: Double) { self.red = white self.green = white self.blue = white } } let magenta = Color(red: 1, green: 0, blue: 1) let halfGrey = Color(white: 0.5) let green = Color(red: 0,green: 1,blue: 0) let bodyTemperature = Celsius(37) class SurveyQuestion { let text: String //al ser opcional response, no hace falta inicializarla var response: String? init(_ text: String) { self.text = text } func ask() { print(text) } } let q1 = SurveyQuestion( "Te gustan los tacos?") q1.ask() q1.response = "Si, me encantan todos ellos" let q2 = SurveyQuestion( "Cual es tu nombre?") q2.ask() q2.response = "Luis Martin" //Inicializadores en Subclases //Designado -> Desginado super clase //Conveniencia -> Otro init de la misma clase //El ultimo init que se llame siempre debe ser designado class Vehicle { var numberOfWheels = 0 var description: String { return "\(numberOfWheels) ruedas" } } let vehicle = Vehicle() vehicle.description class Bicycle: Vehicle { //Inicializador Designado override init() { //siempre se debe empezar con super.init() para un override init() super.init() numberOfWheels = 2 } } let bicycle = Bicycle() bicycle.description class Hoverboard: Vehicle { var color: String //Inicializador por conveniencia init(color: String) { self.color = color //aqui se llama implicitamente a super.init() } override var description: String{ return "\(super.description) en el color \(self.color)" } } let hoverboard = Hoverboard(color: "Silver") print(hoverboard.description) //Failable Initializer enum TemperatureUnit { case kelvin, celsius, fahrenheint //init?() puede o no devolver un nil init?(symbol: Character) { switch symbol { case "K": self = .kelvin case "C": self = .celsius case "F": self = .fahrenheint default: return nil } } } let someUnit = TemperatureUnit(symbol: "A") class Product { let name: String init?(name: String) { if name.isEmpty{ return nil } self.name = name } } class CartItem: Product { let quantity: Int init?(name: String, quantity: Int) { if quantity < 1 { return nil } self.quantity = quantity super.init(name: name) } } //if let someSocks = CartItem(name: "", quantity: ) no va imprimir nada if let someSocks = CartItem(name: "Socks", quantity: 2){ print("\(someSocks.name) - \(someSocks.quantity)") } //Destruccion de Objetos con deinit class Bank { static var coinsInBank = 2_000 static func distribute(coins numberOfCoinsRequested: Int) -> Int { let numberOfCoinsToVend = min(numberOfCoinsRequested, coinsInBank) coinsInBank -= numberOfCoinsToVend return numberOfCoinsToVend } static func receive(coins: Int) { coinsInBank += coins } } class Player { var coinsInPurse: Int init(coins: Int) { self.coinsInPurse = Bank.distribute(coins: coins) } func win(coins: Int) { coinsInPurse += Bank.distribute(coins: coins) } deinit { Bank.receive(coins: coinsInPurse) } } //declaramo opcionar y var para poder destruirlo DESINICIALIZAR var playerOne: Player? = Player(coins: 100) Bank.coinsInBank playerOne!.win(coins: 2_000) Bank.coinsInBank playerOne = nil Bank.coinsInBank
[ -1 ]
8f28a86e3095b1d85cccd1a112ecb80b80f98e8a
f969b2b43155ab3ef8015a726cc2a80e69cc1ec0
/src/ui/button/text/SelectTextButton.swift
b964e55616fc9bd67ea967dd020e5d720c00b5c5
[ "MIT" ]
permissive
rbwimir/Element
570fb1383925a9f544637a5136032e7f08703ea5
cfe64f25b38095eda2466411a79bbb30bd4c9a1d
refs/heads/master
2020-12-28T19:56:34.520085
2016-05-11T09:59:21
2016-05-11T09:59:21
null
0
0
null
null
null
null
UTF-8
Swift
false
false
1,455
swift
import Cocoa /** * NOTE: Maybe the methods relating to ISelectable could be moved to an extension (Maybe not, since you need access to super, test this idea in playground) */ class SelectTextButton:TextButton,ISelectable { var isSelected:Bool; init(_ width : CGFloat, _ height : CGFloat, _ text : String = "defaultText", _ isSelected : Bool = false, _ parent : IElement? = nil, _ id : String? = nil){ self.isSelected = isSelected; super.init(width, height, text, parent, id) } required init?(coder: NSCoder) {fatalError("init(coder:) has not been implemented")} override func mouseUpInside(event: MouseEvent) { isSelected = true super.mouseUpInside(event) //NSNotificationCenter.defaultCenter().postNotificationName(SelectEvent.select, object:self)/*bubbles:true because i.e: radioBulet may be added to RadioButton and radioButton needs to dispatch Select event if the SelectGroup is to work*/ self.event!(SelectEvent(SelectEvent.select,self/*,self*/)) } /** * @Note: do not add a dispatch event here, that is the responsibilyy of the caller */ func setSelected(isSelected:Bool){ self.isSelected = isSelected setSkinState(getSkinState()); } func getSelected()->Bool{return isSelected} override func getSkinState() -> String { return isSelected ? SkinStates.selected + " " + super.getSkinState() : super.getSkinState(); } }
[ -1 ]
44ed8685e582f70d1c34e2bfb5e9b016badea505
8137d92294cb5c38256a7d15c6303af303d4870e
/my2048swift/TileView.swift
39f66e38cd31c4881f48373fe06b0ad1df3e8126
[]
no_license
MeiyiHe/my2048
6bbc60abf312ad545431e40d27efa51e0f5851a6
00f97245195e90a65e30d615dab219245da2512a
refs/heads/master
2021-01-12T07:28:02.180061
2020-03-29T20:30:27
2020-03-29T20:30:27
76,965,740
2
0
null
null
null
null
UTF-8
Swift
false
false
1,509
swift
// // TileView.swift // my2048swift // // Created by Meiyi He on 12/25/16. // Copyright © 2016 Meiyi He. All rights reserved. // import UIKit class TileView:UIView{ let colorMap = [ 2:UIColor.yellow, 4:UIColor.orange, 8:UIColor.red, 16:UIColor.green, 32:UIColor.brown, 64:UIColor.blue, 128:UIColor.purple, 256:UIColor.cyan, 512:UIColor.lightGray, 1024:UIColor.magenta, 2048:UIColor.black ] var value:Int = 0{ // when value changes, the didSet will be called to change the color and label didSet{ backgroundColor = colorMap[value] numberLabel.text = "\(value)" } } var numberLabel:UILabel init(pos:CGPoint, width:CGFloat, value:Int){ numberLabel = UILabel(frame: CGRect( x: 0, y: 0,width: width, height: width)) numberLabel.textColor = UIColor.white numberLabel.textAlignment = NSTextAlignment.center numberLabel.minimumScaleFactor = 0.5 numberLabel.font = UIFont(name:"Sans Seriff", size:20) numberLabel.text = "\(value)" super.init(frame: CGRect( x: pos.x, y: pos.y ,width: width, height: width)) addSubview(numberLabel) self.value = value backgroundColor = colorMap[value] } required init?(coder aDecoder: NSCoder) { fatalError("init(coder:) has not been implemented") } }
[ -1 ]
fd3ce5ab925797e1f0c2730208edae703f69da2f
2136183dfacba6d62276dc0642f215f5fd9e1141
/Final/Circle(圈子)/DCircleFinalDemo/Pods/DLogin/Code/DLogin/Login/VC/WLLogin2ViewController.swift
7a9063bdda5614a80084de094f90fded5a489c64
[ "MIT" ]
permissive
StoneStoneStoneWang/DRoutines
af42495f57443ab2117487ae6346dc21d7bdbde0
cf0205f4ad36aca2866165e95e52a32a609b2a9b
refs/heads/master
2020-06-14T03:24:20.325986
2019-08-14T03:14:34
2019-08-14T03:14:34
194,879,854
0
0
null
null
null
null
UTF-8
Swift
false
false
5,998
swift
// // WLLogin2ViewController.swift // WLUserKitDemo // // Created by three stone 王 on 2019/4/18. // Copyright © 2019 three stone 王. All rights reserved. // import Foundation import WLToolsKit import SnapKit @objc (WLLogin2ViewController) final class WLLogin2ViewController: WLLoginBaseViewController { final let iconImageView: UIImageView = UIImageView().then { $0.layer.cornerRadius = 50 $0.layer.masksToBounds = true $0.backgroundColor = .white $0.layer.borderWidth = 1 } final let topView: UIView = UIView().then { $0.layer.masksToBounds = true } override public func addOwnSubViews() { view.addSubview(topView) topView.addSubview(iconImageView) view.addSubview(phone) view.addSubview(password) view.addSubview(loginItem) view.addSubview(swiftLoginItem) view.addSubview(forgetItem) } override public func configOwnSubViews() { let margin: CGFloat = 15 if let config = config { iconImageView.layer.borderColor = WLHEXCOLOR(hexColor: config.itemColor).cgColor iconImageView.image = UIImage(named: config.logo) topView.backgroundColor = WLHEXCOLOR(hexColor: config.itemColor) topView.snp.makeConstraints { (make) in make.left.right.equalToSuperview() make.top.equalTo(WL_TOP_LAYOUT_GUARD) make.height.equalTo(WL_SCREEN_WIDTH / 2) } iconImageView.snp.makeConstraints { (make) in make.width.height.equalTo(100) make.center.equalTo(topView.snp.center) } phone.leftImageName = config.phoneIcon phone.attributedPlaceholder = NSAttributedString(string: "请输入手机号", attributes: [NSAttributedString.Key.foregroundColor: WLHEXCOLOR_ALPHA(hexColor: config.itemColor + "60")]) phone.set_bottomLineColor(WLHEXCOLOR_ALPHA(hexColor: "\(config.itemColor)60")) phone.set_bottomLineFrame(CGRect(x: 0, y: 59, width: WL_SCREEN_WIDTH - margin * 4, height: 1)) phone.snp.makeConstraints { (make) in make.left.equalTo(margin * 2) make.right.equalTo(-margin * 2) make.top.equalTo(topView.snp.bottom).offset(30) make.height.equalTo(60) } password.leftImageName = config.passwordIcon password.attributedPlaceholder = NSAttributedString(string: "请输入6-18位密码", attributes: [NSAttributedString.Key.foregroundColor: WLHEXCOLOR_ALPHA(hexColor: config.itemColor + "60")]) password.set_bottomLineColor(WLHEXCOLOR_ALPHA(hexColor: "\(config.itemColor)60")) password.set_bottomLineFrame(CGRect(x: 0, y: 59, width: WL_SCREEN_WIDTH - margin * 4, height: 1)) password.normalIcon = config.passwordItemNIcon password.selectedIcon = config.passwordItemSIcon password.passwordItem.sizeToFit() password.snp.makeConstraints { (make) in make.left.equalTo(phone.snp.left) make.right.equalTo(phone.snp.right) make.top.equalTo(phone.snp.bottom) make.height.equalTo(phone.snp.height) } loginItem.setBackgroundImage(UIImage.colorTransformToImage(color: WLHEXCOLOR(hexColor: config.itemColor)), for: .normal) loginItem.setBackgroundImage(UIImage.colorTransformToImage(color: WLHEXCOLOR_ALPHA(hexColor: "\(config.itemColor)60")), for: .highlighted) loginItem.snp.makeConstraints { (make) in make.left.equalTo(phone.snp.left) make.right.equalTo(phone.snp.right) make.top.equalTo(password.snp.bottom).offset(50) make.height.equalTo(50) } loginItem.setTitle("登录", for: .normal) loginItem.setTitle("登录", for: .highlighted) forgetItem.snp.makeConstraints { (make) in make.right.equalTo(loginItem.snp.right) make.top.equalTo(loginItem.snp.bottom).offset(margin * 2) } forgetItem.setTitleColor(WLHEXCOLOR(hexColor: config.itemColor), for: .normal) forgetItem.setTitleColor(WLHEXCOLOR_ALPHA(hexColor: config.itemColor + "60"), for: .highlighted) swiftLoginItem.setTitle("没有账号,前往注册/登录?", for: .normal) swiftLoginItem.setTitle("没有账号,前往注册/登录?", for: .highlighted) swiftLoginItem.setTitleColor(WLHEXCOLOR(hexColor: config.itemColor), for: .normal) swiftLoginItem.setTitleColor(WLHEXCOLOR_ALPHA(hexColor: config.itemColor + "60"), for: .highlighted) swiftLoginItem.snp.makeConstraints { (make) in make.centerX.equalToSuperview() make.bottom.equalToSuperview().offset(-margin * 2) } } } override public func configOwnProperties() { view.backgroundColor = WLHEXCOLOR(hexColor: "#ffffff") } }
[ -1 ]
caa16389c9745a579a88d458eb6bc153631e782c
ea2f9d517784cc41406ea480b27ab6d7abc5ffa5
/Source/Utils/Extensions/StringExtensions.swift
d057d0227d48af0d6fb3d78d66e8970220f7aeb3
[ "MIT" ]
permissive
mario2100/aural-player
8af90d3ff17fba997649e8b4b605cd152cd9d3e9
5046f1f15641921e85a44988c7bbed8a0250c0e2
refs/heads/master
2023-06-16T14:14:46.359653
2021-07-06T19:52:27
2021-07-06T19:52:27
null
0
0
null
null
null
null
UTF-8
Swift
false
false
9,545
swift
// // StringExtensions.swift // Aural // // Copyright © 2021 Kartik Venugopal. All rights reserved. // // This software is licensed under the MIT software license. // See the file "LICENSE" in the project root directory for license terms. // import Cocoa extension String { func truncate(font: NSFont, maxWidth: CGFloat) -> String { let selfWidth = size(withFont: font).width if selfWidth <= maxWidth { return self } let len = self.count var cur = len - 2 var str: String = "" while cur >= 0 { str = self.substring(range: 0..<(cur + 1)) + "..." let strWidth = str.size(withFont: font).width if strWidth <= maxWidth { return str } cur -= 1 } return str } func size(withFont font: NSFont) -> CGSize { size(withAttributes: [.font: font]) } /// /// For a given font, computes the width of the widest numerical character. /// static func widthOfWidestNumber(forFont font: NSFont) -> CGFloat { var maxWidth: CGFloat = 0 for number in 0...9 { let numString = String(number) let width = numString.size(withFont: font).width if width > maxWidth { maxWidth = width } } return maxWidth } // For a given piece of text rendered in a certain font, and a given line width, calculates the number of lines the text will occupy (e.g. in a multi-line label) func numberOfLines(font: NSFont, lineWidth: CGFloat) -> Int { let size: CGSize = self.size(withAttributes: [.font: font]) return Int(ceil(size.width / lineWidth)) } func withEncodingAndNullsRemoved() -> String { (self.removingPercentEncoding ?? self).replacingOccurrences(of: "\0", with: "") } // Splits a camel cased word into separate words, all capitalized. For ex, "albumName" -> "Album Name". This is useful for display within the UI. func splitAsCamelCaseWord(capitalizeEachWord: Bool) -> String { var newString: String = "" var firstLetter: Bool = true for eachCharacter in self { if (eachCharacter >= "A" && eachCharacter <= "Z") == true { // Upper case character // Add a space to delimit the words if (!firstLetter) { // Don't append a space if it's the first word (if first word is already capitalized as in "AlbumName") newString.append(" ") } else { firstLetter = false } if (capitalizeEachWord) { newString.append(eachCharacter) } else { newString.append(String(eachCharacter).lowercased()) } } else if (firstLetter) { // Always capitalize the first word newString.append(String(eachCharacter).capitalized) firstLetter = false } else { newString.append(eachCharacter) } } return newString } // Joins multiple words into one camel-cased word. For example, "Medium hall" -> "mediumHall" func camelCased() -> String { var newString: String = "" var wordStart: Bool = false for eachCharacter in self { // Ignore spaces if eachCharacter == " " { wordStart = true continue } if newString == "" { // The very first character needs to be lowercased newString.append(String(eachCharacter).lowercased()) } else if (wordStart) { // The first character of subsequent words needs to be capitalized newString.append(String(eachCharacter).capitalized) wordStart = false } else { newString.append(eachCharacter) } } return newString } func lowerCasedAndTrimmed() -> String {self.lowercased().trim()} // Checks if the string 1 - is non-null, 2 - has characters, 3 - not all characters are whitespace static func isEmpty(_ string: String?) -> Bool { string == nil ? true : string!.isEmptyAfterTrimming } var isEmptyAfterTrimming: Bool { trim().isEmpty } func trim() -> String { return self.trimmingCharacters(in: CharacterSet.whitespacesAndNewlines) } func capitalizingFirstLetter() -> String { return prefix(1).uppercased() + (self.count > 1 ? self.substring(range: 1..<self.count) : "") } subscript (index: Int) -> Character { let charIndex = self.index(self.startIndex, offsetBy: index) return self[charIndex] } func substring(range: Range<Int>) -> String { let startIndex = self.index(self.startIndex, offsetBy: range.startIndex) let stopIndex = self.index(self.startIndex, offsetBy: range.startIndex + range.count) return String(self[startIndex..<stopIndex]) } var isAcronym: Bool { !self.contains(where: {$0.isLowercase}) } func alphaNumericMatch(to other: String) -> Bool { if self == other {return true} if count != other.count {return false} var characterMatch: Bool = false for index in 0..<count { let myChar = self[index] let otherChar = other[index] if myChar.isAlphaNumeric && otherChar.isAlphaNumeric { if myChar != otherChar { return false } else { characterMatch = true } } } return characterMatch } // The lower the number, the better the match. 0 means perfect match. func similarityToString(other: String) -> Int { if self == other {return 0} let myLen = self.count let otherLen = other.count let matchLen = min(myLen, otherLen) var score: Int = 0 for index in 0..<matchLen { if self[index] != other[index] { score.increment() } } if myLen != otherLen { score += abs(myLen - otherLen) } return score } func matches(_ regex: String) -> Bool { return self.range(of: regex, options: .regularExpression, range: nil, locale: nil) != nil } func encodedAsURLComponent() -> String { self.addingPercentEncoding(withAllowedCharacters: .alphanumerics) ?? self.replacingOccurrences(of: " ", with: "%20") } func draw(in rect: NSRect, withFont font: NSFont, andColor color: NSColor) { self.draw(in: rect, withAttributes: [.font: font, .foregroundColor: color]) } func draw(in rect: NSRect, withFont font: NSFont, andColor color: NSColor, style: NSParagraphStyle) { self.draw(in: rect, withAttributes: [.font: font, .foregroundColor: color, .paragraphStyle: style]) } /* Takes a formatted artist/album string like "Artist -- Album" and truncates it so that it fits horizontally within a text view. */ static func truncateCompositeString(_ font: NSFont, _ maxWidth: CGFloat, _ fullLengthString: String, _ s1: String, _ s2: String, _ separator: String) -> String { // Check if the full length string fits. If so, no need to truncate. let origWidth = fullLengthString.size(withFont: font).width if origWidth <= maxWidth { return fullLengthString } // If fullLengthString doesn't fit, find out which is longer ... s1 or s2 ... truncate the longer one just enough to fit let w1 = s1.size(withFont: font).width let w2 = s2.size(withFont: font).width if w1 > w2 { // Reconstruct the composite string with the truncated s1 let wRemainder1: CGFloat = origWidth - w1 // Width available for s1 = maximum width - (original width - s1's width) let max1: CGFloat = maxWidth - wRemainder1 let t1 = s1.truncate(font: font, maxWidth: max1) return String(format: "%@%@%@", t1, separator, s2) } else { // s2 is longer than s1, simply truncate the string as a whole return fullLengthString.truncate(font: font, maxWidth: maxWidth) } } } extension Character { var isAlphaNumeric: Bool {self.isLetter || self.isNumber} } extension Substring.SubSequence { func trim() -> String { return self.trimmingCharacters(in: CharacterSet.whitespacesAndNewlines) } }
[ -1 ]
6b7ccc3246c79363a8c113f8cc8731b85b2b06c2
1d3a2f985fd826f938a99f0b86b8a58f333a006c
/MeetPaws/MeetPaws/Models/Messages.swift
631e51a24862e5c620b9911d25d45c1fcd820a2b
[ "MIT" ]
permissive
princekili/MeetPaws
1034f42ce3aa91b8de9b46c9ce97e5af5f83d588
1e73b70b3ad25798386a4579e34597559617a730
refs/heads/main
2023-02-16T01:43:36.302474
2021-01-14T09:06:39
2021-01-14T09:06:39
316,391,291
0
0
null
null
null
null
UTF-8
Swift
false
false
886
swift
// // Messages.swift // MeetPaws // // Created by prince on 2020/12/20. // import Foundation import Firebase class Messages { var message: String! var sender: String! var recipient: String! var time: NSNumber! var mediaUrl: String! var audioUrl: String! var videoUrl: String! var storageID: String! var imageWidth: NSNumber! var imageHeight: NSNumber! var id: String! var repMessage: String! var repMediaMessage: String! var repMID: String! var repSender: String! // MARK: - func determineUser() -> String { guard let uid = Auth.auth().currentUser?.uid else { return "" } if sender == uid { return recipient } else { return sender } } }
[ -1 ]
4dd99f66e7e4057482355bf95ec86afe37b7e2b2
fd95bfc72fd3d89137b3e7ffd3ee0a7d2298414d
/API/API/Manager/DatabaseManager.swift
637c0fcc74faef36a85a01c8fb18a84f05d1897e
[]
no_license
KodliOS/Todo
22d99e8a47931127afde0f5fe066a7aded03337f
b94a0cdcd7563e7fb5823754965995de144a728a
refs/heads/master
2020-09-27T03:26:32.927885
2019-12-06T21:50:49
2019-12-06T21:50:49
226,417,644
1
1
null
null
null
null
UTF-8
Swift
false
false
326
swift
// // DatabaseManager.swift // API // // Created by Yasin Akbaş on 6.12.2019. // Copyright © 2019 Yasin Akbaş. All rights reserved. // import Foundation public class DatabaseManager<T:Identifiable> { public func getTodoList() -> [T] { return Todo.all() as! [T] } public init() { } }
[ -1 ]
a01b21283b74515ef605aedbbb88c28662562850
78833aa85fbd231892b9386dfb0ed349d59cd8a2
/SwiftHomework/02.Video/VideoCell.swift
17270d74592b42020fbc3ad0daf60611ef9bb957
[]
no_license
Shizq5509/SwiftHomework
f33ea07dc4080c2ebf7619f2d7dd367a1afff929
34853aac5475e74380210bead08b0413cf71ef87
refs/heads/master
2020-03-13T10:48:48.213445
2018-04-26T09:44:24
2018-04-26T09:44:24
131,090,648
0
0
null
null
null
null
UTF-8
Swift
false
false
3,110
swift
// // VideoCell.swift // SwiftHomework // // Created by shi.zhengqian on 2018/4/26. // Copyright © 2018年 shi.zhengqian. All rights reserved. // import UIKit import AVKit import AVFoundation struct video { let image: String let title: String let source: String } class VideoCell: UITableViewCell { var videoScreenshot: UIImageView = UIImageView() var videoPlayButton: UIButton = UIButton() var videoTitleLabel: UILabel = UILabel() var videoSourceLabel: UILabel = UILabel() override init(style: UITableViewCellStyle, reuseIdentifier: String?) { super.init(style: style, reuseIdentifier: reuseIdentifier) self.contentView.addSubview(videoScreenshot) self.contentView.addSubview(videoPlayButton) self.contentView.addSubview(videoTitleLabel) self.contentView.addSubview(videoSourceLabel) videoScreenshot.snp.makeConstraints { (make) in make.center.equalTo(self.contentView) make.size.equalTo(self.contentView) } videoPlayButton.addTarget(self, action: #selector(onPlay), for: UIControlEvents.touchUpInside) videoPlayButton.setImage(UIImage(named: "playBtn"), for: UIControlState.normal) videoPlayButton.snp.makeConstraints { (make) in make.center.equalTo(self.contentView) make.size.equalTo(self.contentView).multipliedBy(0.5) } videoTitleLabel.font = UIFont(name: "Avenir Next Heavy", size: 14) videoTitleLabel.textColor = UIColor.white videoTitleLabel.snp.makeConstraints { (make) in make.centerX.equalTo(self.contentView) make.top.equalTo(videoPlayButton.snp.bottom).offset(6) } videoSourceLabel.font = UIFont(name: "Avenir Next Heavy", size: 10) videoSourceLabel.textColor = UIColor.lightText videoSourceLabel.snp.makeConstraints { (make) in make.top.equalTo(videoTitleLabel.snp.bottom).offset(6) make.centerX.equalTo(self.contentView) } } required init?(coder aDecoder: NSCoder) { fatalError("init(coder:) has not been implemented") } func setupWithModel(model:video) { videoScreenshot.image = UIImage(named: model.image) videoTitleLabel.text = model.title videoSourceLabel.text = model.source } @objc func onPlay() { let path = Bundle.main.path(forResource: "emoji zone", ofType: "mp4") let playerView = AVPlayer(url: URL(fileURLWithPath: path!)) let playerVC = AVPlayerViewController() playerVC.player = playerView UIApplication.shared.keyWindow?.rootViewController?.present(playerVC, animated: true, completion: { playerVC.player?.play() }) } override func awakeFromNib() { super.awakeFromNib() // Initialization code } override func setSelected(_ selected: Bool, animated: Bool) { super.setSelected(selected, animated: animated) // Configure the view for the selected state } }
[ -1 ]
939161262bc7351cfb4cc84e33dba122b70ff39e
588e35cacc82f94950ddc418da16ae5580d8dd28
/On the Map/Controller/UIViewController+Extension.swift
7f0c1b9c2e924683a8a272308c22d36356cc6e40
[]
no_license
shedo/On-The-Map
d584372cbd09389f0a0e43d7aeb7a672f9d2ba64
96f134b3a09e0eef98886e4160a2aefd548c9903
refs/heads/main
2023-01-06T16:42:16.834907
2020-11-12T07:45:59
2020-11-12T07:45:59
311,749,685
0
0
null
null
null
null
UTF-8
Swift
false
false
1,094
swift
// // UIViewController+Extension.swift // On the Map // // Created by Ivan Zandonà on 10/11/2020. // import Foundation import UIKit extension UIViewController { static var spinner: UIActivityIndicatorView? func showAlertDialog(title:String, message: String) { let alertVC = UIAlertController(title: title, message: message, preferredStyle: .alert) alertVC.addAction(UIAlertAction(title: "OK", style: .default, handler: nil)) present(alertVC, animated: true, completion:nil) } func showLoader(show: Bool) { if show { UIViewController.spinner = UIActivityIndicatorView(style: UIActivityIndicatorView.Style.medium) UIViewController.spinner?.center = view.center UIViewController.spinner?.hidesWhenStopped = false UIViewController.spinner?.startAnimating() if let spinner = UIViewController.spinner { view.addSubview(spinner) } } else { UIViewController.spinner?.removeFromSuperview() } } }
[ -1 ]
701fdebe018f1d04e522fb1342af4aa9fb63581a
2048538e075fd8b607a5cb5cf68a5d76585d4bce
/ios/MessagesExtension/MessagesModule.swift
4a0582f800474f04f620725884efcdc74357027a
[]
no_license
jqn-io/rn-input-extensions-blog
acdcf9b5daead2597f851ab91f435129ae954021
c2c45c4ff8fc03ba872b6c57ff53f1fd7c6d66e3
refs/heads/main
2023-08-18T16:29:52.902307
2021-09-13T12:36:30
2021-09-13T12:36:30
null
0
0
null
null
null
null
UTF-8
Swift
false
false
2,575
swift
// // MessagesModule.swift // MessagesExtension // import Foundation import Messages @objc(MessagesModule) class MessagesModule: NSObject { let viewController: MessagesViewController static func moduleName() -> String! { "RCTMessages" } static func requiresMainQueueSetup() -> Bool { false } init(viewController: MessagesViewController) { self.viewController = viewController } /** Insert a sticker into the active conversation. */ @objc func insertSticker( _ stickerUrl: String, resolver resolve: @escaping RCTPromiseResolveBlock, rejector reject: @escaping RCTPromiseRejectBlock ) { guard let conversation = viewController.activeConversation else { return reject("ERROR", "No active conversation", nil) } guard let url = URL.init(string: stickerUrl) else { return reject("ERROR", "Invalid sticker URL", nil) } // This will be called when the sticker URL is resolved (in dev mode the // URLs will be http://, which MSSticker can't handle) func insertSticker(_ url: URL) { guard let sticker = try? MSSticker.init( contentsOfFileURL: url, localizedDescription: "sticker") else { return reject("ERROR", "Could not load sticker", nil) } conversation.insert(sticker) { error in if error != nil { reject("ERROR", "Could not insert sticker \(url)", error) } else { resolve(nil) } } // After inserting a sticker, request that the extension collapse back to // compact mode viewController.requestPresentationStyle(.compact) } if !url.isFileURL { // If the URL isn't a file URL, download it to a temp file and insert that URLSession.shared.downloadTask(with: url) { (tempFileUrl, response, error) in if let tmpFile = tempFileUrl { guard let data = try? Data(contentsOf: tmpFile) else { return reject("ERROR", "Could not read downloaded sticker", nil) } let documents = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask)[0] let fileUrl = documents.appendingPathComponent("temp.png") do { try data.write(to: fileUrl) insertSticker(fileUrl) } catch { reject("ERROR", "Could not save downloaded sticker", nil) } } }.resume() } else { // For file URLs, just insert them insertSticker(url) } } }
[ -1 ]
cac66ae4a18a32d538c5859e3935087085b7ad04
d8c58f584573f8ed9e14362889f23cee9786fca2
/Swift实战/Mine/View/MineTopView.swift
25459b1d9b1358bf589c85b617a60f9ba24124ee
[]
no_license
NieYinlong/SwiftDemo
0929957f8e2f5e59f826925c533806eb23e6b99c
ac1394e46ae8ff1c1fba7b06bd031febc9888f7f
refs/heads/master
2020-05-07T21:33:06.193671
2019-04-12T01:48:52
2019-04-12T01:48:52
180,909,080
1
0
null
null
null
null
UTF-8
Swift
false
false
408
swift
// // MineTopView.swift // Swift实战 // // Created by nyl on 2018/11/2. // Copyright © 2018年 nieyinlong. All rights reserved. // import UIKit class MineTopView: UIView { /* // Only override draw() if you perform custom drawing. // An empty implementation adversely affects performance during animation. override func draw(_ rect: CGRect) { // Drawing code } */ }
[ -1 ]
d36cffca4be5173566cf5d884d5844ed320995a9
0fd42ad8fb16eafcf11a6dcd87d080af6c650f59
/Provenance/Game Library/UI/Game Library/CollectionViewController/PVGameLibraryViewController+CollectionView.swift
7e3a6450a2029ddb2ecb71e5bf78701026bffd5a
[ "MIT", "BSD-2-Clause" ]
permissive
levyilan/Provenance
8a3dc181313e35064632786a8ff053fd22ab7cdb
35fb8e52519418aabd0afce7e9553b1d54709c82
refs/heads/develop
2020-09-03T22:35:55.173513
2020-08-30T04:37:43
2020-08-30T04:37:43
219,589,971
0
0
NOASSERTION
2020-08-30T04:37:45
2019-11-04T20:25:11
null
UTF-8
Swift
false
false
5,412
swift
// // PVGameLibraryViewController+CollectionView.swift // Provenance // // Created by Joseph Mattiello on 5/26/18. // Copyright © 2018 Provenance. All rights reserved. // import Foundation import PVLibrary import PVSupport import RxCocoa import RxSwift #if canImport(RxGesture) import RxGesture #endif // tvOS let tvOSCellUnit: CGFloat = 256.0 // MARK: - UICollectionViewDelegateFlowLayout extension PVGameLibraryViewController: UICollectionViewDelegateFlowLayout { var minimumInteritemSpacing: CGFloat { #if os(tvOS) return 24.0 #else return 10.0 #endif } func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { #if os(tvOS) return tvos_collectionView(collectionView, layout: collectionViewLayout, sizeForItemAt: indexPath) #else return ios_collectionView(collectionView, layout: collectionViewLayout, sizeForItemAt: indexPath) #endif } #if os(iOS) private func ios_collectionView(_ collectionView: UICollectionView, layout _: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { var height: CGFloat = PVSettingsModel.shared.showGameTitles ? 144 : 100 let viewWidth = transitioningToSize?.width ?? collectionView.bounds.size.width let itemsPerRow: CGFloat = viewWidth > 800 ? 6 : 3 var width: CGFloat = (viewWidth / itemsPerRow) - (minimumInteritemSpacing * itemsPerRow * 0.67) let item: Section.Item = try! collectionView.rx.model(at: indexPath) switch item { case .game: width *= collectionViewZoom height *= collectionViewZoom case .saves, .favorites, .recents: // TODO: Multirow? let numberOfRows = 1 width = viewWidth height = (height + PageIndicatorHeight + 24) * CGFloat(numberOfRows) } return .init(width: width, height: height) } #endif #if os(tvOS) private func tvos_collectionView(_ collectionView: UICollectionView, layout _: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { let item: Section.Item = try! collectionView.rx.model(at: indexPath) let viewWidth = transitioningToSize?.width ?? collectionView.bounds.size.width switch item { case .game(let game): let boxartSize = CGSize(width: tvOSCellUnit, height: tvOSCellUnit / game.boxartAspectRatio.rawValue) return PVGameLibraryCollectionViewCell.cellSize(forImageSize: boxartSize) case .saves: // TODO: Multirow? let numberOfRows: CGFloat = 1.0 let width = viewWidth - collectionView.contentInset.left - collectionView.contentInset.right / 4 let height = tvOSCellUnit * numberOfRows + PageIndicatorHeight return PVSaveStateCollectionViewCell.cellSize(forImageSize: CGSize(width: width, height: height)) case .favorites, .recents: let numberOfRows: CGFloat = 1.0 let width = viewWidth - collectionView.contentInset.left - collectionView.contentInset.right / 5 let height: CGFloat = tvOSCellUnit * numberOfRows + PageIndicatorHeight return PVSaveStateCollectionViewCell.cellSize(forImageSize: CGSize(width: width, height: height)) } } #endif #if os(tvOS) func collectionView(_ collectionView: UICollectionView, layout _: UICollectionViewLayout, minimumLineSpacingForSectionAt section: Int) -> CGFloat { let item: Section.Item = try! collectionView.rx.model(at: IndexPath(item: 0, section: section)) switch item { case .game: return 88 case .saves, .favorites, .recents: return 0 } } #endif func collectionView(_ collectionView: UICollectionView, layout _: UICollectionViewLayout, minimumInteritemSpacingForSectionAt section: Int) -> CGFloat { let item: Section.Item? = firstModel(in: collectionView, at: section) switch item { case .none: return .zero case .some(.game): return minimumInteritemSpacing case .saves, .favorites, .recents: return 0 } } func collectionView(_ collectionView: UICollectionView, layout _: UICollectionViewLayout, insetForSectionAt section: Int) -> UIEdgeInsets { #if os(tvOS) return UIEdgeInsets(top: 32, left: 0, bottom: 64, right: 0) #else let item: Section.Item? = firstModel(in: collectionView, at: section) switch item { case .none: return .zero case .some(.game): return .init(top: section == 0 ? 5 : 15, left: 10, bottom: 5, right: 10) case .saves, .favorites, .recents: return .zero } #endif } private func firstModel(in collectionView: UICollectionView, at section: Int) -> Section.Item? { guard collectionView.numberOfItems(inSection: section) > 0 else { return nil } return try? collectionView.rx.model(at: IndexPath(item: 0, section: section)) } }
[ -1 ]
803d7f5a93d1b771de7cd442a280e4207d854818
5a565fe42b110aed54040e9f8edd2330df05b0cb
/ChattingQuiz/Game/GameVC+CollectionView.swift
96d2e682334da8eb0b8e1a79f58993650f8df66e
[]
no_license
krgoodnews/ChattingQuiz
87754eba2b2eb698d24041ef5b0d0bae24dba9f9
2e2de5c545b88ad011fc2067a8c5dd35a0ec4cf2
refs/heads/master
2020-03-25T21:20:37.868108
2019-08-29T09:13:49
2019-08-29T09:13:49
144,171,361
0
0
null
2019-08-29T09:13:50
2018-08-09T15:28:01
Swift
UTF-8
Swift
false
false
1,539
swift
// // GameVC+CollectionView.swift // ChattingQuiz // // Created by Goodnews on 2018. 8. 14.. // Copyright © 2018년 krgoodnews. All rights reserved. // import UIKit // MARK: Collection View extension GameVC: UICollectionViewDelegate, UICollectionViewDataSource, UICollectionViewDelegateFlowLayout { func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { return usersUID.count } func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { let cell = collectionView.dequeueReusableCell(withReuseIdentifier: userCellID, for: indexPath) as! UserCell cell.userUID = usersUID[indexPath.item] return cell } func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, minimumLineSpacingForSectionAt section: Int) -> CGFloat { return 2 } func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, minimumInteritemSpacingForSectionAt section: Int) -> CGFloat { return 2 } func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { return CGSize(width: 60, height: 86) } func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, insetForSectionAt section: Int) -> UIEdgeInsets { return UIEdgeInsets(top: 0, left: 14, bottom: 0, right: 14) } }
[ -1 ]
29779abefcf76d419aecac0b3d20565860869f65
005b400f2dbd06f56a1c2e915b28ade97dbf529b
/TestTask/RequestHelper.swift
1fd7adc688c585639feb18c46cf1c39bed3719c8
[]
no_license
ilyalapan/TestTask
9aeb2115b7441c9e9306e970caefae140c6e91d1
5b25ca7b490c415a93c53ba1b4d8ec3c1b9de493
refs/heads/master
2021-06-19T20:34:43.601348
2016-12-15T14:07:29
2016-12-15T14:07:29
76,430,367
0
0
null
null
null
null
UTF-8
Swift
false
false
2,077
swift
import Foundation import Alamofire enum ServerRequestResponse: String { case Success = "successful" case Unathorised = "unauthorised" case BadRequest = "bad reqeust" case BadResponse = "bad response" case Other = "other" case Failed = "failed" case Empty = "empty" //TODO: expand } enum ServerResponseError : Error { case Unathorised case BadRequest case NoResponseStatus case BadResponse case Failed case Unknown case Empty } class RequestHelper { //TODO: possibly make this an extension of Alamofire static let helper = RequestHelper() static func checkResponse(responseJSON: Alamofire.DataResponse<Any> ) throws -> Dictionary<String, AnyObject> { if let JSON = responseJSON.result.value { if let dict = JSON as? Dictionary<String, AnyObject>{ do { try checkStatus(responseDict: dict) } //TODO: catch all errors return dict } } throw ServerResponseError.BadResponse } static func checkStatus(responseJSON: Alamofire.DataResponse<Any> ) throws { if let JSON = responseJSON.result.value { if let dict = JSON as? Dictionary<String, AnyObject>{ do { try checkStatus(responseDict: dict) return } } } print("Bad Response") throw ServerResponseError.BadResponse } static func checkStatus(responseDict: Dictionary<String, AnyObject> ) throws { if let rawValue = responseDict["status"] { if let status = ServerRequestResponse(rawValue: rawValue as! String) { switch status { case ServerRequestResponse.Success: return default: print("Unknown error") throw ServerResponseError.Unknown } } } } }
[ -1 ]
69ab0d6dd9d672bef115f7dbba2c58933f3d1a7f
3550dd5a93cb14c88079d9b4aa88237f2b8e3c71
/test8/TableView/TableViewTests/TableViewTests.swift
737cee37f93d91e3c05243c62b744be518719c71
[]
no_license
2016110324/shiyan8-9
00b3ca6818d605b6bab03cf3b5f2886ac941e03d
9cb136affdd6c88eef302a57aa972f4a3118a21b
refs/heads/master
2020-04-12T01:18:51.601808
2018-12-18T04:10:03
2018-12-18T04:10:03
162,228,481
0
0
null
null
null
null
UTF-8
Swift
false
false
909
swift
// // TableViewTests.swift // TableViewTests // // Created by student on 2018/12/8. // Copyright © 2018年 liuyuping. All rights reserved. // import XCTest @testable import TableView class TableViewTests: XCTestCase { override func setUp() { // Put setup code here. This method is called before the invocation of each test method in the class. } override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. } func testExample() { // This is an example of a functional test case. // Use XCTAssert and related functions to verify your tests produce the correct results. } func testPerformanceExample() { // This is an example of a performance test case. self.measure { // Put the code you want to measure the time of here. } } }
[ 282633, 313357, 182296, 241692, 98333, 16419, 102437, 229413, 292902, 204840, 354345, 223274, 278570, 344107, 233517, 102445, 124975, 253999, 346162, 229430, 319542, 124984, 358456, 288833, 352326, 311372, 354385, 196691, 315476, 280661, 329814, 278615, 338007, 307289, 200794, 354393, 309345, 280675, 280677, 313447, 278634, 315498, 319598, 288879, 352368, 299121, 284788, 233589, 280694, 333940, 237689, 215164, 313469, 215166, 278655, 292992, 333955, 280712, 215178, 319629, 241808, 323729, 325776, 317587, 278677, 284826, 278685, 346271, 311458, 278691, 49316, 233636, 333991, 333992, 284842, 32941, 278704, 239793, 278708, 125109, 131256, 182456, 184505, 299198, 379071, 299203, 301251, 309444, 338119, 282831, 321745, 254170, 356576, 327904, 338150, 176362, 286958, 125169, 338164, 327929, 184570, 243962, 125183, 309503, 125188, 313608, 125193, 375051, 180493, 125198, 325905, 254226, 125203, 125208, 325912, 299293, 278816, 125217, 233762, 211235, 217380, 305440, 151847, 282919, 321840, 125235, 332085, 280887, 125240, 332089, 278842, 282939, 315706, 287041, 241986, 260418, 332101, 182598, 323916, 319821, 254286, 348492, 250192, 6481, 323920, 344401, 348500, 366929, 155990, 366930, 325968, 6489, 272729, 379225, 106847, 323935, 391520, 321894, 242023, 280939, 242029, 246127, 354676, 139640, 246136, 246137, 291192, 313727, 362881, 248194, 225670, 395659, 227725, 395661, 240016, 108944, 291224, 317852, 121245, 283038, 61857, 285090, 61859, 289189, 375207, 340398, 377264, 61873, 61880, 283064, 278970, 319930, 311738, 336317, 293310, 278978, 127427, 127428, 283075, 188871, 324039, 317901, 281040, 278993, 326100, 278999, 328152, 176601, 242139, 369116, 285150, 287198, 279008, 342498, 242148, 195045, 279013, 279018, 281072, 279029, 279032, 233978, 279039, 342536, 287241, 279050, 340490, 279062, 289304, 279065, 342553, 291358, 182817, 375333, 377386, 283184, 23092, 315960, 352829, 301638, 348742, 322120, 55881, 348749, 281166, 244310, 354911, 436832, 66150, 111208, 344680, 191082, 313966, 281199, 279164, 189057, 311941, 348806, 279177, 369289, 330379, 344715, 184973, 311949, 330387, 330388, 352917, 227990, 230040, 271000, 342682, 279206, 295590, 287404, 303793, 299699, 299700, 164533, 338613, 314040, 287417, 158394, 342713, 109241, 285373, 66242, 363211, 242386, 279252, 318173, 289502, 363230, 295652, 338662, 285415, 346858, 289518, 312052, 199414, 154359, 221948, 35583, 205568, 162561, 299776, 363263, 285444, 117517, 322319, 312079, 166676, 207640, 326429, 336671, 326433, 344865, 279336, 318250, 295724, 152365, 312108, 318252, 353069, 328499, 242485, 353078, 230199, 353079, 336702, 420677, 353094, 353095, 299849, 283467, 293711, 281427, 353109, 244568, 281433, 230234, 244570, 322395, 109409, 293730, 242529, 303972, 351077, 275303, 342887, 242541, 246641, 330609, 109428, 246648, 209785, 269178, 177019, 279417, 361337, 254850, 359298, 240518, 287622, 228233, 228234, 308107, 316298, 56208, 295824, 308112, 209817, 324506, 324507, 318364, 189348, 324517, 289703, 240552, 353195, 140204, 353197, 353216, 349121, 363458, 213960, 279498, 316364, 338899, 340955, 248797, 207838, 50143, 130016, 340961, 64485, 314342, 123881, 324586, 289774, 304110, 320494, 340974, 316405, 240630, 295927, 201720, 304122, 314362, 320507, 328700, 328706, 320516, 230410, 320527, 146448, 324625, 316437, 418837, 197657, 281626, 201755, 336929, 300068, 357414, 248872, 345132, 238639, 252980, 300084, 322612, 359478, 324666, 238651, 302139, 21569, 314436, 359495, 238664, 300111, 314448, 341073, 353367, 156764, 156765, 314467, 281700, 250981, 322663, 300136, 316520, 228458, 207979, 316526, 357486, 187506, 353397, 160891, 341115, 363644, 150657, 187521, 248961, 349316, 279685, 349318, 222343, 228491, 228493, 285838, 169104, 162961, 177296, 308372, 326804, 296086, 119962, 300187, 296092, 300188, 339102, 302240, 343203, 300201, 300202, 253099, 238765, 318639, 279728, 367799, 339130, 64700, 343234, 367810, 259268, 283847, 353479, 62665, 353481, 353482, 244940, 283852, 283853, 290000, 228563, 296153, 357595, 279774, 298212, 304356, 330984, 228588, 234733, 253167, 279792, 353523, 298228, 216315, 208124, 316669, 363771, 388349, 228609, 320770, 279814, 322824, 242954, 292107, 312587, 328971, 251153, 245019, 320796, 126237, 130338, 208164, 130343, 351537, 345396, 326966, 300343, 318775, 116026, 312634, 222524, 312635, 286018, 193859, 279875, 230729, 224586, 372043, 177484, 251213, 238927, 296273, 120148, 318805, 283991, 222559, 314720, 292195, 230756, 294243, 333160, 230765, 243056, 279920, 312689, 314739, 116084, 327025, 327024, 327031, 306559, 378244, 298374, 314758, 314760, 388487, 368011, 304524, 314766, 296335, 112017, 112018, 234898, 306579, 282007, 357786, 290207, 314783, 333220, 314789, 279974, 282024, 241066, 316842, 286129, 173491, 210358, 284089, 228795, 292283, 302529, 302531, 163268, 380357, 415171, 300487, 361927, 300489, 370123, 148940, 280013, 310732, 64975, 312782, 327121, 222675, 366037, 210390, 210391, 353750, 210393, 228827, 286172, 310757, 187878, 280041, 361963, 54765, 191981, 321009, 251378, 343542, 280055, 300536, 288249, 343543, 286205, 290301, 210433, 282114, 228867, 366083, 323080, 230921, 253452, 323087, 304656, 329232, 316946, 146964, 398869, 308764, 349726, 282146, 306723, 245287, 245292, 349741, 169518, 230959, 286254, 288309, 290358, 235070, 288318, 349763, 124485, 56902, 288326, 288327, 292425, 243274, 128587, 333388, 333393, 224851, 290390, 235095, 300630, 196187, 343647, 374372, 282213, 323178, 54893, 138863, 222832, 314998, 247416, 366203, 323196, 175741, 325245, 337535, 294529, 224901, 282245, 282246, 288392, 229001, 312965, 310923, 188048, 323217, 239250, 282259, 345752, 229020, 255649, 245412, 40613, 40614, 40615, 229029, 282280, 298661, 323236, 61101, 321199, 321207, 296632, 319162, 280251, 327358, 282303, 286399, 218819, 321219, 306890, 280267, 212685, 333517, 333520, 241361, 245457, 302802, 333521, 333523, 280278, 280280, 298712, 18138, 278234, 294622, 321247, 278240, 321249, 12010, 212716, 212717, 280300, 282348, 284401, 282358, 313081, 286459, 325371, 124669, 194303, 278272, 175873, 319233, 323331, 323332, 280329, 284429, 323346, 278291, 294678, 321302, 366360, 116505, 249626, 284442, 325404, 321310, 282400, 241441, 325410, 339745, 341796, 247590, 257830, 317232, 282417, 321337, 282427, 360252, 319292, 325439, 315202, 307011, 325445, 345929, 159562, 341836, 325457, 18262, 370522, 188251, 345951, 362337, 284514, 345955, 296806, 292712, 288619, 325484, 292720, 362352, 313203, 325492, 241528, 194429, 124798, 325503, 182144, 305026, 241540, 253829, 333701, 67463, 243591, 243597, 325518, 282518, 282519, 124824, 214937, 329622, 118685, 298909, 319392, 292771, 354212, 294823, 333735, 284587, 200627, 124852, 243637, 288697, 214977, 163781, 247757, 344013, 212946, 219101, 280541, 292836, 298980, 294886, 337895, 313319, 247785, 253929, 327661, 362480, 325619, 333817, 313339 ]
481af2c209dc411c09847ea43661e1d8ed770a0e
e02ae3356615c931b6945f1b8ea9cdadebfc0cb8
/weatherApp/Extension/UiViewControllerExtension.swift
a518ae632c853881f269e7dc9ea0af6aec21f3c4
[]
no_license
hamzon55/weatherApp
1083bc5254322064572f3f807caab3195dcd24ba
8c665f97f8bd3de93f7908462b618f84412f0c40
refs/heads/master
2020-04-27T08:02:39.719258
2019-03-07T00:00:03
2019-03-07T00:00:03
174,157,263
0
0
null
null
null
null
UTF-8
Swift
false
false
1,511
swift
import Foundation import UIKit func showLoader() { let activity = UIActivityIndicatorView() guard let window = UIApplication.shared.keyWindow else {return} let backgroundAlphaView = UIView(frame: window.bounds) backgroundAlphaView.tag = 789 backgroundAlphaView.backgroundColor = .clear window.addSubview(backgroundAlphaView) backgroundAlphaView.translatesAutoresizingMaskIntoConstraints = false backgroundAlphaView.leadingAnchor.constraint(equalTo: window.leadingAnchor).isActive = true backgroundAlphaView.trailingAnchor.constraint(equalTo: window.trailingAnchor).isActive = true backgroundAlphaView.topAnchor.constraint(equalTo: window.topAnchor).isActive = true backgroundAlphaView.bottomAnchor.constraint(equalTo: window.bottomAnchor).isActive = true backgroundAlphaView.addSubview(activity) activity.translatesAutoresizingMaskIntoConstraints = false activity.centerXAnchor.constraint(equalTo: backgroundAlphaView.centerXAnchor).isActive = true activity.centerYAnchor.constraint(equalTo: backgroundAlphaView.centerYAnchor).isActive = true activity.style = .whiteLarge activity.color = UIColor.black activity.hidesWhenStopped = true activity.isHidden = false activity.startAnimating() } func hideLoader() { DispatchQueue.main.async { guard let window = UIApplication.shared.keyWindow else {return} if let activity = window.viewWithTag(789) { activity.removeFromSuperview() } } }
[ -1 ]
3c2c9bb19644821ffb0738f9eac672e12ff9f302
290bb11be396b74ee01ee4b2d546c235f2c0098c
/MentorPreview/Config.swift
5966ba182f99c84ad62f93918b9391ca89055569
[]
no_license
MentorPreview/MentorPreview-iOS
110261afdc0312bb246e53e46c0d291069126cb2
3254b4b583499237f9b19e4e0ebfaf36cb85ffe3
refs/heads/master
2021-07-19T12:15:51.570885
2017-10-29T14:48:31
2017-10-29T14:48:31
106,305,087
2
0
null
null
null
null
UTF-8
Swift
false
false
292
swift
// // Config.swift // MentorPreview // // Created by ShinokiRyosei on 2017/10/26. // Copyright © 2017年 ShinokiRyosei. All rights reserved. // import UIKit // MARK: - Config final class Config: NSObject { static var baseURL: String = "https://mentor-preview.herokuapp.com/" }
[ -1 ]
523b7029320258aa6562f0056c83879ee2759dcb
8db6297ae790d46b5ff27dc5bda0b0f842fec927
/DHTopView/AppDelegate.swift
50b9bdc309788e540e5ffd6ef54b7f4e45194f2d
[ "MIT" ]
permissive
Demons-Bee/DHTopView
3a85249694194e4af8cc0c2beb3171f2be8d5deb
62b11916d50244279a777856959d116335012354
refs/heads/master
2021-05-27T05:58:19.792707
2014-11-14T04:58:13
2014-11-14T04:58:13
null
0
0
null
null
null
null
UTF-8
Swift
false
false
2,097
swift
// // AppDelegate.swift // DHTopView // // Created by 胡大函 on 14/11/13. // Copyright (c) 2014年 HuDahan_payMoreGainMore. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. } func applicationDidEnterBackground(application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(application: UIApplication) { // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 229388, 294924, 278542, 229391, 327695, 278545, 229394, 278548, 229397, 229399, 229402, 278556, 229405, 352284, 278559, 278564, 229415, 229417, 327722, 237613, 229426, 237618, 229428, 286774, 229432, 286776, 286778, 319544, 204856, 286791, 237640, 278605, 286797, 311375, 196692, 319573, 311383, 278623, 278626, 319590, 311400, 278635, 303212, 278639, 278648, 131192, 237693, 327814, 131209, 417930, 303241, 303244, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 286916, 286922, 286924, 286926, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 278760, 237807, 303345, 286962, 229622, 327930, 278781, 278783, 278785, 237826, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 155966, 278849, 319809, 319810, 319814, 311623, 319818, 311628, 287054, 319822, 278865, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 319879, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 278983, 319945, 278986, 278990, 278994, 311767, 279003, 279006, 188895, 279010, 287202, 279015, 172520, 279020, 279023, 311791, 172529, 279027, 319989, 164343, 180727, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 172550, 287238, 172552, 303623, 320007, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 172618, 303690, 33357, 279124, 172634, 262752, 172644, 311911, 189034, 295533, 189039, 189040, 172655, 172656, 295538, 189044, 172660, 287349, 352880, 287355, 287360, 295553, 287365, 311942, 303751, 295557, 352905, 279178, 287371, 311946, 311951, 287377, 172691, 287381, 311957, 221850, 287386, 164509, 303773, 295583, 172702, 230045, 287394, 287390, 303780, 172705, 287398, 172707, 279208, 287400, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 328381, 279231, 287423, 328384, 287427, 107208, 279241, 172748, 287436, 287440, 295633, 172755, 303827, 279255, 279258, 303835, 213724, 189149, 303838, 287450, 279267, 295654, 279272, 230128, 312048, 312050, 230131, 205564, 303871, 230146, 328453, 295685, 230154, 33548, 312077, 295695, 295701, 369433, 230169, 295707, 328476, 295710, 230175, 303914, 279340, 279353, 230202, 312124, 222018, 295755, 377676, 148302, 287569, 279383, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303985, 328563, 303987, 303991, 303997, 295806, 295808, 304005, 213895, 320391, 304007, 304009, 304011, 304013, 213902, 279438, 295822, 189329, 295825, 304019, 279445, 58262, 279452, 279461, 279462, 304042, 213931, 230327, 304055, 287675, 197564, 304063, 238528, 304065, 189378, 213954, 156612, 312272, 304084, 304090, 320481, 304106, 320490, 312302, 328687, 320496, 304114, 295928, 320505, 295945, 197645, 295949, 230413, 320528, 140312, 295961, 238620, 304164, 304170, 238641, 238652, 238655, 230465, 238658, 336964, 296004, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 296040, 361576, 205931, 296044, 164973, 279661, 205934, 312432, 279669, 337018, 189562, 279679, 279683, 222340, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 238766, 165038, 230576, 238770, 304311, 350308, 230592, 279750, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 320740, 279781, 304360, 279788, 320748, 279790, 304370, 296189, 320771, 312585, 296202, 296205, 230674, 320786, 230677, 296213, 296215, 320792, 230681, 214294, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 222525, 296253, 312639, 296255, 296259, 378181, 230727, 238919, 320840, 296264, 296267, 296271, 222545, 230739, 337244, 222556, 230752, 312676, 230760, 173418, 410987, 230763, 230768, 296305, 312692, 230773, 279929, 304506, 304505, 181626, 181631, 312711, 312712, 296331, 288140, 288144, 230800, 337306, 288160, 173472, 288162, 288164, 279975, 304555, 370092, 279983, 288176, 279985, 312755, 296373, 279991, 312759, 288185, 337335, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 370130, 288210, 288212, 280021, 288214, 222676, 239064, 288217, 288218, 280027, 329177, 288220, 239070, 288224, 370146, 280034, 280036, 288226, 280038, 288229, 288230, 288232, 288234, 288236, 288238, 288240, 291754, 288242, 296435, 288244, 288250, 402942, 148990, 296446, 206336, 296450, 230916, 230919, 370187, 304651, 304653, 230940, 222752, 108066, 296486, 296488, 157229, 230961, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 280152, 288344, 239194, 280158, 403039, 370272, 312938, 280183, 280185, 280188, 280191, 280194, 116354, 280208, 280211, 288408, 280218, 280222, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 313027, 280260, 206536, 280264, 206539, 206541, 206543, 280276, 321239, 280283, 313052, 288478, 313055, 321252, 313066, 280302, 288494, 321266, 419570, 288499, 288502, 280314, 288510, 124671, 67330, 280324, 198405, 288519, 280331, 198416, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 288576, 345921, 280388, 304968, 280393, 280402, 313176, 42842, 280419, 321381, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 124817, 280468, 239510, 280473, 124827, 247709, 214944, 313258, 296883, 124853, 10170, 296890, 288700, 296894, 280515, 190403, 296900, 337862, 165831, 280521, 231379, 296921, 239586, 313320, 231404, 124913, 165876, 321528, 239612, 313340, 288764, 239617, 313347, 288773, 313358, 321560, 305176, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 124980, 288824, 288826, 321595, 378941, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 223327, 280671, 149599, 321634, 149601, 149603, 313451, 223341, 280687, 313458, 280691, 313464, 329850, 321659, 280702, 288895, 321670, 215175, 141455, 141459, 313498, 288936, 100520, 288940, 280755, 288947, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 280819, 157940, 125171, 182517, 280823, 280825, 280827, 280830, 280831, 280833, 280835, 125187, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 280891, 289087, 280897, 280900, 239944, 305480, 280906, 239947, 305485, 305489, 280919, 354653, 313700, 280937, 313705, 190832, 280946, 313720, 280956, 239997, 280959, 313731, 199051, 240011, 289166, 240017, 297363, 190868, 297365, 240021, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 305594, 289210, 281024, 289218, 289221, 289227, 281047, 215526, 166378, 305647, 281075, 174580, 281084, 240124, 305662, 305664, 240129, 305666, 305668, 240132, 223749, 281095, 338440, 150025, 223752, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 199262, 338532, 281190, 199273, 281196, 158317, 313973, 281210, 158347, 133776, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 314029, 314033, 240309, 133817, 314047, 314051, 199364, 297671, 158409, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 281401, 289593, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207737, 183172, 240519, 322440, 338823, 314249, 183184, 289687, 240535, 297883, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 183260, 281567, 289762, 322534, 281581, 183277, 322550, 175134, 322599, 322610, 314421, 281654, 314427, 207937, 314433, 207949, 322642, 314456, 281691, 314461, 281702, 281704, 281708, 281711, 289912, 248995, 306341, 306347, 306354, 142531, 199877, 289991, 306377, 289997, 363742, 363745, 298216, 330988, 216303, 322801, 388350, 363802, 199976, 199978, 314671, 298292, 298294, 216376, 298306, 380226, 224587, 224594, 216404, 306517, 314714, 224603, 159068, 314718, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 290171, 314747, 306555, 290174, 224641, 281987, 298372, 314756, 281990, 224647, 298377, 314763, 224657, 306581, 314779, 314785, 282025, 314793, 282027, 241068, 241070, 241072, 282034, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 282101, 241142, 191992, 290298, 151036, 290302, 290305, 192008, 323084, 282127, 290321, 282130, 282133, 290325, 241175, 290328, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 282186, 224849, 282195, 282201, 306778, 159324, 159330, 314979, 298598, 323176, 224875, 241260, 257658, 315016, 282249, 290445, 324757, 282261, 298651, 282269, 323229, 298655, 323231, 61092, 282277, 282295, 282300, 323260, 323266, 282310, 323273, 282319, 306897, 241362, 282328, 306904, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 282410, 241450, 306988, 306991, 315184, 315190, 241464, 282425, 159545, 298811, 307009, 413506, 307012, 315211, 307027, 315221, 282454, 315223, 241496, 241498, 307035, 307040, 282465, 241509, 110438, 298860, 110445, 282478, 315249, 110450, 315251, 315253, 315255, 339838, 282499, 315267, 315269, 241544, 282505, 241546, 241548, 298896, 298898, 282514, 44948, 298901, 241556, 282520, 241560, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 241581, 241583, 323504, 241586, 282547, 241588, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 241661, 299006, 282623, 315396, 241669, 315397, 282632, 282639, 282645, 241693, 241701, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 307287, 315482, 315483, 217179, 192605, 200801, 299105, 217188, 299109, 307303, 315495, 356457, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 307329, 307338, 233613, 241813, 307352, 299164, 184479, 299167, 184481, 184486, 307370, 307372, 307374, 307376, 323763, 176311, 299191, 307385, 307386, 258235, 176316, 307388, 307390, 184503, 299200, 307394, 307396, 184518, 307399, 323784, 307409, 307411, 299225, 233701, 307432, 282881, 282893, 291089, 282906, 291104, 233766, 282931, 307508, 315701, 307510, 332086, 307512, 307515, 282942, 307518, 282947, 282957, 323917, 110926, 233808, 323921, 315733, 323926, 233815, 315739, 299357, 242018, 242024, 299373, 315757, 250231, 242043, 315771, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 283033, 291226, 242075, 315801, 291231, 283042, 291238, 291241, 127403, 127405, 291247, 127407, 299440, 299444, 127413, 283062, 291254, 127417, 291260, 283069, 127421, 127424, 299457, 127431, 176592, 315856, 315860, 176597, 127447, 283095, 299481, 176605, 242143, 291299, 127463, 242152, 291305, 127466, 176620, 127474, 291314, 291317, 135672, 233979, 291323, 291330, 283142, 127497, 233994, 135689, 233998, 234003, 234006, 152087, 127511, 283161, 242202, 234010, 135707, 242206, 135710, 242208, 291361, 291378, 234038, 152118, 234041, 70213, 242250, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 291456, 135808, 373383, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 135839, 299680, 225954, 299684, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 225998, 299726, 226002, 226005, 119509, 226008, 201444, 299750, 283368, 234219, 283372, 381677, 226037, 283382, 234231, 316151, 234236, 226045, 234239, 242431, 209665, 234242, 299778, 242436, 226053, 234246, 226056, 234248, 291593, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 234269, 283421, 234272, 234274, 152355, 234278, 299814, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 283452, 160572, 234302, 234307, 242499, 234309, 292433, 234313, 316233, 316235, 234316, 283468, 242511, 234319, 234321, 234324, 185173, 201557, 234329, 234333, 308063, 234336, 234338, 242530, 349027, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 177011, 234356, 234358, 234362, 226171, 234364, 291711, 234368, 234370, 201603, 234373, 226182, 234375, 226185, 308105, 234379, 234384, 226193, 234388, 234390, 226200, 324504, 234393, 209818, 308123, 324508, 234398, 234396, 291742, 234401, 291747, 291748, 234405, 291750, 234407, 324518, 324520, 234410, 324522, 226220, 291756, 234414, 324527, 291760, 234417, 201650, 324531, 226230, 234422, 275384, 324536, 234428, 291773, 234431, 242623, 324544, 324546, 226239, 324548, 226245, 234437, 234439, 234434, 234443, 275406, 234446, 234449, 316370, 234452, 234455, 234459, 234461, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 324599, 234487, 234490, 234493, 234496, 316416, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 234519, 316439, 234520, 234523, 234526, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 144430, 234543, 234546, 275508, 234549, 300085, 300088, 234553, 234556, 234558, 316479, 234561, 316483, 234563, 308291, 234568, 234570, 316491, 300108, 234572, 234574, 300115, 234580, 234581, 275545, 242777, 234585, 234590, 234593, 234595, 300133, 234597, 234601, 300139, 234605, 234607, 160879, 275569, 234610, 300148, 234614, 398455, 144506, 275579, 234618, 234620, 234623, 226433, 234627, 275588, 234629, 242822, 234634, 234636, 177293, 234640, 275602, 234643, 226453, 275606, 234647, 275608, 308373, 234650, 234648, 308379, 283805, 234653, 324766, 119967, 234657, 300189, 324768, 242852, 283813, 234661, 300197, 234664, 275626, 234667, 316596, 308414, 234687, 300226, 308418, 226500, 234692, 300229, 308420, 283844, 283850, 300234, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 161003, 300267, 300270, 300272, 120053, 300278, 316663, 275703, 300284, 275710, 300287, 300289, 292097, 300292, 300294, 275719, 300299, 177419, 283917, 300301, 242957, 177424, 275725, 349464, 283939, 259367, 283951, 292143, 300344, 226617, 283963, 243003, 226628, 283973, 300357, 283983, 316758, 357722, 316766, 292192, 316768, 218464, 292197, 316774, 284010, 136562, 324978, 275834, 275836, 275840, 316803, 316806, 316811, 316814, 226703, 300433, 234899, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 284076, 144812, 144814, 144820, 284084, 284087, 292279, 144826, 144828, 144830, 144832, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 226787, 218597, 292329, 300523, 259565, 300527, 259567, 308720, 226802, 316917, 308727, 292343, 300537, 316947, 308757, 284191, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 284213, 284215, 194103, 284218, 226877, 284223, 284226, 243268, 292421, 226886, 284231, 128584, 284228, 284234, 276043, 317004, 366155, 284238, 226895, 276048, 284241, 194130, 284243, 276052, 276053, 284245, 284247, 317015, 284249, 243290, 284251, 300628, 284253, 235097, 284255, 300638, 284258, 292452, 292454, 284263, 284265, 292458, 284267, 292461, 284272, 284274, 276086, 284278, 292470, 292473, 276090, 284283, 276093, 284286, 276095, 284288, 292481, 276098, 284290, 325250, 284292, 292479, 276103, 292485, 284297, 317066, 284299, 317068, 276109, 284301, 284303, 276114, 284306, 284308, 284312, 284314, 276122, 284316, 276127, 284320, 284322, 284327, 276137, 284329, 284331, 317098, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 276160, 358080, 284354, 358083, 276166, 284358, 358089, 276170, 284362, 276175, 284368, 276177, 284370, 317138, 284372, 358098, 284377, 276187, 284379, 284381, 284384, 284386, 358114, 358116, 276197, 317158, 358119, 284392, 325353, 284394, 358122, 284397, 276206, 284399, 358126, 358128, 358133, 358135, 276216, 358140, 284413, 358142, 284418, 358146, 317187, 317189, 317191, 284428, 300816, 300819, 317207, 284440, 186139, 300828, 300830, 276255, 325408, 284449, 300834, 300832, 227109, 317221, 358183, 276268, 300845, 243504, 284469, 276280, 325436, 276291, 366406, 276295, 153417, 276308, 284502, 317271, 276315, 292700, 284511, 227175, 292715, 300912, 284529, 292721, 300915, 292729, 317306, 284540, 292734, 325512, 276365, 284564, 358292, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 284585, 317353, 276395, 292784, 276402, 358326, 161718, 276410, 276411, 358330, 276418, 301009, 301011, 301013, 292823, 301015, 301017, 358360, 292828, 276446, 153568, 276448, 276452, 276455, 292839, 292843, 276460, 276464, 178161, 227314, 276466, 276472, 317435, 276476, 276479, 276482, 276485, 317446, 276490, 292876, 276496, 317456, 317458, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 243762, 309298, 325685, 325689, 276539, 235579, 235581, 325692, 178238, 276544, 284739, 292934, 276553, 243785, 350293, 350295, 194649, 227418, 309337, 350302, 227423, 194654, 194657, 178273, 276579, 227426, 194660, 227430, 276583, 309346, 309348, 276586, 309350, 309352, 309354, 276590, 350313, 350316, 350321, 284786, 276595, 227440, 301167, 350325, 350328, 292985, 301178, 292989, 292993, 301185, 350339, 317570, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 276638, 350366, 284837, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 309450, 301258, 276685, 276689, 309462, 301272, 309468, 309471, 301283, 317672, 276713, 317674, 325867, 227571, 309491, 309494, 243960, 276735, 227583, 227587, 276739, 276742, 227593, 227596, 325910, 309530, 342298, 211232, 317729, 276775, 325937, 276789, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 235858, 276829, 276833, 391523, 276836, 276843, 293227, 276848, 293232, 186744, 211324, 227709, 285061, 317833, 178572, 285070, 285077, 227738, 317853, 276896, 317858, 342434, 285093, 317864, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 317951, 309764, 301575, 121352, 236043, 342541, 113167, 277011, 317971, 309781, 309779, 227877, 227879, 293417, 227882, 309804, 293421, 105007, 236082, 277054, 129603, 318020, 301636, 301639, 301643, 277071, 285265, 399955, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 277106, 121458, 170619, 309885, 309888, 277122, 227975, 277128, 285320, 301706, 318092, 326285, 318094, 334476, 277136, 277139, 227992, 285340, 318108, 227998, 318110, 137889, 383658, 285357, 318128, 277170, 342707, 154292, 277173, 293555, 318132, 285368, 277177, 277181, 277187, 277191, 277194, 277196, 277201, 137946, 113378, 228069, 277223, 342760, 285417, 56043, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 285453, 228113, 285459, 277273, 293659, 326430, 228128, 285474, 293666, 228135, 318248, 277291, 293677, 318253, 285489, 293685, 285494, 301880, 301884, 310080, 293696, 277314, 277317, 277322, 301911, 277337, 301913, 301921, 400236, 236397, 162671, 310134, 277368, 15224, 236408, 416639, 416640, 113538, 416648, 277385, 39817, 187274, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 293811, 293820, 203715, 293849, 293861, 228327, 228328, 228330, 318442, 228332, 277486, 326638, 318450, 293876, 293877, 285686, 302073, 285690, 121850, 302075, 244731, 293882, 293887, 277504, 277507, 138246, 277511, 277519, 293908, 293917, 293939, 277561, 277564, 310336, 293956, 277573, 228422, 310344, 277577, 293960, 277583, 203857, 310355, 293971, 310359, 236632, 277594, 138332, 277598, 285792, 277601, 203872, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 285817, 367737, 285821, 302205, 285824, 392326, 285831, 253064, 302218, 285835, 384148, 162964, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 302241, 277671, 302248, 64682, 277678, 228526, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 204023, 228601, 228606, 64768, 310531, 285958, 228617, 138505, 318742, 277798, 130345, 113964, 285997, 285999, 113969, 318773, 318776, 286010, 417086, 286016, 294211, 302403, 384328, 294221, 326991, 294223, 179547, 146784, 302436, 294246, 327015, 310632, 327017, 351594, 351607, 310648, 310651, 310657, 351619, 294276, 310659, 327046, 253320, 310665, 318858, 310672, 351633, 310689, 130468, 228776, 277932, 310703, 310710, 130486, 310712, 310715, 302526, 228799, 64966, 245191, 163272, 302534, 310727, 302541, 302543, 310737, 228825, 163290, 310749, 310755, 187880, 286188, 310764, 310772, 212472, 40443, 286203, 228864, 40448, 286214, 228871, 302603, 65038, 302614, 286233, 302617, 302621, 146977, 187939, 294435, 286246, 294439, 294440, 278057, 294443, 294445, 310831, 40499, 212538, 40507, 228933, 286283, 40525, 228944, 212560, 400976, 147032, 40537, 40539, 278109, 40550, 286312, 286313, 40554, 310892, 40557, 294521, 343679, 310925, 286354, 278163, 122517, 278168, 327333, 229030, 278188, 278192, 319153, 278196, 302781, 319171, 302789, 294599, 278216, 294601, 302793, 343757, 212690, 278227, 229076, 286420, 319187, 286425, 319194, 278235, 229086, 278238, 286432, 294625, 294634, 302838, 319226, 286460, 278274, 302852, 278277, 302854, 294664, 311048, 352008, 319243, 311053, 302862, 294682, 278306, 188199, 294701, 278320, 319280, 319290, 229192, 302925, 188247, 188252, 237409, 294776, 294785, 327554, 40851, 294811, 319390, 237470, 294817, 319394, 40865, 311209, 180142, 294831, 188340, 40886, 294844, 294847, 393177, 294876, 294879, 294883, 311279, 278513, 237555, 278516, 311283, 278519, 237562 ]
cb2df48d7784edf61e7934c1c0111f721958dcc2
127e9dd1a6b736b396f945b5c9a5ba8c3a098753
/revolut-test/revolut-testTests/ProviderMock.swift
47c21c505b48bc3baf2292d0697bb4a05cf51a29
[]
no_license
fredybp/revolut-test
b2f185f664a395e86ac0a8171129d5081ce37712
27da3a581361eba92028677b44809c984e6db9ea
refs/heads/master
2020-04-21T10:48:46.209001
2019-02-16T02:38:20
2019-02-16T02:38:20
169,498,065
0
0
null
null
null
null
UTF-8
Swift
false
false
706
swift
// // ProviderMock.swift // revolut-testTests // // Created by Frederico Bechara De Paola on 14/02/19. // Copyright © 2019 Frederico Bechara De Paola. All rights reserved. // import Foundation @testable import revolut class ProviderMock: ProviderAPI { func request(urlString: String, completion: @escaping (Result<Data, APIError>) -> Void) { if let path = Bundle.main.path(forResource: urlString, ofType: "json") { do { let data = try Data(contentsOf: URL(fileURLWithPath: path), options: .mappedIfSafe) completion(.success(data)) } catch { completion(.failure(APIError.wrongMock)) } } } }
[ -1 ]
a57d96a2a108fbb1cb4142fce0285e16e4c27263
192e6b84061b37ae9e62033229ef503ff006ef01
/MyProject1/AppDelegate.swift
037f279f3173988a5ce0991f2eac91a1b751dd9e
[]
no_license
lllKishlll/custom-buddy
56f3aeabd4b6b7e902d0249abd25f7a67766e3ba
923ba5b68b8d900f25589bca49d68b03c1b6282c
refs/heads/master
2020-06-23T16:40:39.588497
2019-06-26T16:23:49
2019-06-26T16:23:49
198,682,870
0
0
null
null
null
null
UTF-8
Swift
false
false
2,172
swift
// // AppDelegate.swift // MyProject1 // // Created by 貴島健斗 on 2019/06/27. // Copyright © 2019 Kish. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 294924, 229388, 278542, 229391, 327695, 229394, 278548, 229397, 229399, 229402, 352284, 229405, 278556, 278559, 229408, 278564, 294950, 229415, 229417, 327722, 237613, 229422, 360496, 229426, 237618, 229428, 311349, 286774, 286776, 319544, 286778, 229432, 204856, 352318, 286791, 237640, 286797, 278605, 311375, 163920, 237646, 196692, 319573, 311383, 278623, 278626, 319590, 311400, 278635, 303212, 278639, 131192, 278648, 237693, 303230, 327814, 303241, 131209, 417930, 303244, 311436, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 237807, 303345, 286962, 303347, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 295220, 287032, 155966, 319809, 319810, 278849, 319814, 311623, 319818, 311628, 229709, 319822, 287054, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 319879, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 287202, 279010, 279015, 172520, 319978, 279020, 172526, 311791, 279023, 172529, 279027, 319989, 172534, 180727, 164343, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 172550, 303623, 172552, 287238, 320007, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 213575, 172618, 303690, 33357, 287309, 303696, 279124, 172634, 262752, 254563, 172644, 311911, 189034, 295533, 172655, 172656, 352880, 295538, 189039, 172660, 287349, 189040, 189044, 287355, 287360, 295553, 172675, 295557, 287365, 311942, 303751, 352905, 279178, 287371, 311946, 311951, 287377, 172691, 287381, 311957, 221850, 287386, 230045, 172702, 164509, 303773, 172705, 287394, 172707, 303780, 287390, 287398, 205479, 279208, 287400, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 287423, 328384, 172737, 279231, 287427, 312005, 312006, 107208, 172748, 287436, 107212, 172751, 287440, 295633, 172755, 303827, 279255, 172760, 287450, 303835, 279258, 189149, 303838, 213724, 312035, 279267, 295654, 279272, 230128, 312048, 312050, 230131, 189169, 205564, 303871, 230146, 328453, 295685, 230154, 33548, 312077, 295695, 295701, 230169, 369433, 295707, 328476, 295710, 230175, 295720, 303914, 279340, 205613, 279353, 230202, 312124, 328508, 222018, 295755, 377676, 148302, 287569, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303981, 303985, 328563, 303987, 279413, 303991, 303997, 295806, 295808, 295813, 304005, 320391, 213895, 304007, 304009, 304011, 230284, 304013, 295822, 279438, 213902, 189329, 295825, 304019, 189331, 58262, 304023, 304027, 279452, 410526, 279461, 279462, 304042, 213931, 230327, 304055, 287675, 197564, 230334, 304063, 238528, 304065, 213954, 189378, 156612, 295873, 213963, 197580, 312272, 304084, 304090, 320481, 304106, 320490, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 230413, 295949, 197645, 320528, 140312, 295961, 238620, 197663, 304164, 304170, 304175, 238641, 312374, 238652, 238655, 230465, 238658, 336964, 296004, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 296040, 361576, 205931, 296044, 279661, 205934, 164973, 312432, 279669, 337018, 189562, 279679, 304258, 279683, 222340, 66690, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 238766, 165038, 230576, 238770, 304311, 230592, 312518, 279750, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 320740, 279781, 304360, 320748, 279788, 279790, 304370, 296189, 320771, 312585, 296202, 296205, 230674, 320786, 230677, 296213, 296215, 320792, 230681, 214294, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 296253, 222525, 296255, 312639, 230718, 296259, 378181, 296262, 230727, 238919, 296264, 320840, 296267, 296271, 222545, 230739, 312663, 222556, 337244, 230752, 312676, 230760, 173418, 148843, 410987, 230763, 230768, 296305, 312692, 230773, 304505, 304506, 279929, 181626, 181631, 148865, 312711, 312712, 296331, 288140, 288144, 230800, 304533, 337306, 288154, 288160, 173472, 288162, 288164, 279975, 304555, 370092, 279983, 173488, 288176, 279985, 312755, 296373, 312759, 279991, 288185, 337335, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 288210, 370130, 222676, 288212, 148946, 288214, 239064, 288217, 329177, 280027, 288220, 288218, 239070, 288224, 280034, 288226, 280036, 288229, 280038, 288230, 288232, 370146, 288234, 320998, 288236, 288238, 288240, 288242, 296435, 288244, 288250, 296446, 321022, 402942, 148990, 296450, 206336, 230916, 230919, 214535, 230923, 304651, 304653, 370187, 230940, 222752, 108066, 296486, 296488, 157229, 230961, 157236, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 288344, 280152, 239194, 280158, 403039, 370272, 181854, 239202, 312938, 280183, 280185, 280188, 280191, 116354, 280194, 280208, 280211, 288408, 280218, 280222, 419489, 190118, 198310, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 419522, 313027, 280260, 419525, 206536, 280264, 206539, 206541, 206543, 263888, 313044, 280276, 321239, 280283, 313052, 18140, 288478, 313055, 419555, 321252, 313066, 288494, 280302, 280304, 313073, 321266, 288499, 419570, 288502, 280314, 288510, 124671, 67330, 280324, 198405, 288519, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 280388, 304968, 280393, 280402, 173907, 313171, 313176, 42842, 280419, 321381, 296809, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 214944, 280487, 313258, 321458, 296883, 124853, 214966, 296890, 10170, 288700, 296894, 190403, 296900, 280515, 337862, 165831, 280521, 231379, 296921, 354265, 354270, 239586, 313320, 354281, 231404, 124913, 165876, 321528, 239612, 313340, 288764, 239617, 313347, 288773, 313358, 305176, 321560, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 321595, 378941, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 149599, 280671, 149601, 321634, 149603, 223327, 329830, 280681, 313451, 223341, 280687, 149618, 215154, 313458, 280691, 313464, 329850, 321659, 280702, 288895, 321670, 215175, 141446, 141455, 141459, 280725, 313498, 100520, 288936, 280747, 288940, 288947, 280755, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 125171, 157940, 280819, 182517, 280823, 280825, 280827, 280830, 280831, 280833, 125187, 280835, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 305464, 280888, 280891, 289087, 108865, 280897, 280900, 305480, 239944, 280906, 239947, 305485, 305489, 379218, 280919, 248153, 354653, 354656, 313700, 280937, 313705, 190832, 280946, 223606, 313720, 280956, 239997, 280959, 313731, 199051, 240011, 289166, 240017, 297363, 190868, 240021, 297365, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 289210, 305594, 281024, 289218, 289221, 289227, 281045, 281047, 215526, 166378, 305647, 281075, 174580, 240124, 281084, 305662, 305664, 240129, 305666, 305668, 223749, 240132, 281095, 223752, 150025, 338440, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 289317, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 338528, 338532, 281190, 199273, 281196, 19053, 158317, 313973, 297594, 281210, 158347, 264845, 133776, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 297671, 158409, 256716, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 289593, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 158596, 183172, 240519, 322440, 314249, 338823, 183184, 289687, 240535, 297883, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 183260, 281567, 289762, 322534, 297961, 183277, 281581, 322550, 134142, 322563, 314372, 330764, 175134, 322599, 322610, 314421, 281654, 314427, 314433, 207937, 314441, 207949, 322642, 314456, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 289912, 248995, 306341, 306344, 306347, 322734, 306354, 142531, 199877, 289991, 306377, 289997, 249045, 363742, 363745, 298216, 330988, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 380226, 298306, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 290171, 314747, 306555, 290174, 298365, 224641, 281987, 298372, 314756, 281990, 224647, 265604, 298377, 314763, 142733, 298381, 314768, 224657, 306581, 314773, 314779, 314785, 314793, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 191992, 290298, 151036, 290302, 282111, 290305, 175621, 306694, 192008, 323084, 257550, 282127, 290321, 282130, 323090, 290325, 282133, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 323176, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 324757, 282261, 175770, 298651, 282269, 323229, 298655, 323231, 61092, 282277, 306856, 282295, 282300, 323260, 323266, 282310, 323273, 282319, 306897, 241362, 306904, 282328, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 241450, 282410, 306988, 306991, 315184, 323376, 315190, 241464, 159545, 282425, 298811, 118593, 307009, 413506, 307012, 241475, 298822, 315211, 282446, 307027, 315221, 323414, 315223, 241496, 241498, 307035, 307040, 110433, 282465, 241509, 110438, 298860, 110445, 282478, 315249, 110450, 315251, 282481, 315253, 315255, 339838, 315267, 282499, 315269, 241544, 282505, 241546, 241548, 298896, 298898, 282514, 241556, 44948, 298901, 241560, 282520, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 36779, 241581, 282542, 241583, 323504, 241586, 290739, 241588, 282547, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 299003, 241661, 299006, 282623, 315396, 241669, 315397, 282632, 307211, 282639, 290835, 282645, 241693, 282654, 241701, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 307290, 217179, 315482, 192605, 315483, 233567, 299105, 200801, 217188, 299109, 307303, 315495, 356457, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 315524, 307338, 233613, 241813, 307352, 299164, 241821, 299167, 315552, 184479, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 299185, 323763, 184503, 299191, 176311, 307385, 307386, 307388, 258235, 307390, 176316, 299200, 184512, 307394, 299204, 307396, 184518, 307399, 323784, 233679, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 184586, 282893, 323854, 291089, 282906, 291104, 233766, 299304, 295583, 176435, 307508, 315701, 332086, 307510, 307512, 168245, 307515, 307518, 282942, 282947, 323917, 110926, 282957, 233808, 323921, 315733, 323926, 233815, 315739, 323932, 299357, 242018, 242024, 299373, 315757, 250231, 242043, 315771, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 315801, 291226, 242075, 283033, 194654, 61855, 291231, 283042, 291238, 291241, 127403, 127405, 291247, 299440, 127407, 299444, 127413, 291254, 283062, 127417, 291260, 127421, 283069, 127424, 299457, 127429, 127431, 127434, 315856, 127440, 176592, 315860, 176597, 127447, 283095, 299481, 127449, 176605, 242143, 127455, 127457, 291299, 127463, 242152, 291305, 127466, 176620, 127469, 127474, 291314, 291317, 127480, 135672, 291323, 233979, 127485, 291330, 127490, 127494, 283142, 127497, 233994, 135689, 127500, 291341, 233998, 127506, 234003, 127509, 234006, 127511, 152087, 283161, 242202, 234010, 135707, 242206, 135710, 242208, 291361, 242220, 291378, 234038, 152118, 234041, 315961, 70213, 242250, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 291456, 135808, 373383, 299655, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 299684, 135844, 242343, 209576, 242345, 373421, 299706, 135870, 135873, 135876, 135879, 299720, 299723, 299726, 225998, 226002, 119509, 226005, 226008, 299740, 242396, 201444, 299750, 283368, 234219, 283372, 226037, 283382, 316151, 234231, 234236, 226045, 242431, 234239, 209665, 234242, 299778, 242436, 226053, 234246, 226056, 291593, 234248, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 234269, 283421, 234272, 234274, 152355, 299814, 234278, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 160572, 283452, 234302, 234307, 242499, 234309, 292433, 316233, 234313, 316235, 234316, 283468, 234319, 242511, 234321, 234324, 185173, 201557, 234329, 234333, 308063, 234336, 242530, 349027, 234338, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 177011, 234356, 234358, 234362, 226171, 234364, 291711, 234368, 291714, 234370, 291716, 234373, 201603, 226182, 234375, 308105, 226185, 234379, 324490, 234384, 234388, 234390, 324504, 234393, 209818, 308123, 234396, 324508, 291742, 226200, 234398, 234401, 291747, 291748, 234405, 291750, 234407, 324520, 324518, 324522, 234410, 291756, 226220, 291754, 324527, 291760, 234417, 201650, 324531, 234414, 234422, 226230, 275384, 324536, 234428, 291773, 242623, 324544, 234431, 234434, 324546, 324548, 226245, 234437, 234439, 226239, 234443, 291788, 234446, 275406, 193486, 234449, 316370, 193488, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 234487, 324599, 234490, 234493, 316416, 234496, 308226, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 316439, 234520, 234519, 234523, 234526, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 144430, 234543, 234546, 275508, 300085, 234549, 300088, 234553, 234556, 234558, 316479, 234561, 316483, 160835, 234563, 308291, 234568, 234570, 316491, 234572, 300108, 234574, 300115, 234580, 234581, 242777, 234585, 275545, 234590, 234593, 234595, 234597, 300133, 234601, 300139, 234605, 160879, 234607, 275569, 234610, 316530, 300148, 234614, 398455, 144506, 234618, 234620, 275579, 234623, 226433, 234627, 275588, 234629, 242822, 234634, 234636, 177293, 234640, 275602, 234643, 308373, 226453, 234647, 234648, 275606, 234650, 275608, 308379, 300189, 324766, 119967, 234653, 324768, 283805, 234657, 242852, 300197, 234661, 283813, 234664, 177318, 275626, 234667, 316596, 308414, 234687, 300223, 300226, 308418, 234692, 300229, 308420, 308422, 226500, 283844, 300234, 283850, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 300267, 161003, 300270, 300272, 120053, 300278, 275703, 316663, 300284, 275710, 300287, 292097, 300289, 161027, 300292, 300294, 275719, 234760, 177419, 300299, 242957, 300301, 283917, 177424, 275725, 349451, 349464, 415009, 283939, 259367, 292143, 283951, 300344, 226617, 243003, 283963, 226628, 300357, 283973, 177482, 283983, 316758, 357722, 316766, 292192, 316768, 218464, 292197, 316774, 243046, 218473, 284010, 136562, 324978, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 316811, 226699, 316814, 226703, 300433, 234899, 300436, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 144812, 284076, 144814, 144820, 374196, 284084, 292279, 284087, 144826, 144828, 144830, 144832, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 226787, 218597, 292329, 300523, 259565, 300527, 308720, 259567, 292338, 226802, 227440, 316917, 308727, 292343, 300537, 316933, 316947, 308757, 308762, 284191, 316959, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 194101, 284213, 316983, 194103, 284215, 308790, 284218, 226877, 292414, 284223, 284226, 284228, 292421, 226886, 284231, 128584, 243268, 284234, 276043, 317004, 366155, 284238, 226895, 284241, 194130, 284243, 300628, 284245, 276053, 284247, 317015, 284249, 243290, 284251, 276052, 284253, 300638, 284255, 235097, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 284278, 292470, 276086, 292473, 284283, 276093, 284286, 292479, 284288, 292481, 284290, 325250, 284292, 292485, 325251, 276095, 276098, 284297, 317066, 284299, 317068, 284301, 276109, 284303, 284306, 276114, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 284329, 317098, 284331, 276137, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 276160, 358080, 284354, 358083, 284358, 276166, 358089, 284362, 276170, 284365, 276175, 284368, 276177, 284370, 358098, 284372, 317138, 284377, 276187, 284379, 284381, 284384, 358114, 284386, 358116, 276197, 317158, 358119, 284392, 325353, 358122, 284394, 284397, 358126, 284399, 358128, 276206, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 358146, 317187, 284418, 317189, 317191, 284428, 300816, 300819, 317207, 284440, 300828, 300830, 276255, 300832, 325408, 300834, 317221, 227109, 358183, 186151, 276268, 300845, 243504, 300850, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 292681, 153417, 358224, 284499, 276308, 178006, 317271, 284502, 276315, 292700, 317279, 284511, 227175, 292715, 300912, 292721, 284529, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 276365, 317332, 358292, 284564, 284566, 399252, 350106, 284572, 276386, 284579, 276388, 358312, 317353, 292776, 284585, 276395, 292784, 276402, 358326, 161718, 358330, 276410, 276411, 276418, 276425, 301009, 301011, 301013, 292823, 358360, 301017, 301015, 292828, 276446, 153568, 276448, 276452, 292839, 276455, 292843, 276460, 292845, 276464, 178161, 227314, 276466, 325624, 276472, 317435, 276476, 276479, 276482, 276485, 317446, 276490, 350218, 292876, 350222, 317456, 276496, 317458, 178195, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 243762, 309298, 325685, 325689, 235579, 325692, 235581, 178238, 276539, 276544, 284739, 325700, 243779, 292934, 243785, 276553, 350293, 350295, 309337, 194649, 227418, 350299, 350302, 227423, 350304, 178273, 309346, 194657, 194660, 350308, 309350, 309348, 292968, 309352, 227426, 276579, 227430, 276583, 309354, 301167, 276590, 350321, 350313, 350316, 284786, 350325, 252022, 276595, 350328, 292985, 301178, 350332, 292989, 301185, 292993, 350339, 317570, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 350366, 276638, 284837, 153765, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 301258, 309450, 276685, 309455, 276689, 309462, 301272, 276699, 194780, 309468, 309471, 301283, 317672, 317674, 325867, 243948, 194801, 309491, 227571, 309494, 243960, 276735, 227583, 227587, 276739, 211204, 276742, 227593, 227596, 325910, 309530, 342298, 211232, 317729, 276775, 211241, 325937, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 293227, 276843, 293232, 276848, 186744, 211324, 227709, 285061, 366983, 317833, 178572, 285070, 285077, 178583, 227738, 317853, 276896, 317858, 342434, 285093, 317864, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 293370, 317951, 309764, 301575, 121352, 293387, 236043, 342541, 317963, 113167, 55822, 309779, 317971, 309781, 277011, 55837, 227877, 227879, 293417, 227882, 309804, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 219714, 129603, 301636, 318020, 301639, 301643, 277071, 285265, 399955, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 309871, 121458, 277106, 170618, 170619, 309885, 309888, 277122, 227975, 277128, 285320, 301706, 318092, 326285, 334476, 318094, 277136, 277139, 227992, 318108, 285340, 318110, 227998, 137889, 383658, 285357, 318128, 277170, 293555, 342707, 154292, 318132, 277173, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 342745, 137946, 342747, 342749, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 285474, 293666, 228135, 318248, 277291, 318253, 293677, 285489, 301876, 293685, 285494, 301880, 285499, 301884, 293696, 310080, 277317, 277322, 293706, 277329, 162643, 310100, 301911, 301913, 277337, 301921, 400236, 236397, 162671, 326514, 310134, 236408, 15224, 277368, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 293811, 293817, 293820, 203715, 326603, 342994, 276586, 293849, 293861, 228327, 228328, 318442, 228330, 228332, 326638, 277486, 351217, 318450, 293876, 293877, 285686, 302073, 121850, 293882, 302075, 244731, 285690, 293887, 277504, 277507, 277511, 293899, 277519, 293908, 302105, 293917, 293939, 318516, 277561, 277564, 310336, 7232, 293956, 277573, 228422, 293960, 310344, 277577, 277583, 203857, 293971, 310355, 310359, 236632, 277594, 138332, 277598, 203872, 277601, 285792, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 367737, 285817, 302205, 285821, 392326, 285831, 253064, 294026, 302218, 285835, 162964, 384148, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 302241, 285862, 277671, 302248, 64682, 277678, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 310486, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 285958, 138505, 228617, 318742, 204067, 277798, 130345, 277801, 113964, 285997, 277804, 285999, 277807, 113969, 277811, 318773, 318776, 277816, 286010, 277819, 294204, 417086, 277822, 286016, 302403, 294211, 384328, 277832, 277836, 294221, 294223, 326991, 277839, 277842, 277847, 277850, 179547, 277853, 146784, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 351619, 294276, 310659, 327046, 277892, 253320, 310665, 318858, 277894, 277898, 277903, 310672, 351633, 277905, 277908, 277917, 310689, 277921, 130468, 228776, 277928, 277932, 310703, 277937, 310710, 130486, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 302534, 310727, 64966, 245191, 163272, 277959, 277963, 302541, 277966, 302543, 310737, 277971, 228825, 163290, 277978, 310749, 277981, 277984, 310755, 277989, 277991, 187880, 277995, 310764, 286188, 278000, 228851, 310772, 278003, 278006, 40440, 212472, 278009, 40443, 286203, 40448, 228864, 286214, 228871, 302603, 65038, 302614, 286233, 302617, 302621, 286240, 146977, 187939, 40484, 294435, 40486, 286246, 294440, 40488, 294439, 294443, 40491, 294445, 278057, 310831, 245288, 286248, 40499, 40502, 212538, 40507, 40511, 40513, 228933, 327240, 40521, 286283, 40525, 40527, 212560, 400976, 228944, 40533, 147032, 40537, 40539, 40541, 278109, 40544, 40548, 40550, 40552, 286313, 40554, 286312, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 294537, 310925, 286354, 278163, 302740, 122517, 278168, 179870, 327333, 229030, 212648, 278188, 302764, 278192, 319153, 278196, 302781, 319171, 302789, 294599, 278216, 294601, 302793, 343757, 212690, 319187, 278227, 286420, 229076, 286425, 319194, 278235, 301163, 278238, 229086, 286432, 294625, 294634, 302838, 319226, 286460, 278274, 302852, 278277, 302854, 294664, 311048, 352008, 319243, 311053, 302862, 319251, 294682, 278306, 188199, 294701, 278320, 319280, 319290, 229192, 302925, 188247, 280021, 188252, 237409, 294776, 360317, 294785, 327554, 360322, 40840, 40851, 294803, 188312, 294811, 237470, 319390, 40865, 319394, 294817, 294821, 311209, 180142, 343983, 294831, 188340, 40886, 319419, 294844, 294847, 393177, 294876, 294879, 294883, 393190, 294890, 311279, 278513, 237555, 278516, 311283, 278519, 237562 ]
b77e1c46903181441e57ea3a4403f8c19bcade5d
053d01c79cb6bd376e9981685dc069dfbcb9962f
/XYZPathKit/Source/XYZPath_JudgeFileType.swift
31c8cb83db63ed077ea67f4ed81b903af942332f
[ "MIT" ]
permissive
brandy2015/XYZPathKit
d980cecc9eec1152ed6fcdecf24730a040115ebf
40d38548063a8f214ce97c7193b60780ac95fd1c
refs/heads/master
2022-11-08T18:08:28.055320
2022-10-29T10:58:48
2022-10-29T10:58:48
253,750,093
1
0
null
null
null
null
UTF-8
Swift
false
false
2,760
swift
// // XYZPath_JudgeFileType.swift // XYZPathKit // // Created by 张子豪 on 2020/4/22. // Copyright © 2020 张子豪. All rights reserved. // // // XYZPath_JudgeFileType.swift // XYZPathKit // // Created by 张子豪 on 2020/4/22. // Copyright © 2020 张子豪. All rights reserved. // import UIKit public extension Path{ func containExtension(FilePath:Path,FileExs:[String]) -> Bool { return FileExs.contains(FilePath.pathExtension.uppercased()) } var isMusic:Bool{ return containExtension(FilePath: self, FileExs: ["MP3","FLAC","M4A","WAV","M4R"]) } var isVideo:Bool{ return containExtension(FilePath: self, FileExs: ["MOV","MP4","AVI","WMV","MPG","M4V","MPG","RMVB","MKV","FLV","3GP"]) } var isPic:Bool{ return containExtension(FilePath: self, FileExs: ["PNG","JPG","JPEG","HEIC","GIF","BMP"]) } var isPDF:Bool{ return containExtension(FilePath: self, FileExs: ["PDF"]) } var isZip:Bool{ return containExtension(FilePath: self, FileExs: ["ZIP","RAR"]) } var isLMR:Bool{ return containExtension(FilePath: self, FileExs: ["LMR"]) } var isOffice:Bool{ return containExtension(FilePath: self, FileExs: [ "WPS", "DOC" ,"XLS" ,"PPT" ,"DOCX" ,"XLSX" ,"PPTX" ,"TXT","KEY","PAGES","numbers".uppercased() ]) } var XYZFileType:XYZFileTypeEnum{ if self.isDirectory { return .Directory} if isMusic {return .Music} if isVideo {return .Video} if isPic {return .Photo} if isPDF {return .PDF} if isZip {return .Compression} if isLMR {return .LMR} if isOffice {return .Office} return .unknowntype } func ReturnMusicTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isMusic} } func ReturnVideoTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isVideo} } func ReturnPicTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isPic} } func ReturnPDFTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isPDF} } func ReturnZipTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isZip} } func ReturnLMRTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isLMR} } func ReturnOfficeTextPath(searchDepth:Int = 1) -> [Path] { return self.find(searchDepth: searchDepth) { path in path.isOffice} } }
[ -1 ]
4d3224c9621360576c0f52d760d3caf8c02e7586
9713f4af1787f013b5f6e9b3f2925d3fad5973a8
/Replate/Replate/Model/Bearer.swift
74c47d0643869e0109257a49499c58e129ea1edf
[]
no_license
glsmkr/apitest-replate
6d10c1c9d49fe7177d74ec22f908c0579bb2001e
0c6804e6a054b44dfe702563aa08fa31107442d1
refs/heads/master
2020-07-05T19:49:46.858183
2019-08-17T00:07:02
2019-08-17T00:07:02
202,754,506
0
0
null
null
null
null
UTF-8
Swift
false
false
206
swift
// // Bearer.swift // Replate // // Created by Julian A. Fordyce on 8/16/19. // Copyright © 2019 Glas Labs. All rights reserved. // import Foundation struct Bearer: Codable { let token: String }
[ -1 ]
1be95041062b73142417a3de67b619f374473d0a
bdd95fc50165d9ab426defa4313f9c7192e8d96d
/LearningSwift.playground/Pages/Error Handeling.xcplaygroundpage/Contents.swift
c324e522cb62939bbc7bc71f8ab17880ed322e31
[ "MIT" ]
permissive
vmachiel/swift
4b75245d38c2154929a991c9ecff3f5a2d87aa7b
c7ce5008b07b93a03a021d4f6af9b1c7c85186ca
refs/heads/main
2023-03-15T17:41:22.642996
2023-02-18T13:00:54
2023-02-18T13:00:54
86,457,156
0
0
null
null
null
null
UTF-8
Swift
false
false
3,327
swift
// Error handeling is often done by creating an enum that adopts the error protocol enum PrinterError: Error { case outOfPaper case outOfToner case onFire } // Write throw to throw and error and throws to indicate a function can throw one // The code calling the function, should deal with the error if its thrown func send(job: Int, toPrinter printerName: String) throws -> String { if printerName == "Never has toner" { throw PrinterError.outOfToner } return "Job Sent" } // To call code that may throw and error write a do block. Mark the part that can throw // the actual error with try, and what should be done if a error is raised with catch. // You can write several catch statements for different raised errors like a switch // statement do { let printerResponse = try send(job: 1440, toPrinter: "Gutenberg") print(printerResponse) } catch PrinterError.onFire { // Specific code print("This. Printer's on fijaaaahhhh") } catch let printererror as PrinterError { // assing the thrown error to a constant en use it print("Printer Error!: \(printererror)") } catch { // general error handeling. print(error) } // You can use optionals to run a function that throws an error. If it's trown, the result // is nil, otherwise its the returned value: let printerSuccess = try? send(job: 1234, toPrinter: "Snor Printer") let printerFailure = try? send(job: 394, toPrinter: "Never has toner") // And finally, you can write defer to specify code that is run at the end of a function, // regardless if any error is thrown. It's the "finally" in "try, except, finally" // from python var fridgeIsOpen = false let fridgeContents = ["milk", "eggs", "leftovers"] func fridgeContainsFood(_ food: String) -> Bool { fridgeIsOpen = true defer { fridgeIsOpen = false // always closes the door whatever happens! } // Check if the kind of food is in the fridge let result = fridgeContents.contains(food) return result } // Optional trys // Let's say to wanted to see just IF a function returns an error. // Doesn't matter what the error is, just that it trown and error. // Consider the following: enum UserError: Error { case badID, networkFailed, iedereenOntploft } func returnUser(id: Int) throws -> String { print("doing some stuff, but o NO an error for demonstration purposes") throw UserError.networkFailed } // I want to know: does this give an error if let user = try? returnUser(id: 33) { print(user) } // Nothing happes because it DID throw and error so no action taken. // You write it like this if you just want to skip in case of error. // You could also use ?? to provide a default value if an error is thrown let user2 = (try? returnUser(id: 33)) ?? "No one" // the point is: You DONT have to handle the errors, just move on if one is thrown or use default value // Assertions: assert is a function that takes a closure, and a message. The closure // must return a bool. If the bool is false, the message will be printed and app will // crash. Autoclosure so no {} necessary assert(printerSuccess == "Job Sent", "The job wasn't sent! ") // asserts can be left there, the version you submit to app store will NOT execute the // asserts' closure or crash or print message in ANY case.
[ -1 ]
6f1cc947650a8002eca23d1647838984a98c3b5b
ecbb58e12cf918e106a4d9dbbc5741ec18289997
/BOJ/Math/BOJ_11005/BOJ_11005/main.swift
08a66b3b27ce077f02003f9f2fb967ec11c04fe4
[]
no_license
chelwoong/Algorithms-Swift-PS
6e32708c803dc2f1a4b7c8a2b1163c8318ba875e
c59f3d3da69155db1e4aae0294a1e8ff01a451dd
refs/heads/master
2020-04-11T21:26:57.759850
2020-01-29T08:03:36
2020-01-29T08:03:36
162,105,944
1
0
null
null
null
null
UTF-8
Swift
false
false
1,135
swift
// // main.swift // BOJ_11005 // // Created by woong on 07/02/2019. // Copyright © 2019 woong. All rights reserved. // //import Foundation // 진법 변환 2 if let input = readLine()?.split(separator: " ").map({Int($0) ?? 0}) { let alpa = Array("ABCDEFGHIJKLMNOPQRSTUVWXYZ") var value = input[0] var reminders: [Int] = [] let punctuation = input[1] while value != 0 { reminders.append(value % punctuation) value /= punctuation } for i in reminders.reversed() { if i >= 10 { print(alpa[i-10], terminator: "") } else { print(i, terminator: "") } } } // 다른 풀이 // 재귀 활용 //func solve(_ n: Int, _ b: Int) { // if n == 0 { // return // } // solve(n / b, b) // let temp = n % b // if temp >= 10 { // let transition = Character(UnicodeScalar(temp + 55)!) // print(transition, terminator: "") // } else { // print(temp, terminator: "") // } //} // //let input = readLine()!.split(separator: " ").map { Int($0)! } //solve(input.first!, input.last!) //print()
[ -1 ]
b4c0e9b6479909155b4950c7bbb437b12d67a114
c5b09d51a359f45ca327b0f9f5ce30883c7f35a1
/Swifter/HttpParser.swift
2b735df0a17bb12bf4b0e806cd1708a8aedab190
[ "BSD-3-Clause" ]
permissive
swift-experiments/swifter
89a00be69bb20dff3a9217f0bee1e5e6289112f2
a7a6deb2ff2881bb42765748a5c00a2918657d95
refs/heads/master
2020-12-29T03:19:49.821729
2014-06-09T17:10:12
2014-06-09T17:10:12
null
0
0
null
null
null
null
UTF-8
Swift
false
false
2,042
swift
// // HttpParser.swift // // Created by Damian Kolakowski on 05/06/14. // Copyright (c) 2014 Damian Kołakowski. All rights reserved. // import Foundation /* HTTP stream parser */ class HttpParser { func parseHttpHeader(socket: CInt) -> (String, Dictionary<String, String>)? { if let statusLine = parseLine(socket) { let statusTokens = split(statusLine, { $0 == " " }) if ( statusTokens.count >= 3 ) { let path = statusTokens[1] if let headers = parseHeaders(socket) { return (path, headers) } } } return nil } func parseHeaders(socket: CInt) -> Dictionary<String, String>? { var headers = Dictionary<String, String>() while let headerLine = parseLine(socket) { if ( headerLine.isEmpty ) { return headers } let headerTokens = split(headerLine, { $0 == ":" }) if ( headerTokens.count >= 2 ) { let headerName = headerTokens[0] let headerValue = headerTokens[1] if ( !headerName.isEmpty && !headerValue.isEmpty ) { headers.updateValue(headerValue, forKey: headerName) } } } return nil } func parseLine(socket: CInt) -> String? { // TODO - read more bytes than one // TODO - check if there is a nicer way to manipulate bytes with Swift ( recv(...) -> String ) var characters: String = "" var buff: UInt8[] = UInt8[](count: 1, repeatedValue: 0), n: Int = 1 do { n = recv(socket, &buff, 1, 0); if ( n > 0 && buff[0] > 13 /* CR */ ) { characters += Character(UnicodeScalar(UInt32(buff[0]))) } } while ( n > 0 && buff[0] != 10 /* NL */ ) if ( n == -1 ) { return nil } println("SOCKET LOG [\(socket)] -> \(characters)") return characters } }
[ -1 ]
bdb119b580b97e5cae05c718b42ba5ab6a510c63
eea3a0c370e0b61c4c0e4a88a4341749af2415ee
/douyuTV/douyuTV/Class/ProfileViewController/ProfileViewController.swift
0ef1106f2f93ce1f736266869955b0c76654171a
[ "MIT" ]
permissive
wuzer/douyuTV
8f2846a6740721ccdc11d854efb4b3179b17ba36
b575a41d9eb937aa76f0c2cff6e1d2870bdcf732
refs/heads/master
2021-01-17T15:26:19.006191
2016-11-07T10:45:59
2016-11-07T10:45:59
69,867,101
0
0
null
null
null
null
UTF-8
Swift
false
false
942
swift
// // ProfileViewController.swift // douyuTV // // Created by Jefferson on 2016/10/4. // Copyright © 2016年 Jefferson. All rights reserved. // import UIKit class ProfileViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() // title = "我的" view.backgroundColor = UIColor.yellow // Do any additional setup after loading the view. } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } /* // MARK: - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation override func prepare(for segue: UIStoryboardSegue, sender: Any?) { // Get the new view controller using segue.destinationViewController. // Pass the selected object to the new view controller. } */ }
[ 286271 ]
fb30f2ed09f4e9cbba1cd86dcb55d8f83a2a0680
8e2a7c3d67c58f910b3bd7883f2b129aa308f922
/PhotoBrowser/PhotoBrowserTests/PhotoBrowserTests.swift
d5ded1e6808c170abb5a37c2ca2bf2bc0dac8a88
[]
no_license
ThePowerOfSwift/PhotoBrowser
c260cb748e2df25fff5b6a237992a132966302ce
a05611dbe2545aeab336cc8f775d82980354ccdf
refs/heads/master
2021-01-19T16:36:43.612448
2016-03-06T10:49:41
2016-03-06T10:49:41
null
0
0
null
null
null
null
UTF-8
Swift
false
false
995
swift
// // PhotoBrowserTests.swift // PhotoBrowserTests // // Created by lifirewolf on 16/3/4. // Copyright © 2016年 lifirewolf. All rights reserved. // import XCTest @testable import PhotoBrowser class PhotoBrowserTests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. } override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() } func testExample() { // This is an example of a functional test case. // Use XCTAssert and related functions to verify your tests produce the correct results. } func testPerformanceExample() { // This is an example of a performance test case. self.measureBlock { // Put the code you want to measure the time of here. } } }
[ 282633, 313357, 98333, 239650, 229413, 102437, 354343, 204840, 354345, 227370, 223274, 292902, 233517, 155694, 309295, 229424, 282672, 278570, 237620, 229430, 180280, 288833, 288834, 286788, 313416, 311372, 354385, 223316, 280661, 315476, 278615, 307289, 354393, 237663, 315487, 309345, 45153, 280675, 227428, 280677, 313447, 315497, 278634, 194666, 315498, 131178, 278638, 288879, 284788, 333940, 223350, 233590, 280694, 288889, 131191, 233589, 292988, 313469, 215166, 131198, 292992, 215164, 278655, 194691, 227460, 280712, 215178, 235662, 311438, 278670, 323729, 278677, 284825, 284826, 278685, 311458, 278691, 233636, 184484, 299174, 284841, 233642, 284842, 153776, 278704, 239793, 299187, 278708, 131256, 184505, 278714, 223419, 280762, 227513, 299198, 295098, 280768, 227524, 309444, 280778, 282831, 280795, 227548, 229597, 301279, 311519, 280802, 176362, 286958, 184570, 227578, 184575, 309503, 194820, 313608, 278797, 325905, 319763, 325912, 309529, 282909, 278816, 282913, 233762, 237857, 217380, 211235, 211238, 282919, 227616, 98610, 280887, 278842, 315706, 282939, 307517, 287041, 260418, 287043, 321860, 139589, 280902, 319813, 227654, 311621, 325968, 6481, 278869, 289110, 6489, 168281, 379225, 293556, 323935, 106847, 354655, 321894, 416104, 280939, 285040, 313713, 242033, 199029, 246136, 291192, 317820, 211326, 311681, 248194, 227725, 240016, 190871, 291224, 293274, 285084, 141728, 61857, 285090, 61859, 246178, 289189, 315810, 315811, 311727, 299441, 293303, 283064, 278970, 319930, 293306, 293310, 278978, 127427, 127428, 291267, 283075, 278989, 281037, 281040, 278993, 326100, 278999, 328152, 176601, 369116, 188894, 287198, 279008, 160225, 358882, 285150, 279013, 279018, 319981, 291311, 281072, 309744, 319987, 279029, 279032, 233978, 279039, 301571, 291333, 342536, 287241, 279050, 303631, 283153, 279057, 303636, 279062, 279065, 299700, 291358, 182817, 180771, 293419, 244269, 283182, 283184, 236081, 234036, 289332, 279094, 23092, 315960, 338490, 70209, 115270, 70215, 293448, 55881, 377418, 309830, 281166, 281171, 309846, 287318, 332378, 295519, 66150, 111208, 279144, 279146, 313966, 281199, 295536, 287346, 287352, 301689, 244347, 279164, 291454, 189057, 279177, 152203, 287374, 111253, 316053, 117397, 230040, 227990, 289434, 303771, 111259, 221852, 295576, 205471, 314009, 279206, 279210, 287404, 295599, 285361, 303793, 299699, 342706, 318130, 166582, 289462, 314040, 230072, 158394, 285371, 285372, 285373, 287422, 285374, 303803, 287417, 66242, 287433, 225995, 154316, 287439, 334547, 279252, 96984, 287452, 289502, 299746, 295652, 279269, 246503, 285415, 234217, 342762, 293612, 129773, 289518, 230125, 279280, 312047, 312052, 125684, 199414, 154359, 230134, 228088, 299770, 234234, 221948, 279294, 205568, 242433, 295682, 299776, 191235, 285444, 322313, 322316, 295697, 291604, 166676, 285466, 283419, 326429, 293664, 281377, 234277, 283430, 262951, 279336, 289576, 262954, 318250, 295724, 318252, 312108, 301871, 164656, 303920, 262962, 285487, 234294, 230199, 285497, 293693, 289598, 160575, 281408, 295744, 279362, 295746, 318278, 201551, 281427, 281433, 230234, 322395, 234331, 301918, 295776, 279392, 293730, 303972, 279397, 230248, 177001, 201577, 308076, 400239, 246641, 174963, 207732, 310131, 295798, 209783, 228215, 209785, 279417, 246648, 177019, 308092, 291712, 158593, 113542, 287622, 228233, 228234, 308107, 58253, 56208, 308112, 234386, 293781, 324506, 324507, 318364, 277403, 310176, 310178, 289698, 189348, 283558, 289703, 279464, 293800, 310182, 236461, 293806, 304051, 189374, 289727, 19399, 213960, 279498, 316364, 183248, 304087, 50143, 314342, 234472, 234473, 324586, 326635, 203757, 289774, 183279, 304110, 320493, 287731, 277492, 240630, 295927, 304122, 312314, 318461, 234500, 277509, 134150, 322570, 230410, 234514, 277524, 316437, 140310, 322582, 293910, 197657, 281626, 175132, 189474, 300068, 238639, 300084, 322612, 238651, 308287, 238664, 234577, 296019, 234587, 277597, 304222, 113760, 281697, 302177, 230499, 281700, 285798, 300135, 300136, 322663, 228458, 207979, 279660, 15471, 144496, 234609, 312434, 280280, 285814, 300151, 279672, 337017, 291959, 160891, 285820, 300158, 150657, 187521, 234625, 285828, 279685, 285830, 222343, 302216, 302213, 228491, 234638, 326804, 185493, 296086, 238743, 187544, 308372, 119962, 283802, 296092, 300188, 339102, 285851, 300187, 330913, 306338, 234663, 300202, 281771, 249002, 238765, 279728, 238769, 208058, 294074, 230588, 64700, 228542, 228540, 283840, 302274, 279747, 283847, 244940, 283853, 283852, 279760, 290000, 189652, 279765, 189653, 148696, 279774, 304351, 298208, 310497, 298212, 304356, 290022, 279785, 228588, 234733, 298221, 279792, 298228, 302325, 234742, 292085, 228600, 216315, 292091, 388349, 208124, 228609, 292107, 312587, 251153, 177428, 173334, 339234, 130338, 130343, 279854, 298291, 286013, 306494, 216386, 279875, 286018, 113987, 300359, 230729, 294218, 234827, 177484, 222541, 296270, 234831, 238927, 296273, 224586, 314709, 314710, 283991, 357719, 292195, 294243, 230756, 281957, 163175, 230765, 284014, 306542, 296303, 327025, 279920, 296307, 116084, 181625, 111993, 290173, 306559, 224640, 179587, 148867, 294275, 298374, 314758, 314760, 142729, 296329, 368011, 296335, 112017, 306579, 224661, 282007, 357786, 318875, 310692, 282022, 314791, 282024, 279974, 310701, 314798, 173491, 304564, 279989, 286132, 228795, 292283, 302531, 292292, 339398, 300487, 306631, 296392, 280010, 300489, 310732, 280013, 312782, 64975, 302540, 306639, 310736, 222675, 284107, 212442, 228827, 286172, 239068, 280032, 144867, 187878, 316902, 280041, 329197, 329200, 306673, 282096, 296433, 308723, 306677, 191990, 300535, 280055, 288249, 286202, 300536, 290300, 286205, 302590, 290301, 294400, 296448, 282114, 230913, 306692, 306693, 300542, 230921, 296461, 323087, 304656, 282129, 316946, 308756, 282136, 282141, 302623, 286244, 286254, 312880, 288309, 290358, 288318, 194110, 280130, 349763, 196164, 288326, 282183, 218696, 288327, 292425, 56902, 333388, 228943, 286288, 290390, 300630, 128599, 235095, 306776, 196187, 239198, 157281, 286306, 300644, 282213, 317032, 310889, 323178, 312940, 204397, 222832, 314998, 288378, 175741, 235135, 294529, 239237, 282245, 286343, 288392, 229001, 282246, 290443, 310923, 323217, 282259, 229020, 333470, 282271, 282273, 302754, 282276, 40613, 40614, 40615, 282280, 290471, 229029, 298667, 298661, 206504, 300714, 321199, 286388, 286391, 337591, 306874, 280251, 282303, 286399, 280257, 323263, 218819, 282312, 306890, 280267, 302797, 282318, 212688, 313041, 302802, 280278, 282327, 286423, 278233, 278234, 18138, 67292, 298712, 294622, 321247, 278240, 298720, 282339, 153319, 12010, 288491, 280300, 239341, 282348, 284401, 282355, 323316, 282358, 313081, 229113, 286459, 300794, 194304, 288512, 278272, 323331, 323332, 288516, 311042, 280327, 216839, 280329, 282378, 300811, 321295, 284431, 278291, 278293, 282391, 116505, 284442, 286494, 282400, 313120, 315171, 282409, 284459, 294700, 280366, 300848, 282417, 200498, 296755, 280372, 321337, 282427, 280380, 345919, 315202, 282434, 307011, 282438, 153415, 280392, 280390, 304977, 307025, 413521, 18262, 216918, 307031, 280410, 284507, 188251, 300894, 237408, 284512, 284514, 296806, 276327, 292712, 282474, 288619, 288620, 280430, 282480, 292720, 313203, 300918, 194429, 315264, 339841, 305026, 243591, 282504, 67463, 279217, 243597, 110480, 184208, 282518, 282519, 294807, 214937, 214938, 294809, 337815, 298909, 294814, 311199, 239514, 300963, 294823, 298920, 284587, 292782, 200627, 282549, 288697, 290746, 294843, 98239, 280514, 294850, 280519, 214984, 151497, 284619, 344013, 301008, 194515, 280541, 298980, 292837, 294886, 296941, 329712, 278512, 311282, 325619, 282612, 311281, 292858 ]
0bfe99981eb200793c9ef367e9e85b558fc6c385
41ec8b00e59962183691aee34bde9c47722e482b
/ExcellentTipCalculatorUITests/ExcellentTipCalculatorUITests.swift
9af448d067a96de37b3723a4d256252f1720f823
[ "Apache-2.0" ]
permissive
mayank-sharma-16/ExcellentTipCalculator
ca41e1da4a9add774bc0dedede9422065de6097f
b283f2ea72b38c1128dd4ffc86a21380b6b2eb38
refs/heads/master
2020-05-03T20:08:07.428769
2019-04-01T06:55:35
2019-04-01T06:55:35
178,796,535
0
0
null
null
null
null
UTF-8
Swift
false
false
1,210
swift
// // ExcellentTipCalculatorUITests.swift // ExcellentTipCalculatorUITests // // Created by Mayank Sharma on 3/26/19. // Copyright © 2019 Mayank Sharma. All rights reserved. // import XCTest class ExcellentTipCalculatorUITests: XCTestCase { override func setUp() { // Put setup code here. This method is called before the invocation of each test method in the class. // In UI tests it is usually best to stop immediately when a failure occurs. continueAfterFailure = false // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. XCUIApplication().launch() // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. } override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. } func testExample() { // Use recording to get started writing UI tests. // Use XCTAssert and related functions to verify your tests produce the correct results. } }
[ 333827, 243720, 282634, 241695, 237599, 223269, 354342, 315431, 229414, 315433, 292901, 325675, 102441, 278571, 102446, 124974, 354346, 282671, 229425, 243763, 241717, 321589, 319543, 180279, 215095, 229431, 288829, 325695, 288835, 237638, 313415, 239689, 315468, 311373, 196687, 278607, 311377, 354386, 223317, 315477, 321632, 315489, 45154, 233578, 194667, 278637, 288878, 319599, 278642, 131190, 288890, 131199, 235661, 323730, 311447, 327834, 284827, 299166, 311459, 284840, 323761, 125108, 180409, 223418, 258233, 295099, 227517, 299197, 280767, 299202, 309443, 176325, 227525, 301255, 280779, 321744, 227536, 280792, 311520, 325857, 182503, 319719, 338151, 317676, 286957, 125166, 125170, 313595, 125180, 125184, 125192, 125197, 125200, 227601, 319764, 125204, 278805, 334104, 315674, 282908, 299294, 125215, 282912, 278817, 311582, 211239, 282920, 125225, 317738, 321839, 98611, 125236, 282938, 168251, 278843, 319812, 280903, 319816, 282959, 289109, 168280, 391521, 239973, 381286, 285031, 313703, 280938, 242027, 242028, 321901, 278895, 354671, 315769, 291194, 291193, 248188, 313726, 211327, 240003, 158087, 227721, 242059, 311692, 227730, 285074, 315798, 291225, 317851, 285083, 242079, 285089, 289185, 293281, 305572, 156069, 311723, 289195, 299449, 311739, 293309, 311744, 317889, 291266, 278979, 278988, 281038, 281039, 278992, 283088, 283089, 279000, 242138, 285152, 279009, 291297, 188899, 195044, 279014, 319976, 279017, 311787, 319986, 279030, 311800, 317949, 279042, 322057, 342537, 279053, 182802, 303635, 279061, 279066, 322077, 291359, 227881, 293420, 283185, 23093, 234037, 244279, 244280, 338491, 301635, 322119, 55880, 377419, 281165, 326229, 115287, 189016, 111197, 295518, 287327, 242274, 244326, 287345, 313970, 301688, 291455, 297600, 311944, 334473, 316044, 184974, 311950, 316048, 311953, 316050, 227991, 295575, 289435, 303772, 205469, 221853, 279207, 295598, 318127, 279215, 342705, 285362, 287412, 154295, 303802, 66243, 291529, 287434, 363212, 242385, 279253, 299737, 322269, 295653, 342757, 289511, 234216, 330473, 289517, 215790, 170735, 312046, 199415, 234233, 279293, 322302, 205566, 299777, 228099, 285443, 291591, 295688, 322312, 285450, 312076, 322320, 295698, 291605, 283418, 285467, 221980, 281378, 318247, 283431, 279337, 293673, 318251, 301872, 303921, 234290, 285493, 230198, 285496, 201534, 281407, 222017, 293702, 318279, 281426, 279379, 295769, 234330, 281434, 322396, 275294, 230238, 301919, 279393, 349025, 303973, 279398, 177002, 242540, 242542, 310132, 295797, 279418, 269179, 314240, 158594, 240517, 228232, 416649, 316299, 234382, 308111, 308113, 293780, 289691, 209820, 240543, 283551, 289704, 279465, 304050, 289720, 289723, 189373, 213956, 345030, 279499, 56270, 191445, 183254, 314343, 324587, 289773, 203758, 320504, 312313, 312317, 234499, 293894, 320526, 234513, 238611, 316441, 197658, 132140, 189487, 281647, 322609, 312372, 203829, 238650, 320571, 21567, 160834, 336962, 314437, 207954, 234578, 205911, 296023, 314458, 281699, 230500, 285795, 228457, 318571, 279659, 234606, 230514, 279666, 312435, 302202, 285819, 314493, 222344, 318602, 228492, 337037, 177297, 324761, 285850, 296091, 119965, 234655, 300192, 339106, 306339, 234662, 300200, 3243, 322733, 300215, 64699, 294075, 228541, 283846, 148687, 290001, 189651, 316628, 279766, 189656, 279775, 304352, 298209, 304353, 279780, 228587, 279789, 290030, 316661, 283894, 208123, 279803, 292092, 228608, 320769, 322826, 242955, 177420, 312588, 318732, 126229, 318746, 320795, 320802, 130342, 304422, 130344, 298290, 312628, 300342, 222523, 286012, 181568, 279872, 193858, 216387, 294210, 300355, 372039, 304457, 296269, 234830, 296274, 314708, 357720, 316764, 230757, 281958, 314727, 134504, 306541, 314734, 327023, 312688, 284015, 316786, 296304, 314740, 314742, 314745, 224637, 314752, 243073, 179586, 306561, 294278, 314759, 296328, 296330, 304523, 318860, 314765, 298378, 314771, 224662, 234902, 282008, 318876, 290206, 148899, 314788, 314790, 298406, 282023, 241067, 279979, 314797, 286128, 279988, 286133, 284090, 302523, 228796, 310714, 302530, 280003, 228804, 292291, 306630, 310725, 300488, 300490, 302539, 306634, 310731, 310735, 312785, 222674, 280025, 310747, 239069, 144862, 286176, 320997, 187877, 280042, 191980, 300526, 337391, 296434, 308722, 191991, 40439, 286201, 288252, 312830, 290304, 228868, 323079, 292359, 218632, 230922, 323083, 294413, 323088, 282132, 316951, 282135, 374297, 222754, 306730, 230960, 288305, 239159, 290359, 323132, 157246, 288319, 280131, 349764, 124486, 194118, 282182, 288328, 224848, 224852, 290391, 128600, 235096, 306777, 212574, 345697, 204386, 99937, 312937, 243306, 224874, 312941, 294517, 290425, 325246, 333438, 282244, 239238, 282248, 323208, 188049, 323226, 229021, 302751, 282272, 282279, 298664, 317102, 286392, 302778, 306875, 280252, 280253, 323262, 282302, 296636, 323265, 321217, 280259, 282309, 319176, 296649, 212684, 241360, 241366, 294621, 282336, 321250, 153318, 12009, 288492, 34547, 67316, 323315, 282366, 319232, 323335, 282375, 116491, 216844, 282379, 284430, 161553, 124691, 118549, 116502, 278294, 325403, 321308, 321309, 282399, 241440, 282401, 325411, 315172, 241447, 333609, 294699, 284460, 280367, 282418, 319289, 321338, 280377, 413500, 280381, 241471, 280386, 280391, 153416, 315209, 280396, 307024, 317268, 237397, 241494, 284508, 300893, 276326, 282471, 282476, 292719, 313200, 296815, 317305, 124795, 317308, 339840, 315265, 327556, 188293, 282503, 67464, 243592, 315272, 315275, 311183, 124816, 282517, 294806, 214936, 124826, 329627, 239515, 214943, 319393, 333734, 219046, 284584, 313257, 292783, 200628, 288698, 214978, 280517, 280518, 214983, 153553, 231382, 323554, 292835, 190437, 292838, 317416, 278507, 311277, 296942, 124912, 327666, 278515, 325620, 313338 ]
813a0d228e061651cbaead2f7fe7260c9544c874
01615e1154e584c24a5c9c472d2f527c4e45506d
/Push Notification Demo/AppDelegate.swift
410269d6a165216d4a2f7f117a2b4262b91fd627
[]
no_license
Aishwaryalaxmi/Urban-Airship-iOS
a59b7c38c0ee52f61b615d8b4938db5f2fa88a04
e8ecabe5002637152edfc7b82c4d6565ca22dcd2
refs/heads/master
2020-04-13T19:15:37.415220
2019-01-12T18:28:49
2019-01-12T18:28:49
163,397,262
0
0
null
null
null
null
UTF-8
Swift
false
false
2,458
swift
// // AppDelegate.swift // Push Notification Demo // // Created by Aishwarya on 28/12/18. // Copyright © 2018 Aishwarya. All rights reserved. // import UIKit import AirshipKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. UAirship.takeOff() UAirship.push()?.userPushNotificationsEnabled = true UAirship.push()?.defaultPresentationOptions = [.alert,.badge,.sound] UAirship.push()?.isAutobadgeEnabled = true UAirship.push()?.tags = ["One"] return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 229388, 294924, 229391, 327695, 229394, 229397, 229399, 229402, 278556, 229405, 229408, 294950, 229415, 229417, 327722, 237613, 229422, 360496, 229426, 237618, 229428, 286774, 319544, 204856, 229432, 286776, 286778, 286791, 237640, 286797, 278605, 311375, 163920, 237646, 196692, 319573, 311383, 319590, 311400, 278635, 303212, 278639, 131192, 237693, 303230, 327814, 131209, 303241, 417930, 303244, 311436, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 295110, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 237807, 303345, 286962, 303347, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 287032, 155966, 319809, 319810, 278849, 319814, 311623, 319818, 311628, 229709, 287054, 319822, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 311746, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 287202, 279010, 279015, 172520, 319978, 279020, 172526, 311791, 279023, 172529, 279027, 319989, 180727, 164343, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 172550, 320007, 303623, 287238, 172552, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 295461, 172581, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 213575, 172618, 303690, 33357, 287309, 279124, 172634, 262752, 172644, 311911, 189034, 295533, 172655, 172656, 352880, 295538, 189039, 172660, 287349, 189040, 189044, 287355, 287360, 295553, 295557, 311942, 303751, 287365, 352905, 311946, 287371, 279178, 311951, 287377, 172691, 287381, 311957, 221850, 287386, 230045, 172702, 164509, 287390, 172705, 287394, 172707, 303780, 295583, 287398, 287400, 279208, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 287423, 328384, 279231, 287427, 312006, 107208, 287436, 107212, 172748, 172751, 287440, 295633, 172755, 303827, 279255, 172760, 287450, 303835, 279258, 189149, 303838, 213724, 279267, 312035, 295654, 279272, 230128, 312048, 312050, 230131, 205564, 303871, 230146, 328453, 295685, 230154, 33548, 312077, 295695, 295701, 230169, 369433, 295707, 328476, 295710, 230175, 303914, 279340, 205613, 279353, 230202, 312124, 328508, 222018, 295755, 377676, 148302, 287569, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303981, 303985, 303987, 328563, 279413, 303991, 303997, 295806, 295808, 295813, 304005, 304007, 320391, 304009, 213895, 304011, 230284, 304013, 295822, 279438, 295825, 189329, 189331, 304019, 58262, 304023, 279452, 410526, 279461, 279462, 304042, 213931, 304055, 230327, 287675, 197564, 304063, 238528, 304065, 213954, 189378, 156612, 295873, 213963, 312272, 304084, 304090, 320481, 320490, 304106, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 230413, 197645, 295949, 320528, 140312, 295961, 238620, 197663, 304164, 304170, 304175, 238641, 312374, 238652, 238655, 230465, 238658, 296004, 336964, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 296040, 361576, 205931, 296044, 164973, 205934, 312432, 279669, 189562, 337018, 279679, 279683, 222340, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 165038, 238766, 230576, 304311, 230592, 312518, 279750, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 279781, 304360, 320748, 279788, 279790, 304370, 296189, 320771, 312585, 296202, 296205, 320786, 230674, 230677, 214294, 296215, 320792, 230681, 296213, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 296253, 222525, 296255, 312639, 230718, 296259, 378181, 296262, 238919, 320840, 230727, 296264, 296271, 222545, 230739, 312663, 337244, 222556, 230752, 312676, 230760, 173418, 148843, 230763, 410987, 230768, 296305, 312692, 230773, 304505, 181626, 304506, 181631, 312711, 312712, 296331, 288140, 288144, 230800, 304533, 288154, 337306, 173472, 288160, 288162, 288164, 279975, 304555, 370092, 279983, 173488, 288176, 279985, 312755, 296373, 312759, 279991, 288185, 337335, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 288210, 370130, 222676, 280021, 288212, 288214, 239064, 329177, 288217, 288218, 280027, 288220, 239070, 288224, 288226, 370146, 280036, 288229, 320998, 280038, 288232, 288230, 288234, 280034, 288236, 288238, 288240, 288242, 296435, 288244, 288250, 321022, 296446, 402942, 206336, 296450, 148990, 230916, 230919, 214535, 230923, 304651, 304653, 370187, 230940, 222752, 108066, 296488, 157229, 239152, 230961, 157236, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 288344, 280152, 239194, 280158, 403039, 370272, 181854, 239202, 312938, 280183, 280185, 280188, 280191, 116354, 280194, 280208, 280211, 288408, 280218, 280222, 190118, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 313027, 280260, 206536, 280264, 206539, 206541, 206543, 280276, 313044, 321239, 280283, 313052, 288478, 313055, 321252, 313066, 288494, 280302, 280304, 313073, 321266, 419570, 288499, 288502, 288510, 124671, 67330, 280324, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 321316, 304932, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 337732, 280388, 304968, 280393, 280402, 173907, 313176, 280419, 321381, 296809, 296812, 313201, 1920, 255873, 305028, 247688, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 214944, 280487, 313258, 321458, 296883, 124853, 214966, 296890, 10170, 288700, 296894, 190403, 280515, 296900, 337862, 165831, 280521, 231379, 296921, 239586, 313320, 231404, 124913, 165876, 321528, 313340, 239612, 288764, 239617, 313347, 288773, 313358, 305176, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 321595, 378941, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 149599, 280671, 149601, 321634, 149603, 223327, 329830, 280681, 313451, 223341, 280687, 215154, 313458, 280691, 313464, 321659, 280702, 288895, 321670, 215175, 141446, 141455, 141459, 280725, 313498, 275608, 100520, 288936, 280747, 288940, 288947, 280755, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 125171, 157940, 182517, 280823, 280825, 280827, 280830, 280831, 280833, 125187, 280835, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 280891, 289087, 280897, 280900, 305480, 239944, 280906, 239947, 305485, 305489, 379218, 280919, 354653, 313700, 313705, 280937, 190832, 280946, 223606, 313720, 280956, 280959, 313731, 199051, 240011, 289166, 240017, 297363, 190868, 297365, 240021, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 305594, 289210, 281024, 289218, 289221, 289227, 281045, 281047, 166378, 305647, 281075, 174580, 240124, 281084, 305662, 305664, 240129, 305666, 240132, 223749, 330244, 305668, 223752, 150025, 281095, 338440, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 338528, 338532, 281190, 199273, 281196, 158317, 19053, 313973, 297594, 281210, 158347, 182926, 133776, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 297671, 158409, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 183172, 158596, 338823, 322440, 314249, 240519, 183184, 142226, 240535, 289687, 297883, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 281567, 289762, 322534, 297961, 183277, 322550, 134142, 322563, 314372, 330764, 175134, 322599, 322610, 314421, 281654, 314427, 207937, 314433, 314441, 207949, 322642, 314456, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 248995, 306341, 306344, 306347, 322734, 306354, 142531, 199877, 289991, 306377, 289997, 249045, 363742, 363745, 298216, 330988, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 380226, 298306, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 306555, 314747, 298365, 290171, 290174, 224641, 281987, 314756, 298372, 281990, 224647, 265604, 298377, 314763, 142733, 298381, 314768, 224657, 306581, 314773, 314779, 314785, 187939, 314793, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 191992, 290298, 151036, 290302, 282111, 290305, 175621, 192008, 323084, 257550, 290321, 282130, 323090, 282133, 290325, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 323176, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 282261, 175770, 298651, 323229, 282269, 298655, 323231, 61092, 282277, 306856, 282295, 323260, 282300, 323266, 282310, 323273, 282319, 306897, 241362, 306904, 282328, 298714, 52959, 282337, 216801, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 241450, 282410, 306988, 306991, 315184, 323376, 315190, 241464, 159545, 282425, 298811, 307009, 413506, 241475, 307012, 298822, 148946, 315211, 282446, 307027, 315221, 323414, 315223, 241496, 241498, 307035, 307040, 110433, 282465, 241509, 110438, 298860, 110445, 282478, 282481, 110450, 315249, 315251, 315253, 315255, 339838, 315267, 282499, 315269, 241544, 282505, 241546, 241548, 298896, 298898, 282514, 241556, 298901, 241560, 282520, 241563, 241565, 241567, 241569, 241574, 282537, 298922, 36779, 241581, 282542, 241583, 323504, 241586, 290739, 241588, 282547, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 241661, 299006, 282623, 315396, 241669, 315397, 282632, 282639, 290835, 282645, 241693, 282654, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 315482, 217179, 315483, 192605, 233567, 299105, 200801, 217188, 299109, 315495, 307303, 356457, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 315524, 307338, 233613, 241813, 307352, 299164, 184479, 299167, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 299185, 323763, 184503, 176311, 307385, 307386, 258235, 307388, 176316, 307390, 299200, 184512, 307394, 299204, 307396, 184518, 307399, 323784, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 282893, 323854, 291089, 282906, 291104, 233766, 176435, 307508, 315701, 307510, 332086, 307512, 168245, 307515, 282942, 307518, 282947, 323917, 110926, 282957, 233808, 323921, 315733, 323926, 233815, 315739, 323932, 299357, 276053, 242018, 242024, 315757, 299373, 250231, 242043, 315771, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 315801, 291226, 242075, 283033, 61855, 291231, 283042, 291238, 291241, 127403, 127405, 127407, 291247, 299440, 299444, 127413, 291254, 283062, 194660, 127417, 291260, 127421, 127424, 299457, 127429, 127431, 315856, 176592, 315860, 176597, 283095, 127447, 299481, 176605, 242143, 291299, 340454, 127463, 242152, 291305, 127466, 176620, 127469, 127474, 291314, 291317, 135672, 291323, 233979, 291330, 283142, 135689, 127497, 233994, 291341, 233998, 234003, 234006, 127511, 152087, 283161, 234010, 135707, 242202, 135710, 242206, 242208, 291361, 303773, 242220, 291378, 152118, 234038, 70213, 242250, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 135808, 291456, 373383, 299655, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 135844, 299684, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 299726, 225998, 226002, 119509, 226005, 226008, 242396, 299740, 201444, 299750, 283368, 234219, 283372, 226037, 283382, 316151, 234231, 234236, 226045, 242431, 234239, 209665, 234242, 242436, 234246, 226056, 291593, 234248, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 234269, 283421, 234272, 234274, 152355, 299814, 234278, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 160572, 283452, 234302, 234307, 242499, 234309, 316233, 234313, 316235, 234316, 283468, 234319, 242511, 234321, 234324, 201557, 234329, 234333, 308063, 234336, 242530, 349027, 234338, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 234356, 177011, 234358, 234362, 234364, 291711, 234368, 291714, 234370, 291716, 234373, 226182, 234375, 308105, 226185, 234379, 234384, 234388, 234390, 324504, 234393, 209818, 308123, 324508, 234396, 291742, 226200, 234401, 291747, 291748, 234405, 291750, 324518, 324520, 234407, 291754, 324522, 291756, 226220, 234414, 324527, 291760, 234417, 201650, 324531, 234422, 226230, 275384, 324536, 234428, 291773, 234431, 242623, 324544, 234434, 324546, 324548, 234437, 226245, 226239, 234439, 234443, 291788, 234446, 275406, 193486, 234449, 193488, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 234487, 324599, 234490, 234493, 234496, 316416, 234501, 308231, 234504, 234507, 234510, 234515, 300054, 234519, 316439, 234520, 234523, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 234543, 234546, 275508, 234549, 300085, 300088, 234556, 234558, 316479, 234561, 316483, 308291, 234563, 234568, 234570, 316491, 234572, 300108, 234574, 300115, 234580, 234581, 234585, 275545, 242777, 234590, 234593, 234595, 300133, 234597, 234601, 300139, 234605, 160879, 234607, 275569, 234610, 300148, 234614, 398455, 144506, 234618, 234620, 275579, 234623, 226433, 234627, 275588, 234634, 234636, 177293, 234640, 275602, 234643, 308373, 324757, 234647, 234648, 226453, 234650, 308379, 275606, 234653, 300189, 119967, 324768, 324766, 283805, 234657, 242852, 300197, 283813, 234661, 234664, 275626, 234667, 316596, 308414, 234687, 300223, 300226, 308418, 283844, 300229, 308420, 308422, 234692, 283850, 300234, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 300267, 161003, 300270, 300272, 120053, 300278, 275703, 316663, 300284, 275710, 300287, 292097, 300289, 161027, 300292, 300294, 275719, 177419, 300299, 275725, 242957, 283917, 177424, 300301, 349464, 283939, 259367, 292143, 283951, 300344, 226617, 243003, 283963, 226628, 283973, 300357, 177482, 283983, 316758, 357722, 316766, 316768, 292192, 218464, 292197, 316774, 243046, 218473, 136562, 324978, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 316811, 226699, 316814, 226703, 300433, 234899, 226709, 357783, 316824, 316826, 300448, 144807, 144810, 144812, 284076, 144814, 144820, 284084, 284087, 292279, 144826, 144828, 144830, 144832, 227430, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 218597, 292329, 300523, 259565, 300527, 308720, 259567, 292338, 226802, 316917, 292343, 308727, 300537, 316947, 308757, 308762, 284191, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 284213, 308790, 284215, 316983, 194103, 284218, 194101, 226877, 284223, 284226, 243268, 284228, 292421, 284231, 226886, 128584, 284234, 366155, 276043, 317004, 284238, 226895, 284241, 194130, 284243, 300628, 284245, 292433, 284247, 317015, 235097, 243290, 284249, 284251, 284253, 300638, 284255, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 284278, 292470, 276086, 292473, 284283, 276093, 284286, 276095, 284288, 292479, 284290, 325250, 284292, 292485, 276098, 292481, 284297, 317066, 284299, 317068, 276109, 284301, 284303, 284306, 276114, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 284329, 317098, 284331, 276137, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 358080, 276160, 284354, 358083, 284358, 276166, 358089, 284362, 276170, 276175, 284368, 276177, 284370, 358098, 284372, 317138, 284377, 284379, 284381, 284384, 358114, 284386, 358116, 276197, 317158, 358119, 284392, 325353, 284394, 358122, 284397, 276206, 284399, 358128, 358126, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 358146, 317187, 284418, 317189, 317191, 284428, 300816, 300819, 317207, 300828, 300830, 276255, 300832, 325408, 300834, 317221, 227109, 358183, 186151, 276268, 300845, 243504, 300850, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 153417, 292681, 358224, 284499, 276308, 178006, 317271, 284502, 276315, 292700, 317279, 284511, 227175, 292715, 300912, 284529, 292721, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 358292, 284564, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 317353, 284585, 276395, 292776, 292784, 276402, 358326, 161718, 358330, 276411, 276418, 276425, 301009, 301011, 301013, 292823, 358360, 301017, 301015, 292828, 276446, 153568, 276448, 292839, 276455, 292843, 276460, 292845, 178161, 227314, 276466, 325624, 276472, 317435, 276476, 276479, 276482, 276485, 276490, 292876, 317456, 276496, 317458, 243733, 317468, 243740, 317472, 325666, 243751, 292904, 276528, 243762, 309298, 325685, 325689, 235579, 325692, 235581, 276539, 178238, 276544, 243779, 325700, 284739, 292934, 243785, 350293, 350295, 309337, 194649, 350299, 227418, 350302, 194654, 227423, 178273, 309346, 227426, 309348, 350308, 309350, 276579, 292968, 309352, 309354, 301163, 350313, 350316, 276583, 301167, 276586, 350321, 276590, 227440, 284786, 350325, 276595, 350328, 292985, 301178, 350332, 292989, 301185, 317570, 350339, 292993, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 350366, 276638, 153765, 284837, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 301258, 309450, 276685, 276689, 309462, 301272, 276699, 309468, 194780, 309471, 301283, 317672, 317674, 325867, 243948, 194801, 309491, 227571, 309494, 243960, 227583, 276735, 276739, 211204, 276742, 227596, 325910, 342298, 309530, 211232, 317729, 211241, 325937, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 293227, 276843, 293232, 276848, 186744, 211324, 227709, 317833, 178572, 285070, 285077, 178583, 227738, 317853, 276896, 342434, 317858, 285093, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 293346, 276964, 293352, 236013, 293364, 301562, 317951, 309764, 301575, 121352, 236043, 317963, 342541, 55822, 113167, 309779, 277011, 309781, 317971, 55837, 227877, 227879, 293417, 227882, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 219714, 129603, 301636, 318020, 301639, 301643, 285265, 399955, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 121458, 170618, 170619, 309885, 309888, 277122, 227975, 277128, 285320, 301706, 318092, 326285, 318094, 334476, 277136, 277139, 334488, 227992, 318108, 285340, 318110, 227998, 137889, 383658, 285357, 318128, 277170, 293555, 318132, 154292, 277173, 342707, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 137946, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 277232, 228081, 56059, 310015, 285441, 310020, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 285474, 293666, 228135, 318248, 277291, 318253, 293677, 285489, 293685, 285494, 301880, 285499, 301884, 293696, 310080, 277317, 293706, 277322, 277329, 162643, 310100, 301911, 277337, 301913, 301921, 400236, 236397, 162671, 326514, 310134, 15224, 236408, 277368, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 293811, 293817, 293820, 203715, 326603, 293849, 293861, 228327, 228328, 318442, 228332, 326638, 277486, 318450, 293876, 293877, 285686, 302073, 121850, 293882, 302075, 285690, 244731, 293887, 277504, 277507, 277511, 277519, 293908, 293917, 293939, 318516, 277561, 277564, 310336, 7232, 293956, 277573, 228422, 293960, 310344, 277577, 277583, 203857, 293971, 310359, 236632, 277594, 138332, 277598, 285792, 277601, 203872, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 367737, 285817, 302205, 285821, 392326, 253064, 302218, 285835, 294026, 162964, 384148, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 302241, 285862, 277671, 302248, 64682, 277678, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 302296, 384222, 310498, 285927, 318698, 302315, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 138505, 228617, 318742, 204067, 277798, 130345, 277801, 113964, 285997, 277804, 285999, 277807, 113969, 277811, 318773, 318776, 277816, 286010, 277819, 294204, 417086, 277822, 302403, 294211, 384328, 277832, 277836, 294223, 326991, 277839, 277842, 277847, 277850, 179547, 277853, 146784, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 310659, 351619, 294276, 327046, 277892, 277894, 310665, 318858, 253320, 277898, 277903, 310672, 351633, 277905, 277908, 277917, 310689, 277921, 130468, 228776, 277928, 277932, 310703, 277937, 310710, 130486, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 302534, 310727, 64966, 245191, 277959, 277963, 302541, 277966, 302543, 310737, 277971, 228825, 163290, 277978, 310749, 277981, 277984, 310755, 277989, 277991, 187880, 277995, 310764, 286188, 278000, 228851, 310772, 278003, 278006, 40440, 212472, 278009, 286203, 40443, 40448, 228864, 286214, 228871, 302603, 302614, 302617, 286233, 302621, 286240, 146977, 294435, 40484, 196133, 40486, 286246, 245288, 294439, 294440, 40491, 294443, 294445, 40488, 286248, 310831, 40499, 40502, 212538, 40507, 40511, 40513, 228933, 40521, 286283, 40525, 40527, 212560, 228944, 400976, 40533, 147032, 40537, 40539, 40541, 278109, 40544, 40548, 40550, 40552, 286312, 40554, 286313, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 294537, 310925, 286354, 278163, 302740, 122517, 278168, 179870, 327333, 229030, 212648, 302764, 278188, 278192, 319153, 278196, 302781, 319171, 302789, 294599, 278216, 294601, 302793, 319187, 278227, 229076, 286420, 286425, 319194, 278235, 229086, 278238, 286432, 294625, 294634, 302838, 319226, 286460, 278274, 302852, 278277, 302854, 311048, 294664, 352008, 319243, 311053, 302862, 319251, 294682, 278306, 188199, 294701, 319280, 278320, 319290, 229192, 302925, 188247, 188252, 237409, 229233, 294776, 360317, 294785, 327554, 40840, 40851, 294803, 188312, 294811, 237470, 319390, 40865, 319394, 294817, 294821, 311209, 180142, 294831, 188340, 40886, 319419, 294844, 294847, 393177, 294876, 294879, 294883, 294890, 311279, 278513, 237555, 311283, 278516, 237562 ]
cd8dad6c91c1e13e727ff81a084f7191d647fb3f
26c4bffd56f7d743c7b90f30733195ed714c14d8
/Rxzhihu/Rxzhihu/Classes/Vender/SkinManager/SkinManager.swift
7342f9f53e3fa6641b8683cbb8a0b4ae7f87db51
[ "Apache-2.0" ]
permissive
wscqs/Rxzhihu
2e103b099a2af66008fac7745970adc54420aca3
b61ac1f053ec617ea90e6101f049dceec50147c7
refs/heads/master
2021-01-12T05:58:22.102625
2016-12-26T10:19:55
2016-12-26T10:19:55
77,260,019
0
0
null
null
null
null
UTF-8
Swift
false
false
4,262
swift
// // File.swift // SkinManager // // Created by nantang on 2016/11/16. // Copyright © 2016年 nantang. All rights reserved. // import UIKit public protocol ValueFilter { static func valueFrom<T>(array:[T]?) -> T? } public protocol keyPathValue { static func value<T>(forKeyPath keyPath:String) -> T? } public struct SkinManager { public static var skinIndex: Int = 0 { didSet{ updateSkin() performActions() } } fileprivate static var skinDict: NSDictionary? fileprivate static var path:Path? public static func switchTo(plistName: String, path:Path){ guard let plistPath = path.plistPath(name: plistName) else { assertionFailure("SkinManager: No plist named \(plistName) from \(path)") return } guard let plistDict = NSDictionary(contentsOfFile: plistPath) else { assertionFailure("SkinManager: Read plist failed from \(plistPath)") return } switchTo(skinDict: plistDict, path: path) } public static func switchTo(skinDict: NSDictionary, path: Path){ self.skinDict = skinDict self.path = path updateSkin() performActions() } fileprivate static var objectActionMapper = Dictionary<Weak<NSObjectProtocol>,AnyObject>() fileprivate static var objectToUpdate = Set<Weak<NSObjectProtocol>>() private static func updateSkin() { objectToUpdate.forEach{ $0.value?.updateSkin() } } private static func performActions() { objectActionMapper.forEach { (key: Weak<NSObjectProtocol>, value: AnyObject) in if let value = value as? Block { value.block() return } if let value = value as? String,let obj = key.value { let sel = NSSelectorFromString(value) if obj.responds(to: sel) { _ = obj.perform(sel) } } } } } extension SkinManager{ internal static func add(observer:NSObjectProtocol) { self.objectToUpdate.insert(Weak(value: observer)) } public static func add(observer:NSObjectProtocol, for sel:Selector) { self.objectActionMapper[Weak(value: observer)] = NSStringFromSelector(sel) as AnyObject? } public static func add(observer:NSObjectProtocol, using block:@escaping () -> ()) { self.objectActionMapper[Weak(value: observer)] = Block(block: block) } public static func remove(observer:NSObjectProtocol) { self.objectActionMapper.removeValue(forKey: Weak(value:observer)) } } extension SkinManager:ValueFilter { public static func valueFrom<T>(array:[T]?) -> T? { guard let array = array, array.count > 0 else{ return nil } if array.count <= skinIndex { return array.first } return array[skinIndex] } } extension SkinManager:keyPathValue { public static func value<T>(forKeyPath keyPath:String) -> T? { return skinDict?.value(forKeyPath: keyPath) as? T } public static func image(forKeyPath keyPath:String) -> UIImage?{ guard let imageName:String = value(forKeyPath: keyPath) else { return nil } if let filePath = path?.URL?.appendingPathComponent(imageName).path { return UIImage(contentsOfFile: filePath) } else { return UIImage(named: imageName) } } } public enum Path { case mainBundle case sandbox(Foundation.URL) public var URL: Foundation.URL? { switch self { case .mainBundle: return nil case .sandbox(let path): return path } } public func plistPath(name: String) -> String? { switch self { case .mainBundle: return Bundle.main.path(forResource: name, ofType: "plist") case .sandbox(let path): return Foundation.URL(string: name + ".plist", relativeTo: path)?.path } } } class Weak<T: NSObjectProtocol>:Hashable, CustomStringConvertible { weak var value : T? init (value: T) { self.value = value } var hashValue: Int{ guard let value = value else { return 0 } return value.hash } public static func == (lhs:Weak<T>,rhs:Weak<T>) -> Bool{ return lhs.hashValue == rhs.hashValue } var description: String{ return "Weak<\(value?.description)>" } } typealias Action = () -> () private class Block:NSObject { var block:Action init(block:@escaping Action) { self.block = block } }
[ -1 ]
d95e5e7b04d54becc590165fb82a974d74cb8dd1
bc0126f752c4bbde2410a76f7dd92ff4647a0601
/Africa/View/MapAnnotationView.swift
ea1698bdc55beb226d44d1784d49a9e394f16598
[]
no_license
Wishtrader/Africa
cb6da6126d25661245dbb48a19ea53231bece82a
06dc46fc25b8258fe0719d2938cbc47fe558ed2c
refs/heads/main
2023-08-13T17:59:55.956373
2021-10-04T12:10:28
2021-10-04T12:10:28
407,816,123
0
0
null
2021-10-04T12:21:10
2021-09-18T09:28:38
Swift
UTF-8
Swift
false
false
1,430
swift
// // MapAnnotationView.swift // Africa // // Created by Andrei Kamarou on 25.09.21. // import SwiftUI struct MapAnnotationView: View { // MARK: - PROPERTIES var location: NationalParkLocation @State private var animation: Double = 0.0 // MARK: - BODY var body: some View { ZStack { Circle() .fill(Color.accentColor) .frame(width: 54, height: 54, alignment: .center) Circle() .stroke(Color.accentColor, lineWidth: 2) .frame(width: 52, height: 52, alignment: .center) .scaleEffect(1 + CGFloat(animation)) .opacity(1 - animation) Image(location.image) .resizable() .scaledToFit() .frame(width: 48, height: 48, alignment: .center) .clipShape(Circle()) } //: ZSTACK .onAppear { withAnimation(Animation.easeOut(duration: 2).repeatForever(autoreverses: false)) { animation = 1.0 } } } } // MARK: - PREVIEW struct MapAnnotationView_Previews: PreviewProvider { static var locations: [NationalParkLocation] = Bundle.main.decode("locations.json") static var previews: some View { MapAnnotationView(location: locations[0]) .previewLayout(.sizeThatFits) .padding() } }
[ 358586, 358485, 358514 ]
ef7fef6718c6f08a33f5214a84c0653f0caa27eb
1593434cd386f133781d47cf89e92c0acc66a928
/Sources/iTunesSearch/NetworkRequest.swift
6469991cd01dcfc200f2838a25929a7d5f87603d
[ "Apache-2.0" ]
permissive
coodly/iTunesSearch
92f00f3759fdaa08703a6f0fe4bbcc900b959830
2dc595412d4f71c7ae4fb557e10a0d34a43388a2
refs/heads/master
2021-06-25T20:34:06.549946
2020-05-24T13:33:31
2020-05-24T13:33:31
57,390,995
1
0
null
null
null
null
UTF-8
Swift
false
false
3,376
swift
/* * Copyright 2016 Coodly LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import Foundation #if canImport(FoundationNetworking) import FoundationNetworking #endif private let APIServer = "https://itunes.apple.com" private enum Method: String { case POST case GET } internal class NetworkRequest: FetchConsumer { var fetch: NetworkFetch! var apiKey: String! var resultHandler: ((Any?, Error?) -> ())! func execute() { fatalError("Override \(#function)") } func GET(_ path: String, parameters: [String: AnyObject]? = nil) { executeMethod(.GET, path: path, parameters: parameters) } func POST(_ path: String, parameters: [String: AnyObject]? = nil) { executeMethod(.POST, path: path, parameters: parameters) } private func executeMethod(_ method: Method, path: String, parameters: [String: AnyObject]?) { var components = URLComponents(url: URL(string: APIServer)!, resolvingAgainstBaseURL: true)! components.path = components.path + path if let parameters = parameters { var queryItems = [URLQueryItem]() for (name, value) in parameters { queryItems.append(URLQueryItem(name: name, value: value as? String)) } components.queryItems = queryItems } let requestURL = components.url! let request = NSMutableURLRequest(url: requestURL) request.httpMethod = method.rawValue fetch.fetch(request as URLRequest) { data, response, error in if let error = error { Logging.log("Fetch error \(error)") self.handle(error: error) } if let data = data { let decoder = JSONDecoder() let formatter = DateFormatter() formatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ss'Z'" decoder.dateDecodingStrategy = .formatted(formatter) do { let result = try decoder.decode(SearchResults.self, from: data) self.handle(success: result.results) } catch let error as NSError { if let tunesError = try? decoder.decode(TunesError.self, from: data) { self.handle(error: tunesError) } else { self.handle(error: error) } } } else { self.handle(error: error) } } } func handle(success hits: [SearchHit]) { Logging.log("handleSuccessResponse") } func handle(error: Error?) { Logging.log("handleErrorResponse") resultHandler(nil, error) } }
[ -1 ]
bf717cf18b3a180ad75627d5c48283bfcd052098
eeb99ba840a58401e322ccba2de79363d08ceec2
/Rapptr iOS Test/View Controllers/LoginViewController.swift
4f6b1e164d6d934e5dd96620ed3f681d588f670c
[]
no_license
Andylochan/RapptriOS
a8ffa4ca38c9565d4902d03d36a3911d18033733
ea0b9fbbf9e32cbcef9b154819c12177910a1df5
refs/heads/master
2023-07-02T12:48:54.120251
2021-08-16T04:39:25
2021-08-16T04:39:25
395,397,736
0
0
null
null
null
null
UTF-8
Swift
false
false
3,273
swift
// // LoginViewController.swift // iOSTest // // Copyright © 2020 Rapptr Labs. All rights reserved. import UIKit class LoginViewController: UIViewController { /** * ========================================================================================= * INSTRUCTIONS * ========================================================================================= * 1) Make the UI look like it does in the mock-up. * 2) Take email and password input from the user * 3) Use the endpoint and paramters provided in LoginClient.m to perform the log in * 4) Calculate how long the API call took in milliseconds * 5) If the response is an error display the error in a UIAlertController * 6) If the response is successful display the success message AND how long the API call took in milliseconds in a UIAlertController * 7) When login is successful, tapping 'OK' in the UIAlertController should bring you back to the main menu. **/ // MARK: - Properties private var client: LoginClient? // MARK: - Outlets @IBOutlet weak var userTextfield: UITextField! @IBOutlet weak var passwordTextfield: UITextField! @IBOutlet weak var loginButton: UIButton! // MARK: - Lifecycle override func viewDidLoad() { super.viewDidLoad() title = "Login" loginButton.isEnabled = false; loginButton.layer.opacity = 0.6 userTextfield.addTarget(self, action: #selector(textFieldDidChange(_:)), for:.editingChanged ) passwordTextfield.addTarget(self, action: #selector(textFieldDidChange(_:)), for:.editingChanged ) } // MARK: - Actions @IBAction func backAction(_ sender: Any) { let mainMenuViewController = MenuViewController() self.navigationController?.pushViewController(mainMenuViewController, animated: true) } @IBAction func didPressLoginButton(_ sender: Any) { LoginClient.shared.login(email: userTextfield.text ?? "", password: passwordTextfield.text ?? "") { (response, message) in DispatchQueue.main.async { let alert = UIAlertController(title: "Login Complete", message: "\(message)\n Request took \(response) ms", preferredStyle: .alert) alert.addAction(UIAlertAction(title: "OK", style: .default, handler: { action in self.navigationController?.popToRootViewController(animated: true) })) self.present(alert, animated: true) } } error: { (error) in DispatchQueue.main.async { let alert = UIAlertController(title: "Error", message: (String(describing: error)), preferredStyle: .alert) alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil)) self.present(alert, animated: true) } } } // MARK: - Functions @objc func textFieldDidChange(_ sender: UITextField) { if userTextfield.text == "" || passwordTextfield.text == "" { loginButton.isEnabled = false; loginButton.layer.opacity = 0.6 } else { loginButton.isEnabled = true; loginButton.layer.opacity = 1.0 } } }
[ -1 ]
597fd1e351bf569562e3e7f34c3a913a3dd16e7d
5791c65fb34bef7b6f8e3eaf9f8279d15323c750
/RetroTechApp/Delegates/NavigationBarTitleChangerDelegate.swift
db42a6a01a01e9c7fe110d2d26e03f981a77ffbc
[]
no_license
EvgeniyUskov/RetroTechApp
228a3496d292392b5edde33ab534fc0ddd0b714a
d8078d0eb0e1977533f000157cdd416740d11868
refs/heads/master
2021-03-17T13:50:37.874168
2020-03-16T12:28:13
2020-03-16T12:28:13
246,994,732
0
0
null
null
null
null
UTF-8
Swift
false
false
306
swift
// // NavBarTitleChangerDelegate.swift // RetroTechApp // // Created by Evgeniy Uskov on 10.03.2020. // Copyright © 2020 Evgeniy Uskov. All rights reserved. // import Foundation protocol NavigationBarTitleChangerDelegate: AnyObject { func updateDeviceTitle(computer: ComputerDetailsViewModel) }
[ -1 ]
52be1543af092372169578687e266c44efc77e06
9cc1c7fbfedd081432655725f6281958d2380890
/Tests/MapboxMapsTests/Foundation/GeoJSON/GeometryCollectionTests.swift
d04f92ba0a21bdf8bcb3b3ae45b26701fef11355
[ "ISC", "BSL-1.0", "BSD-2-Clause", "MIT", "LicenseRef-scancode-object-form-exception-to-mit", "BSD-3-Clause", "Zlib" ]
permissive
6122617139/mapbox-maps-ios
041c4522f5efa030144d45003f83770b380a0b5d
6c415bc1e6614da7cf97f18d6919dfe2169d9a3c
refs/heads/main
2023-08-22T03:44:25.871699
2021-09-24T14:22:40
2021-09-24T14:22:40
410,054,754
1
0
NOASSERTION
2021-09-24T17:51:49
2021-09-24T17:51:47
null
UTF-8
Swift
false
false
2,853
swift
import XCTest import CoreLocation @testable import MapboxMaps // Disabling rules against force try for test file. // swiftlint:disable explicit_top_level_acl explicit_acl force_try class GeometryCollectionTests: XCTestCase { func testGeometryCollectionFeatureDeserialization() { // Arrange let data = try! Fixture.geojsonData(from: "geometry-collection")! let multiPolygonCoordinate = CLLocationCoordinate2D(latitude: 8.5, longitude: 1) // Act let geoJSON = try! GeoJSON.parse(data) // Assert XCTAssert(geoJSON.decoded is Turf.Feature) guard let geometryCollectionFeature = geoJSON.decoded as? Turf.Feature else { XCTFail("Failed to create Feature.") return } XCTAssert(geometryCollectionFeature.geometry.type == .GeometryCollection) XCTAssert(geometryCollectionFeature.geometry.value is GeometryCollection) guard case let .geometryCollection(geometries) = geometryCollectionFeature.geometry else { XCTFail("Failed to create GeometryCollection.") return } XCTAssert(geometries.geometries[2].type == .MultiPolygon) guard case let .multiPolygon(decodedMultiPolygonCoordinate) = geometries.geometries[2] else { XCTFail("Failed to create MultiPolygon.") return } XCTAssertEqual(decodedMultiPolygonCoordinate.coordinates[0][1][2], multiPolygonCoordinate) } func testGeometryCollectionFeatureSerialization() { // Arrange let multiPolygonCoordinate = CLLocationCoordinate2D(latitude: 8.5, longitude: 1) let data = try! Fixture.geojsonData(from: "geometry-collection")! let geoJSON = try! GeoJSON.parse(data) // Act let encodedData = try! JSONEncoder().encode(geoJSON) let encodedJSON = try! GeoJSON.parse(encodedData) // Assert XCTAssert(encodedJSON.decoded is Turf.Feature) guard let geometryCollectionFeature = encodedJSON.decoded as? Turf.Feature else { XCTFail("Failed to create Feature.") return } XCTAssert(geometryCollectionFeature.geometry.type == .GeometryCollection) XCTAssert(geometryCollectionFeature.geometry.value is GeometryCollection) guard case let .geometryCollection(geometries) = geometryCollectionFeature.geometry else { XCTFail("Failed to create GeometryCollection.") return } XCTAssert(geometries.geometries[2].type == .MultiPolygon) guard case let .multiPolygon(decodedMultiPolygonCoordinate) = geometries.geometries[2] else { XCTFail("Failed to create MultiPolygon.") return } XCTAssertEqual(decodedMultiPolygonCoordinate.coordinates[0][1][2], multiPolygonCoordinate) } }
[ -1 ]
bb3fa5855b1548f8e39773c0d0255e275e32ee31
f83d52b8e54dfa6e2a02d246fc7eb04a4c5750f5
/DailyTasks/ContentView.swift
7219d8dbdc3ad769c075e0899744a4321633a2e8
[ "MIT" ]
permissive
ppsdatta/dview-ios
ea18837ba147c282610cd2c6f5619f758410aebc
f4b2522467e8c10cc1cfab26af3290213f7fc933
refs/heads/master
2022-04-15T21:05:15.521570
2020-04-12T13:07:02
2020-04-12T13:07:02
255,076,342
0
0
null
null
null
null
UTF-8
Swift
false
false
680
swift
import SwiftUI import WebKit struct ContentView: View { var body: some View { WebView().edgesIgnoringSafeArea(.all) } } struct WebView: UIViewRepresentable { func makeUIView(context: Context) -> WKWebView { let webView = WKWebView() webView.scrollView.isScrollEnabled = true return webView } func updateUIView(_ webView: WKWebView, context: Context) { let liveView = "https://sheltered-tundra-09814.herokuapp.com" if let url = URL(string: liveView) { let request = URLRequest(url: url) webView.load(request) } } } struct ContentView_Previews : PreviewProvider { static var previews: some View { ContentView() } }
[ -1 ]
23500a81df0bc33272175fc352682d74a8fd37c8
e881e1989b8af7f1d598033f89de0f10c7ed5293
/PakinBO/PKBOGeocoder.swift
70baeb77f37844e4779abd4685db0c50687246b1
[]
no_license
gdibernardo/PakinBO
7952097d2a6cc521a1c8560295d783e889516c00
9fe34ddbe041c3e9ed9dfdef52e09f2c9fd87367
refs/heads/master
2021-06-21T15:03:44.259143
2017-06-22T00:54:34
2017-06-22T00:54:34
49,820,910
3
0
null
null
null
null
UTF-8
Swift
false
false
7,192
swift
// // PKBOGeocoder.swift // PakinBO // // Created by Gabriele Di Bernardo on 03/06/15. // Copyright (c) 2015 Gabriele Di Bernardo. All rights reserved. // import UIKit import Foundation class PKBOGeocoder: NSObject { private static let singleGeocoderInstance = PKBOGeocoder() private var cache = [PKBOGeocoderAddress]() private static func queryWithAddress(address address: String) -> String { var formattedAddress = address + ", Bologna" formattedAddress = formattedAddress.stringByAddingPercentEscapesUsingEncoding(NSUTF8StringEncoding)! return "https://maps.googleapis.com/maps/api/geocode/json?address=\(formattedAddress)&region=it" } private static func globalQueue() -> dispatch_queue_t { return dispatch_get_global_queue(Int(QOS_CLASS_UTILITY.rawValue), 0) } static func sharedInstance() -> PKBOGeocoder { return singleGeocoderInstance } func emptyCache() { self.cache = [PKBOGeocoderAddress]() } private func saveInCache(address: PKBOGeocoderAddress) { let checkArray = self.cache.filter { (cacheAddress: PKBOGeocoderAddress) -> Bool in (cacheAddress.coordinate?.latitude == address.coordinate?.latitude && cacheAddress.coordinate?.longitude == cacheAddress.coordinate?.longitude) } if checkArray.isEmpty { self.cache.append(address) self.cache.sortInPlace { (firstElement: PKBOGeocoderAddress, secondElement: PKBOGeocoderAddress) -> Bool in firstElement.formattedAddress!.localizedCaseInsensitiveCompare(secondElement.formattedAddress!) == NSComparisonResult.OrderedAscending } } } private func searchInCache(address address: String) -> [PKBOGeocoderAddress] { let cacheResults = self.cache.filter { (cacheAddress: PKBOGeocoderAddress) -> Bool in cacheAddress.formattedAddress!.containsIgnoringCase(address) } return cacheResults } func geocodeAddress(address: String, withCompletionHandler completionHandler: ([PKBOGeocoderAddress]!, NSError!) -> Void) { let query = PKBOGeocoder.queryWithAddress(address: address) /* Check in cache first. */ let cacheResults = self.searchInCache(address: address) if(cacheResults.count > 0) { completionHandler(cacheResults,nil) return } self.geocodeWithQuery(query) { (result: NSData?) -> Void in if let unwrappedResult = result { let error: NSError? let jsonDictionary: NSDictionary? do { jsonDictionary = try NSJSONSerialization.JSONObjectWithData(unwrappedResult, options: []) as? NSDictionary } catch _ { jsonDictionary = nil } // let jsonDictionary = NSJSONSerialization.JSONObjectWithData(unwrappedResult, // options: []) as? NSDictionary // if let unwrappedError = error // { // /* JSON serialization error. */ // completionHandler(nil, unwrappedError) // } var addressResults = [PKBOGeocoderAddress]() var results = jsonDictionary!["results"] as? [AnyObject] for index in 0 ..< results!.count { let types = results![index].objectForKey("types") as? [String] if((types!).contains("route")) { let address = PKBOGeocoderAddress.address() let addressComponents = results![index].objectForKey("address_components") as? [AnyObject] for(var component = 0; component < addressComponents!.count; component++) { let currentComponent = addressComponents![component] as! NSDictionary let currentTypes = currentComponent["types"] as! [String] if(currentTypes.contains("route")) { address.route = currentComponent["long_name"] as? String } if(currentTypes.contains("locality")) { address.locality = currentComponent["long_name"] as? String } if(currentTypes.contains("country")) { address.country = currentComponent["long_name"] as? String } } address.formattedAddress = results![index].objectForKey("formatted_address") as? String let location = (results![index].objectForKey("geometry") as? NSDictionary)!["location"] as? NSDictionary let latitude = location!["lat"] as! CLLocationDegrees let longitude = location!["lng"] as! CLLocationDegrees address.coordinate = CLLocationCoordinate2DMake(latitude, longitude) self.saveInCache(address) addressResults.append(address) } } completionHandler(addressResults,nil) } } } private func geocodeWithQuery(query: String, andCompletionHandler completionHandler: (NSData?) -> Void ) { let queue = PKBOGeocoder.globalQueue() PKBONetworkActivityIndicator.sharedInstance().show() dispatch_async(queue, { () -> Void in let data = NSData(contentsOfURL: NSURL(string: query)!) dispatch_async(dispatch_get_main_queue(), { () -> Void in PKBONetworkActivityIndicator.sharedInstance().hide() completionHandler(data) }) }) } } extension String { func containsIgnoringCase(string: String) -> Bool { var start = self.startIndex repeat { let substring = self[Range(start: start++, end: endIndex)].lowercaseString if(substring.hasPrefix(string.lowercaseString)) { return true } } while (start != self.endIndex) return false } }
[ -1 ]
c2d6ce6585d2f0bc97168661badc23fe53b215ae
b5d568616c4dc8ffc0057c5f90fdeb8e2c38c13a
/Final/AppDelegate.swift
f6504419649b2352929544b1df297d2d1a8ae2f5
[]
no_license
pjshalhoub/Final-Project
33aae108575f3ce98f81925832356de682c4957e
35a404a64c1bf1763aecc7d0dc26f2044d626614
refs/heads/master
2021-08-23T12:09:51.776051
2017-12-04T21:13:57
2017-12-04T21:13:57
112,424,601
0
0
null
null
null
null
UTF-8
Swift
false
false
4,008
swift
// // AppDelegate.swift // Final // // Created by PJ Shalhoub on 11/22/17. // Copyright © 2017 PJ Shalhoub. All rights reserved. // import UIKit import GooglePlaces import Firebase import GoogleSignIn @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate, GIDSignInDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. GMSPlacesClient.provideAPIKey("AIzaSyAHt1lhZdwyhx3yKx_64UZdUl4GjFOpWxc") FirebaseApp.configure() GIDSignIn.sharedInstance().clientID = FirebaseApp.app()?.options.clientID GIDSignIn.sharedInstance().delegate = self return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } @available(iOS 9.0, *) func application(_ application: UIApplication, open url: URL, options: [UIApplicationOpenURLOptionsKey : Any]) -> Bool { return GIDSignIn.sharedInstance().handle(url, sourceApplication:options[UIApplicationOpenURLOptionsKey.sourceApplication] as? String, annotation: [:]) } func sign(_ signIn: GIDSignIn!, didSignInFor user: GIDGoogleUser!, withError error: Error?) { // ... if let error = error { // ... return } print("%%%%% GoogleSignIn Successful!") guard let authentication = user.authentication else { return } let credential = GoogleAuthProvider.credential(withIDToken: authentication.idToken, accessToken: authentication.accessToken) // ... Auth.auth().signIn(with: credential) { (user, error) in if let error = error { // ... return } // User is signed in // ... print("***** Firebase sign in successful!") guard let controller = GIDSignIn.sharedInstance().uiDelegate as? SignInViewController else { return } controller.dismiss(animated: true, completion: nil) } } func sign(_ signIn: GIDSignIn!, didDisconnectWith user: GIDGoogleUser!, withError error: Error!) { // Perform any operations when the user disconnects from app here. // ... } }
[ -1 ]
bffd31d1f191a56c83a41e17e373ed606bfef53d
bc5442e83ec622d2ebeb6fdef7b4a2b163938419
/Detector/ViewController.swift
a9d360c34610440c5d2dda6c29c973ef9da76dc5
[]
no_license
rsampdev/FaceDetectorApp
2890c27ee406f05d82a20c558a171c399f3be336
917ffb834f37bc92b82441677daae9d8447ee690
refs/heads/master
2020-12-24T08:39:35.868766
2016-11-10T00:44:03
2016-11-10T00:44:03
73,333,686
0
0
null
null
null
null
UTF-8
Swift
false
false
2,273
swift
// // ViewController.swift // Detector // // Created by Gregg Mojica on 8/21/16. // Copyright © 2016 Gregg Mojica. All rights reserved. // import UIKit import CoreImage class ViewController: UIViewController { @IBOutlet weak var personPic: UIImageView! override func viewDidLoad() { super.viewDidLoad() personPic.image = UIImage(named: "face-4") detect() } func detect() { guard let personciImage = CIImage(image: personPic.image!) else { return } let accuracy = [CIDetectorAccuracy: CIDetectorAccuracyHigh] let faceDetector = CIDetector(ofType: CIDetectorTypeFace, context: nil, options: accuracy) let faces = faceDetector?.features(in: personciImage) let ciImageSize = personciImage.extent.size var transform = CGAffineTransform(scaleX: 1, y: -1) transform = transform.translatedBy(x: 0, y: -ciImageSize.height) for face in faces as! [CIFaceFeature] { print("Found bounds are \(face.bounds)") var faceViewBounds = face.bounds.applying(transform) let viewSize = personPic.bounds.size let scale = min(viewSize.width / ciImageSize.width, viewSize.height / ciImageSize.height) let offsetX = (viewSize.width - ciImageSize.width * scale) / 2 let offsetY = (viewSize.height - ciImageSize.height * scale) / 2 faceViewBounds = faceViewBounds.applying(CGAffineTransform(scaleX: scale, y: scale)) faceViewBounds.origin.x += offsetX faceViewBounds.origin.y += offsetY let faceBox = UIView(frame: faceViewBounds) faceBox.layer.borderWidth = 3 faceBox.layer.borderColor = UIColor.red.cgColor faceBox.backgroundColor = UIColor.clear personPic.addSubview(faceBox) if face.hasLeftEyePosition { print("Left eye bounds are \(face.leftEyePosition)") } if face.hasRightEyePosition { print("Right eye bounds are \(face.rightEyePosition)") } } } }
[ -1 ]
1104538664dd217cf7e5ff18fb4a5fda07dcc1ef
a86a527df5ed447e9ec9e63887bd2823d02eede4
/2018-05-31/W8D4-Firebase/notification/NotificationViewController.swift
9311d3b09e1fe910b1a1893c4b4755e3a32cd1c5
[]
no_license
jyliang/LightHouseLabs
38ce816d01579055ed4dfb4f22dded939b11a652
592a88d716c8d60c0e3f7736b6295e2d8c4b4c65
refs/heads/master
2023-01-21T10:23:26.643174
2019-06-19T20:44:15
2019-06-19T20:44:15
80,742,077
0
31
null
2023-01-09T11:24:17
2017-02-02T16:06:41
Objective-C
UTF-8
Swift
false
false
604
swift
// // NotificationViewController.swift // notification // // Created by Jason Liang on 6/4/18. // Copyright © 2018 Jason Liang. All rights reserved. // import UIKit import UserNotifications import UserNotificationsUI class NotificationViewController: UIViewController, UNNotificationContentExtension { @IBOutlet var label: UILabel? override func viewDidLoad() { super.viewDidLoad() // Do any required interface initialization here. } func didReceive(_ notification: UNNotification) { self.label?.text = notification.request.content.body } }
[ 350907, 325677 ]
f61e9b941fd0c00e48573fc624ac555664cbdd5f
a0a39e3edc400a338443d6579f7d90f0e56d5180
/7SwiftyWords.Project8/AppDelegate.swift
167244bafcdaafd4bb0823c29e352f160cb03909
[]
no_license
ElijahButers/7SwiftyWords.Project8
6c31d246f93cdcba9a2ddd193ed5e3dbb7c9a6e6
bdabf986d7aa968ee2b6b8878ae4c5cd01b0a3f4
refs/heads/master
2021-01-10T17:13:48.043411
2016-03-18T15:48:39
2016-03-18T15:48:39
55,407,582
0
0
null
null
null
null
UTF-8
Swift
false
false
2,151
swift
// // AppDelegate.swift // 7SwiftyWords.Project8 // // Created by User on 3/16/16. // Copyright © 2016 Elijah Buters. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. } func applicationDidEnterBackground(application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(application: UIApplication) { // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 229388, 294924, 278542, 229391, 327695, 278545, 229394, 278548, 229397, 229399, 229402, 278556, 229405, 278559, 229408, 278564, 294950, 229415, 229417, 237613, 229422, 229426, 237618, 229428, 286774, 319544, 204856, 286776, 229432, 286791, 237640, 278605, 286797, 311375, 237646, 163920, 196692, 319573, 311383, 278623, 278626, 319590, 311400, 278635, 303212, 278639, 131192, 237693, 327814, 131209, 417930, 303241, 311436, 303244, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 278760, 237807, 303345, 286962, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 287032, 155966, 278849, 319809, 319810, 319814, 319818, 311628, 229709, 287054, 319822, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 279010, 287202, 279015, 172520, 319978, 279020, 172526, 279023, 311791, 172529, 279027, 319989, 164343, 180727, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 287238, 320007, 172550, 172552, 303623, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 172618, 303690, 33357, 287309, 279124, 172634, 262752, 311911, 189034, 295533, 189039, 189040, 172655, 172656, 295538, 189044, 172660, 287349, 352880, 287355, 287360, 295553, 287365, 295557, 303751, 311942, 352905, 279178, 287371, 311946, 311951, 287377, 287381, 311957, 221850, 287386, 164509, 287390, 295583, 230045, 303773, 287394, 172702, 303780, 172705, 287398, 172707, 287400, 279208, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 279231, 287423, 328384, 287427, 312006, 107208, 107212, 287436, 172748, 172751, 287440, 295633, 172755, 303827, 279255, 172760, 279258, 303835, 213724, 189149, 303838, 287450, 279267, 312035, 295654, 279272, 230128, 312048, 312050, 230131, 205564, 303871, 230146, 295685, 230154, 33548, 312077, 295695, 295701, 369433, 230169, 295707, 328476, 295710, 230175, 303914, 279340, 205613, 279353, 230202, 312124, 222018, 295755, 377676, 148302, 287569, 279383, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303985, 328563, 303987, 279413, 303991, 303997, 295806, 295808, 304005, 295813, 320391, 213895, 304009, 304007, 304011, 230284, 304013, 213902, 279438, 295822, 295825, 189329, 304019, 189331, 279445, 58262, 279452, 410526, 279461, 279462, 304042, 213931, 230327, 304055, 287675, 304063, 238528, 304065, 189378, 213954, 156612, 295873, 213963, 312272, 304084, 304090, 320481, 320490, 304106, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 295949, 197645, 230413, 320528, 140312, 238620, 197663, 304164, 189479, 304170, 238641, 312374, 238652, 238655, 230465, 238658, 296004, 336964, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 361576, 296040, 205931, 296044, 164973, 205934, 279661, 312432, 279669, 189562, 337018, 279679, 279683, 222340, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 165038, 238766, 230576, 304311, 230592, 279750, 230600, 230607, 148690, 279769, 304348, 279777, 304354, 296163, 279781, 304360, 279788, 320748, 279790, 304370, 320771, 312585, 296202, 296205, 320786, 230674, 296213, 214294, 296215, 320792, 230677, 230681, 304416, 230689, 173350, 312622, 296243, 312630, 222522, 222525, 230718, 296255, 312639, 296259, 378181, 230727, 238919, 320840, 222545, 230739, 312663, 222556, 337244, 230752, 312676, 230760, 173418, 230763, 410987, 230768, 296305, 230773, 279929, 181626, 304506, 304505, 181631, 312711, 296331, 288140, 230800, 288144, 304533, 337306, 288154, 288160, 173472, 288162, 288164, 279975, 304555, 370092, 279983, 173488, 279985, 312755, 296373, 279991, 312759, 288185, 337335, 222652, 173507, 296389, 222665, 230860, 280014, 312783, 230865, 288210, 370130, 288212, 280021, 288214, 222676, 239064, 288217, 288218, 280027, 288220, 329177, 239070, 288224, 288226, 370146, 280036, 288229, 280038, 288230, 288232, 280034, 288234, 320998, 288236, 288238, 288240, 288242, 296435, 288244, 296439, 288250, 402942, 148990, 206336, 296446, 296450, 321022, 230916, 230919, 214535, 370187, 304651, 304653, 230940, 222752, 108066, 296488, 230961, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 280152, 288344, 239194, 280158, 403039, 370272, 181854, 239202, 312938, 280183, 280185, 280188, 280191, 280194, 116354, 280208, 280211, 288408, 280218, 280222, 190118, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 280260, 280264, 206536, 206539, 206541, 280276, 313044, 321239, 280283, 288478, 313055, 321252, 313066, 280302, 288494, 280304, 313073, 419570, 288499, 288502, 280314, 288510, 124671, 67330, 280324, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 280388, 304968, 280393, 280402, 313176, 280419, 321381, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 280458, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 280487, 313258, 321458, 296883, 124853, 214966, 10170, 296890, 288700, 296894, 280515, 190403, 296900, 337862, 165831, 280521, 231379, 296921, 239586, 313320, 231404, 124913, 165876, 321528, 288764, 239612, 239617, 313347, 288773, 313358, 305176, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 378941, 313406, 288831, 288836, 67654, 223303, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 280671, 223327, 149599, 321634, 149603, 329830, 280681, 313451, 223341, 280687, 215154, 280691, 313458, 313464, 321659, 280702, 288895, 321670, 215175, 141446, 141455, 141459, 280725, 313498, 288936, 100520, 280747, 288940, 280755, 288947, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 313548, 321740, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 280819, 157940, 182517, 125171, 280823, 280825, 280827, 280830, 280831, 280833, 280835, 125187, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 280891, 289087, 280897, 280900, 239944, 305480, 280906, 239947, 305485, 305489, 379218, 280919, 354653, 313700, 280937, 313705, 280940, 190832, 280946, 223606, 313720, 280956, 280959, 313731, 240011, 199051, 289166, 240017, 297363, 190868, 240021, 297365, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 289210, 305594, 281024, 289218, 289221, 289227, 281045, 281047, 215526, 166378, 305647, 281075, 174580, 281084, 240124, 305662, 305664, 240129, 305666, 240132, 223749, 305668, 281095, 223752, 338440, 150025, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 199262, 338528, 338532, 281190, 199273, 281196, 158317, 19053, 313973, 281210, 297594, 158347, 133776, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 199367, 297671, 158409, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 207661, 289593, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 183172, 158596, 338823, 322440, 314249, 240519, 183184, 240535, 289687, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 281567, 289762, 322534, 297961, 281581, 183277, 322550, 134142, 322563, 175134, 322599, 322610, 314421, 281654, 314427, 207937, 314433, 314441, 207949, 322642, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 289912, 308373, 248995, 306341, 306344, 306347, 306354, 142531, 199877, 289991, 306377, 249045, 363742, 363745, 298216, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 380226, 281923, 298306, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 290171, 306555, 314747, 290174, 298365, 224641, 281987, 298372, 314756, 281990, 224647, 265604, 298377, 314763, 142733, 298381, 224657, 306581, 314779, 314785, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 290298, 151036, 290302, 282111, 290305, 175621, 192008, 323084, 257550, 282127, 290321, 282130, 323090, 282133, 290325, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 282261, 298651, 282269, 323229, 298655, 323231, 61092, 282277, 306856, 282295, 282300, 323260, 323266, 282310, 323273, 282319, 306897, 241362, 282328, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 241448, 315176, 282410, 241450, 306988, 306991, 315184, 323376, 315190, 241464, 282425, 159545, 298811, 307009, 413506, 241475, 307012, 148946, 315211, 282446, 307027, 315221, 282454, 323414, 241496, 315223, 241498, 307035, 307040, 282465, 110433, 241509, 110438, 298860, 110445, 282478, 282481, 110450, 315251, 315249, 315253, 315255, 339838, 282499, 315267, 315269, 241544, 282505, 241546, 241548, 298896, 282514, 298898, 241556, 298901, 282520, 241560, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 36779, 241581, 282542, 241583, 323504, 241586, 282547, 241588, 290739, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 299006, 282623, 241669, 315397, 282632, 282639, 290835, 282645, 241693, 282654, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 315482, 217179, 315483, 192605, 233567, 200801, 217188, 299109, 315495, 307303, 45163, 307307, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 307338, 233613, 241813, 307352, 299164, 184479, 299167, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 323763, 176311, 184503, 307385, 307386, 258235, 176316, 307388, 307390, 299200, 184512, 307394, 307396, 299204, 184518, 323784, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 282893, 291089, 282906, 233766, 176435, 307508, 168245, 307510, 332086, 151864, 307512, 315701, 307515, 282942, 307518, 151874, 282947, 282957, 110926, 323917, 233808, 323921, 315733, 323926, 233815, 315739, 323932, 299357, 242018, 242024, 299373, 315757, 250231, 242043, 315771, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 283033, 291226, 242075, 291231, 61855, 283042, 291238, 291241, 127403, 127405, 127407, 291247, 299440, 299444, 127413, 283062, 291254, 127417, 291260, 283069, 127421, 127424, 127429, 127431, 283080, 176592, 315856, 315860, 176597, 283095, 127447, 299481, 176605, 242143, 291299, 242152, 291305, 127466, 176620, 291314, 291317, 135672, 291323, 233979, 291330, 283142, 127497, 135689, 233994, 291341, 233998, 234003, 234006, 127511, 152087, 283161, 242202, 234010, 135707, 242206, 135710, 242208, 291361, 242220, 291378, 152118, 234038, 70213, 284243, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 291456, 135808, 299655, 373383, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 299684, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 225998, 299726, 226002, 226005, 119509, 226008, 242396, 299740, 201444, 299750, 283368, 234219, 283372, 226037, 283382, 234231, 316151, 234236, 226045, 234239, 242431, 209665, 234242, 242436, 234246, 226056, 234248, 291593, 242443, 234252, 242445, 234254, 291601, 234258, 242450, 242452, 234261, 348950, 201496, 234264, 234266, 283421, 234269, 234272, 234274, 152355, 234278, 299814, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 283452, 160572, 234302, 234307, 242499, 234309, 234313, 316233, 316235, 283468, 234316, 234319, 242511, 234321, 234324, 201557, 234329, 234333, 308063, 234336, 234338, 242530, 349027, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 234356, 177011, 234358, 234362, 226171, 291711, 234368, 234370, 291714, 291716, 234373, 226182, 234375, 226185, 308105, 234379, 234384, 234388, 234390, 226200, 234393, 209818, 308123, 234396, 324504, 234398, 291742, 324508, 234401, 291747, 291748, 234405, 291750, 234407, 324518, 324520, 291754, 324522, 226220, 291756, 234414, 324527, 291760, 234417, 201650, 324531, 226230, 234422, 275384, 324536, 234428, 291773, 226239, 234431, 242623, 324544, 234434, 324546, 226245, 234437, 234439, 324548, 234443, 291788, 193486, 275406, 193488, 234446, 234449, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 234487, 324599, 234490, 234493, 234496, 316416, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 234519, 234520, 316439, 234523, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 144430, 234543, 234546, 275508, 234549, 300085, 300088, 234556, 234558, 316479, 234561, 234563, 308291, 316483, 234568, 234570, 316491, 234572, 300108, 234574, 300115, 234580, 234581, 234585, 275545, 242777, 234590, 234593, 234595, 234597, 300133, 234601, 300139, 234605, 234607, 160879, 275569, 234610, 300148, 234614, 398455, 234618, 144506, 234620, 275579, 234623, 226433, 234627, 275588, 275594, 234634, 234636, 177293, 234640, 275602, 234643, 226453, 275606, 234647, 275608, 234648, 234650, 308379, 324757, 283805, 234653, 119967, 300189, 234657, 324768, 324766, 242852, 283813, 234661, 300197, 234664, 275626, 234667, 316596, 308414, 234687, 316610, 300226, 226500, 308418, 283844, 300229, 308420, 234692, 283850, 300234, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 300267, 161003, 300270, 300272, 120053, 300278, 275703, 316663, 300284, 275710, 300287, 283904, 292097, 300289, 300292, 300294, 275719, 177419, 300299, 283917, 242957, 275725, 177424, 300301, 349464, 283939, 259367, 283951, 292143, 300344, 226617, 283963, 243003, 226628, 283973, 300357, 177482, 283983, 316758, 357722, 316766, 218464, 316768, 292197, 316774, 243046, 218473, 284010, 136562, 324978, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 226699, 316811, 316814, 226703, 300433, 234899, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 284076, 144812, 144814, 284084, 144820, 284087, 292279, 144826, 144828, 144830, 144832, 284099, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 218597, 292329, 300523, 259565, 259567, 300527, 308720, 226802, 316917, 308727, 300537, 316947, 308757, 308762, 284191, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 284213, 194101, 194103, 284215, 284218, 226877, 284223, 284226, 243268, 284228, 226886, 284231, 128584, 292421, 284234, 366155, 276043, 317004, 284238, 226895, 284241, 194130, 292433, 276052, 276053, 300628, 284245, 284247, 235097, 243290, 284251, 284249, 284253, 300638, 284255, 317015, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 276086, 284278, 292470, 292473, 284283, 276093, 284286, 276095, 284288, 292479, 276098, 284290, 284292, 292481, 292485, 325250, 284297, 317066, 284299, 317068, 276109, 284301, 284303, 276114, 284306, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 276137, 284329, 284331, 317098, 284333, 284335, 276144, 284337, 284339, 300726, 284343, 284346, 284350, 276160, 358080, 284354, 358083, 276166, 284358, 358089, 276170, 284362, 276175, 284368, 276177, 284370, 317138, 358098, 284372, 284377, 276187, 284379, 284381, 284384, 284386, 358116, 276197, 317158, 284392, 325353, 284394, 358122, 284397, 276206, 284399, 358128, 358126, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 284418, 317187, 358146, 317191, 284428, 300816, 300819, 317207, 284440, 186139, 300828, 300830, 276255, 300832, 284449, 300834, 325408, 227109, 317221, 358183, 186151, 276268, 300845, 194351, 243504, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 153417, 284499, 276308, 284502, 317271, 178006, 276315, 292700, 284511, 227175, 292715, 300912, 284529, 292721, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 276365, 284564, 358292, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 284585, 317353, 276395, 292776, 292784, 276402, 161718, 358326, 276410, 276411, 358330, 276418, 276425, 301009, 301011, 301013, 301015, 358360, 301017, 292828, 276446, 153568, 276448, 276452, 276455, 292839, 292843, 276460, 276464, 178161, 276466, 227314, 276472, 325624, 317435, 276476, 276479, 276482, 276485, 276490, 292876, 276496, 317456, 317458, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 243762, 309298, 325685, 325689, 276539, 235579, 235581, 178238, 325692, 276544, 284739, 292934, 276553, 243785, 350293, 350295, 194649, 227418, 309337, 194654, 227423, 350302, 178273, 227426, 276579, 194660, 309346, 227430, 276583, 309348, 309350, 276586, 350308, 309354, 350313, 276590, 350316, 227440, 301167, 284786, 276595, 350321, 350325, 350328, 292985, 301178, 292989, 292993, 317570, 350339, 301185, 317573, 350342, 227463, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 276638, 350366, 284837, 153765, 350375, 350379, 350381, 350383, 129200, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 227522, 350402, 301252, 350406, 227529, 301258, 309450, 276685, 276689, 227540, 309462, 301272, 276699, 309468, 194780, 309471, 301283, 317672, 276713, 325867, 243948, 194801, 227571, 309491, 276725, 309494, 243960, 227583, 276735, 227587, 276739, 211204, 276742, 227593, 227596, 325910, 342298, 309530, 276766, 211232, 317729, 276775, 211241, 325937, 276789, 325943, 211260, 260421, 276809, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 276843, 293227, 276848, 293232, 186744, 285051, 211324, 227709, 317833, 178572, 285070, 178575, 285077, 178583, 227738, 317853, 276896, 317858, 342434, 285093, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 317951, 309764, 301575, 121352, 236043, 317963, 342541, 55822, 113167, 277011, 309779, 309781, 317971, 55837, 227877, 227879, 293417, 227882, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 129603, 318020, 301636, 301639, 301643, 277071, 285265, 399955, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 277106, 121458, 170618, 170619, 309885, 309888, 277122, 227975, 285320, 277128, 301706, 318092, 326285, 318094, 334476, 277136, 277139, 227992, 285340, 318108, 227998, 318110, 137889, 383658, 285357, 318128, 277170, 342707, 154292, 277173, 293555, 318132, 285368, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 137946, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 285474, 293666, 228135, 318248, 277291, 293677, 318253, 285489, 293685, 285494, 301880, 285499, 301884, 293696, 310080, 277314, 277317, 277322, 277329, 162643, 310100, 301911, 301913, 277337, 301921, 400236, 236397, 162671, 326514, 310134, 277368, 236408, 15224, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 310179, 293798, 293802, 236460, 277426, 293811, 293817, 293820, 203715, 326603, 293849, 293861, 228327, 228328, 228330, 318442, 228332, 277486, 326638, 318450, 293877, 285686, 302073, 285690, 244731, 293882, 302075, 121850, 293887, 277504, 277507, 277511, 277519, 293908, 277526, 293917, 293939, 318516, 277561, 277564, 7232, 310336, 293956, 277573, 228422, 310344, 277577, 293960, 277583, 203857, 293971, 310359, 236632, 277594, 138332, 277598, 285792, 277601, 203872, 310374, 203879, 277608, 310376, 228460, 318573, 203886, 187509, 285815, 285817, 367737, 285821, 302205, 285824, 285831, 253064, 302218, 285835, 294026, 162964, 384148, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 285862, 277671, 302248, 64682, 277678, 228526, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 228617, 138505, 318742, 204067, 277798, 130345, 277801, 113964, 285997, 277804, 277807, 285999, 113969, 277811, 318773, 277816, 318776, 286010, 277819, 294204, 277822, 417086, 286016, 294211, 302403, 277832, 384328, 277836, 277839, 326991, 277842, 277847, 277850, 179547, 277853, 146784, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 310659, 277892, 294276, 327046, 277894, 253320, 310665, 277898, 318858, 351619, 277903, 310672, 277905, 351633, 277908, 277917, 277921, 310689, 277923, 130468, 228776, 277928, 277932, 310703, 277937, 130486, 310710, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 64966, 245191, 163272, 277959, 302534, 310727, 292968, 302541, 277966, 302543, 277963, 310737, 277971, 277975, 286169, 228825, 163290, 277978, 277981, 310749, 277984, 310755, 277989, 277991, 187880, 277995, 286188, 310764, 278000, 278003, 310772, 228851, 278006, 212472, 278009, 40440, 286203, 40443, 228864, 286214, 228871, 302603, 65038, 302614, 286233, 302617, 286240, 146977, 187939, 294435, 40484, 286246, 294439, 286248, 278057, 294440, 294443, 40486, 294445, 40488, 40491, 310831, 212538, 40507, 40511, 40513, 228933, 40521, 286283, 40525, 40527, 228944, 212560, 400976, 40533, 147032, 40537, 278109, 40541, 40544, 40548, 40550, 286312, 286313, 40552, 40554, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 278150, 310925, 286354, 278163, 302740, 122517, 278168, 327333, 229030, 212648, 278188, 302764, 278192, 319153, 278196, 319171, 302789, 294599, 278216, 294601, 302793, 278227, 229076, 286420, 319187, 286425, 319194, 278235, 301163, 229086, 278238, 286432, 294625, 294634, 302838, 319226, 286460, 171774, 278274, 302852, 278277, 302854, 311048, 352008, 294664, 319243, 311053, 302862, 294682, 278306, 188199, 294701, 278320, 319280, 319290, 229192, 302925, 188247, 237409, 294776, 360317, 294785, 327554, 40840, 40851, 294803, 188312, 294811, 319390, 294817, 40865, 319394, 294821, 180142, 294831, 188340, 40886, 319419, 294844, 294847, 309352, 393177, 294876, 294879, 294883, 294890, 311279, 278513, 237555, 278516, 311283, 278519, 237562 ]
1cfd29c28ebbd89c853cda8492b6c0834e7e966b
3ab0ac6677d4dee31b23254d2d7fc16235ef2dc8
/testProject/testProject/TabBars/ProfileVC.swift
b190ec228b85caee1f2e21c671ba03cc90532f6b
[]
no_license
kovacsmarci96/WorkTracker
adc4d3cc451fe10f1a221093b2d432ae2f2c2c61
422267de1da373246a5b6cb1524a9b871675422a
refs/heads/master
2023-01-22T01:02:43.327353
2020-11-29T13:38:15
2020-11-29T13:38:15
316,958,680
0
0
null
null
null
null
UTF-8
Swift
false
false
2,916
swift
// // ProfileVC.swift // testProject // // Created by Kovács Márton on 2020. 11. 26.. // import UIKit import Charts class ProfileVC: UIViewController { //IBOutlets @IBOutlet weak var nameLabel: UILabel! @IBOutlet weak var emailLabel: UILabel! @IBOutlet weak var chooser: UITextField! @IBOutlet weak var viewForChart: UIView! //Variables var filteringOptions = ["All", "Today", "This week", "This month"] var user = User() var tabBar = TabBarController() var pickerView = UIPickerView() let barChart = BarChartView() var filteredWorks = [Work]() var taskWorks = [String : [Work]]() var taskHours = [String : Double]() var userWorks = [Work]() var userTasks = [Task]() var projects = [Project]() var tasks = [Task]() var works = [Work]() override func viewDidLoad() { super.viewDidLoad() setupTabBar() setupPickerView() setupChooser() nameLabel.text = user.name emailLabel.text = user.email } override func viewWillAppear(_ animated: Bool) { clear() tabBar.navigationItem.title = "Profile" let filter = chooser.text! let semaphore = DispatchSemaphore(value: 0) let dispatchQueue = DispatchQueue.global(qos: .background) dispatchQueue.async { self.getAllProjects(self.user.token!, semaphore) semaphore.wait() self.fetchTasks(semaphore, filter) DispatchQueue.main.asyncAfter(deadline: .now() + 0.7) { self.countHours() self.viewDidLayoutSubviews() self.barChart.animate(xAxisDuration: 1.0, yAxisDuration: 1.0, easingOption: .easeInBack) } } } override func viewDidLayoutSubviews() { setupBarChart() } func clear() { filteredWorks.removeAll() taskWorks.removeAll() taskHours.removeAll() userWorks.removeAll() userTasks.removeAll() projects.removeAll() tasks.removeAll() works.removeAll() } //Setup TabBar func setupTabBar() { user = tabBar.user tabBar = self.tabBarController as! TabBarController tabBar.navigationController?.navigationBar.prefersLargeTitles = true tabBar.navigationItem.largeTitleDisplayMode = .automatic } //Setup PickerView func setupPickerView() { pickerView.delegate = self pickerView.dataSource = self } // MARK: - Setup labels func setupLabels() { nameLabel.text = user.name emailLabel.text = user.email } //Setup Chooser func setupChooser() { chooser.tintColor = .clear chooser.text = "All" chooser.inputView = pickerView } }
[ -1 ]
99deff83238f2e644108967d7dad7579e47cc00d
67084fa50470ecbf367cf96e62ae51bc4373ece5
/iOS-txtreader/StreamReader.swift
273842ef710ced58478b2475eccffeba59aecac3
[]
no_license
sesang06/iOS-txtreader
42a30e53de5c8a2464ad1e662feb9682c3209934
b3ed5a0b38298e245e82d8d9430d54bf0ca6f32f
refs/heads/master
2021-09-29T14:29:16.148140
2018-11-25T12:27:54
2018-11-25T12:27:54
145,731,297
0
0
null
null
null
null
UTF-8
Swift
false
false
2,659
swift
// // StreamReader.swift // iOS-txtreader // // Created by 조세상 on 2018. 8. 25.. // Copyright © 2018년 조세상. All rights reserved. // import UIKit import Foundation class StreamReader { let encoding: String.Encoding let chunkSize: Int let fileHandle: FileHandle var buffer: Data let delimPattern : Data var isAtEOF: Bool = false var fileSize : UInt64 init?(url: URL, delimeter: String = "\n", encoding: String.Encoding = .utf8, chunkSize: Int = 4096) { guard let fileHandle = try? FileHandle(forReadingFrom: url) else { return nil } guard let attr = try? FileManager.default.attributesOfItem(atPath: url.path) else { return nil } self.fileSize = attr[FileAttributeKey.size] as! UInt64 self.fileHandle = fileHandle self.chunkSize = chunkSize self.encoding = encoding buffer = Data(capacity: chunkSize) delimPattern = delimeter.data(using: .utf8)! } deinit { fileHandle.closeFile() } func totalPage(amount : Int ) -> Int { let total = Int(fileSize) if (total % amount == 0){ return total / amount }else { return total / amount + 1 } } func rewind() { fileHandle.seek(toFileOffset: 0) buffer.removeAll(keepingCapacity: true) isAtEOF = false } /** */ func nextContent(offset : Int, amount : Int) -> String? { fileHandle.seek(toFileOffset: UInt64(offset * amount)) let tempData = fileHandle.readData(ofLength: amount) if tempData.count == 0 { isAtEOF = true return nil } let line = String(data : tempData, encoding : encoding) return line } func nextLine() -> String? { if isAtEOF { return nil } repeat { if let range = buffer.range(of: delimPattern, options: [], in: buffer.startIndex..<buffer.endIndex) { let subData = buffer.subdata(in: buffer.startIndex..<range.lowerBound) let line = String(data: subData, encoding: encoding) buffer.replaceSubrange(buffer.startIndex..<range.upperBound, with: []) return line } else { let tempData = fileHandle.readData(ofLength: chunkSize) if tempData.count == 0 { isAtEOF = true return (buffer.count > 0) ? String(data: buffer, encoding: encoding) : nil } buffer.append(tempData) } } while true } }
[ 67222 ]
90eff6ab2884538aabb238b452b65ef73577eca6
31295fd994cd902e6e32fa09456c67e9e5dd6c14
/Eisenhower Todo/Signup/Configurator/SignupInitializer.swift
bd34193682fa7f753232be762776de4e16b2db17
[ "MIT" ]
permissive
gsabatie/EisenhowerTodoApp
ac54b4a32ead7f8e558563100448665f56539854
723e7ab18cb0e2978c66b3217cdb025d58de5022
refs/heads/master
2021-04-27T05:20:30.957637
2018-05-20T12:31:10
2018-05-20T12:31:10
122,596,075
3
0
MIT
2018-05-20T12:13:51
2018-02-23T08:47:45
Swift
UTF-8
Swift
false
false
523
swift
// // SignupSignupInitializer.swift // EisenhowerTodoApp // // Created by Guillaume Sabatie on 25/03/2018. // Copyright © 2018 EiseinhowerAppTeam. All rights reserved. // import UIKit class SignupModuleInitializer: NSObject { //Connect with object on storyboard @IBOutlet weak var signupViewController: SignupViewController! override func awakeFromNib() { let configurator = SignupModuleConfigurator() configurator.configureModuleForViewInput(viewInput: signupViewController) } }
[ -1 ]
607c956f2210d27e2a79150ce3e24918b6855b9e
fa019e2db1eb84aafb172101e30166ef49eb4870
/Sources/Extensions/RLP/Transaction+RLP.swift
d6ae7bc32104898b25671a38cf25871ce9b515a5
[]
no_license
gerald-aguilar/mew-wallet-ios-kit
3ee7d8750824ef354e1eb3a1535033cb37254bb4
75f26371979964e635f97297198f7a929ce4b5ac
refs/heads/main
2023-08-22T09:20:34.209792
2021-10-18T22:30:07
2021-10-18T22:30:07
null
0
0
null
null
null
null
UTF-8
Swift
false
false
316
swift
// // Transaction+RLP.swift // MEWwalletKit // // Created by Mikhail Nikanorov on 4/25/19. // Copyright © 2019 MyEtherWallet Inc. All rights reserved. // import Foundation import BigInt extension Transaction: RLP { func rlpEncode(offset: UInt8? = nil) -> Data? { return self.rlpData().rlpEncode() } }
[ -1 ]
a03b3b8a06b3c8b0730458658766d1d9bfa45597
806fa72fd1f601c283f028fad100881ab053ad59
/Sources/Graphaello/Processing/Code Generstion/CodeTransformable/Context+render.swift
60cccbe78d67ba4d3526655443a1de5b04a4de85
[ "MIT" ]
permissive
nerdsupremacist/Graphaello
291485d85edfd40871c8f5a171608b4f131d89bb
83fb6106f222603c5ec3c539fdd859b6539ca89e
refs/heads/develop
2023-06-01T01:44:01.586570
2022-06-27T16:18:40
2022-06-27T16:18:40
242,351,920
505
22
MIT
2022-06-27T16:18:42
2020-02-22T14:06:25
Swift
UTF-8
Swift
false
false
351
swift
import Foundation import Stencil extension Stencil.Context { func render(template: String, context dictionary: [String : Any]) throws -> String { return try push(dictionary: dictionary) { let template = try environment.loadTemplate(name: template) return try template.render(flatten()) } } }
[ -1 ]
258f84a494ef037f9735ba75661e66c7d1b0c274
071dbf6881603b392c8250ed171d4b80cf84b2c5
/Designer News App/ViewController.swift
afcc68ce0136b1d09660475479496829e897b5ec
[]
no_license
NovaTechnologies/Designer-News-App
f1c0dc8060139b16d03ccde0028593d8ca150889
d37397cb167cbc4a454202a30fbf4e254c13111b
refs/heads/master
2021-01-02T08:19:11.858678
2014-11-05T18:15:35
2014-11-05T18:15:35
null
0
0
null
null
null
null
UTF-8
Swift
false
false
515
swift
// // ViewController.swift // Designer News App // // Created by P on 23/09/14. // Copyright (c) 2014 com.novatechnologies. All rights reserved. // import UIKit class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
[ 215562, 287243, 295460, 286249, 286775, 226878, 293961, 226896, 212561, 276054, 237655, 277602, 276580, 309353, 311913, 277612, 276597, 276087, 188027, 280710, 280219, 299165, 225955, 326311, 209577, 302256, 277171, 280760, 299709, 283839, 277696, 276167, 277192, 307410, 278752, 290020, 291556, 120054, 230147, 226055, 369434, 329499, 276256, 315170, 304933, 289578, 288579, 293700, 298842, 241499, 298843, 311645, 296813, 276849, 315250, 275842, 224643, 313733, 306577, 279442, 306578, 275358, 288165, 289196, 370093, 289204, 337336, 298936, 276412, 299973, 280015, 301012, 301016, 280028, 280029, 280030, 294889, 277487, 308721, 227315, 296436 ]
93dfe6b21a121299b2ea89e6e87192cea9f1ed9b
2318027b11ba1bf8284d6a40b7407bf6930f2eda
/Demo/Demo/ViewController.swift
d57b356ebacdbbb3cf61ca24045cdf8f67d8ab37
[ "MIT" ]
permissive
douwantech/SwiftShareBubbles
d0385354d399f473e5cd1f94fccf77d0447f5ad6
7eb51f522f26c943c62cb73aa8cc60f85d4100c2
refs/heads/master
2022-03-09T18:28:21.591066
2019-11-21T10:03:35
2019-11-21T10:03:35
null
0
0
null
null
null
null
UTF-8
Swift
false
false
2,197
swift
// // ViewController.swift // Demo // // Created by Fujiki Takeshi on 2017/03/10. // Copyright © 2017年 com.takecian. All rights reserved. // import UIKit import SwiftShareBubbles class ViewController: UIViewController, SwiftShareBubblesDelegate { var bubbles: SwiftShareBubbles? let customBubbleId = 100 override func viewDidLoad() { super.viewDidLoad() bubbles = SwiftShareBubbles(point: CGPoint(x: view.frame.width / 2, y: view.frame.height / 2), radius: 100, in: view) bubbles?.showBubbleTypes = [Bubble.facebook, Bubble.twitter, Bubble.safari] let customAttribute = ShareAttirbute(bubbleId: customBubbleId, icon: UIImage(named: "Custom")!, backgroundColor: UIColor.white) bubbles?.customBubbleAttributes = [customAttribute] bubbles?.delegate = self } func bubblesTapped(bubbles: SwiftShareBubbles, bubbleId: Int) { if let bubble = Bubble(rawValue: bubbleId) { print("\(bubble)") switch bubble { case .facebook: let alert = UIAlertController(title: nil, message: "Open facebook using SDK", preferredStyle: .alert) alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil)) present(alert, animated: true, completion: nil) case .twitter: let alert = UIAlertController(title: nil, message: "Open twitter using SDK", preferredStyle: .alert) alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil)) present(alert, animated: true, completion: nil) default: break } } else { if customBubbleId == bubbleId { let alert = UIAlertController(title: nil, message: "Add custom id handling", preferredStyle: .alert) alert.addAction(UIAlertAction(title: "OK", style: .default, handler: nil)) present(alert, animated: true, completion: nil) } } } func bubblesDidHide(bubbles: SwiftShareBubbles) { } @IBAction func buttonTapped(_ sender: Any) { bubbles?.show() } }
[ -1 ]
3e0049e4843133fac185ca018e3c5a2ae74bb122
db02e506e4142ed36ec52e29a6fe8034fd284f7b
/YellowPod/YellowPod/Data/Remote/Errors/SerializationError.swift
5a7f7bbc820bfedd2fd2774660e9fb06ccda11fa
[]
no_license
yellowme/base-ios
f24cea55220684bb2e099940a6cea4a26cf3a0cd
225ff6d3b56c73e69011fb10bf72fd8743445992
refs/heads/master
2018-11-14T20:39:53.699854
2018-11-01T02:43:02
2018-11-01T02:43:02
103,175,370
3
1
null
2018-07-19T22:14:18
2017-09-11T18:53:09
Swift
UTF-8
Swift
false
false
545
swift
// // Networking.swift // YellowPod // // Created by Luis Burgos on 11/25/17. // Copyright © 2017 YellowPod. All rights reserved. // import Foundation /** Serialization throwing error helper during JSON parsing */ enum SerializationError: Error { case missing(String) case invalid(String, Any) var message: String { switch self { case .missing(let error): return "Missing parameter: \(error)" case .invalid(let error, _): return "Invalid data \(error)" } } }
[ -1 ]
798a0a25650e36a9af5712d5e00ff525a51f3c8e
6034192cf628d3185a5d4c08c489dc206ddc0140
/DesignModel/DesignModel/AppDelegate.swift
292df56a121de9e0e4a54ebecfe061e8608d0444
[]
no_license
housenkui/swift2.3
6e0857f56fd49de986c3fe1eeb632affb0fa90a8
1a7381c081d6d518d53fe0eb1b08b71f14f2252e
refs/heads/master
2021-01-23T00:52:43.091989
2017-07-03T01:50:50
2017-07-03T01:50:50
92,852,677
0
0
null
null
null
null
UTF-8
Swift
false
false
2,179
swift
// // AppDelegate.swift // DesignModel // // Created by 史蒂夫 on 2017/5/26. // Copyright © 2017年 小虎金融. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
[ 229380, 229383, 229385, 278539, 229388, 294924, 278542, 229391, 327695, 278545, 229394, 278548, 229397, 229399, 229402, 352284, 229405, 278556, 278559, 229408, 278564, 294950, 229415, 229417, 327722, 237613, 229422, 360496, 229426, 237618, 229428, 311349, 286774, 319544, 204856, 229432, 286776, 286778, 352318, 286791, 237640, 278605, 286797, 311375, 163920, 237646, 196692, 319573, 311383, 278623, 278626, 319590, 311400, 278635, 303212, 278639, 131192, 278648, 237693, 303230, 327814, 131209, 303241, 417930, 303244, 311436, 319633, 286873, 286876, 311460, 311469, 32944, 327862, 286906, 327866, 180413, 286910, 131264, 286916, 295110, 286922, 286924, 286926, 319694, 286928, 131281, 278743, 278747, 295133, 155872, 319716, 237807, 303345, 286962, 303347, 131314, 229622, 327930, 278781, 278783, 278785, 237826, 319751, 278792, 286987, 319757, 311569, 286999, 319770, 287003, 287006, 287009, 287012, 287014, 287016, 287019, 311598, 287023, 262448, 311601, 295220, 287032, 155966, 319809, 319810, 278849, 319814, 311623, 319818, 311628, 229709, 319822, 287054, 278865, 229717, 196963, 196969, 139638, 213367, 106872, 319872, 311683, 319879, 311693, 65943, 319898, 311719, 278952, 139689, 278957, 311728, 278967, 180668, 311741, 278975, 319938, 278980, 98756, 278983, 319945, 278986, 319947, 278990, 278994, 311767, 279003, 279006, 188895, 172512, 287202, 279010, 279015, 172520, 319978, 279020, 172526, 311791, 279023, 172529, 279027, 319989, 180727, 164343, 279035, 311804, 287230, 279040, 303617, 287234, 279045, 172550, 303623, 320007, 287238, 172552, 279051, 172558, 279055, 303632, 279058, 303637, 279063, 279067, 172572, 279072, 172577, 295459, 172581, 295461, 279082, 311850, 279084, 172591, 172598, 279095, 172607, 172609, 172612, 377413, 172614, 213575, 172618, 303690, 33357, 287309, 303696, 279124, 172634, 262752, 254563, 172644, 311911, 189034, 295533, 172655, 172656, 352880, 189039, 295538, 172660, 189040, 189044, 287349, 287355, 287360, 295553, 172675, 295557, 311942, 303751, 287365, 352905, 311946, 279178, 287371, 311951, 287377, 172691, 287381, 311957, 221850, 287386, 230045, 287390, 303773, 164509, 172705, 287394, 172702, 303780, 172707, 287398, 205479, 279208, 287400, 172714, 295595, 279212, 189102, 172721, 287409, 66227, 303797, 189114, 287419, 303804, 328381, 287423, 328384, 279231, 287427, 312005, 312006, 107212, 172748, 287436, 172751, 295633, 172755, 303827, 279255, 172760, 287450, 303835, 279258, 189149, 303838, 213724, 279267, 312035, 295654, 279272, 312048, 230128, 312050, 230131, 189169, 205564, 303871, 230146, 328453, 295685, 230154, 33548, 312077, 295695, 295701, 230169, 369433, 295707, 328476, 295710, 230175, 303914, 279340, 205613, 279353, 230202, 312124, 328508, 222018, 295755, 377676, 148302, 287569, 303959, 230237, 279390, 230241, 279394, 303976, 336744, 303981, 303985, 303987, 328563, 279413, 303991, 303997, 295806, 295808, 304005, 295813, 304007, 320391, 213895, 304009, 304011, 230284, 304013, 279438, 189325, 295822, 189329, 213902, 189331, 304019, 58262, 304023, 279452, 234648, 410526, 279461, 279462, 304042, 213931, 304055, 230327, 287675, 197564, 230334, 304063, 304065, 213954, 189378, 156612, 295873, 213963, 312272, 304084, 304090, 320481, 304106, 320490, 312302, 328687, 320496, 304114, 295928, 320505, 312321, 295945, 295949, 230413, 197645, 320528, 140312, 295961, 238620, 197663, 304164, 304170, 304175, 238641, 312374, 238652, 238655, 230465, 238658, 296004, 132165, 336964, 205895, 320584, 238666, 296021, 402518, 336987, 230497, 296036, 361576, 296040, 205931, 279661, 205934, 164973, 312432, 279669, 337018, 189562, 279679, 304258, 279683, 222340, 66690, 205968, 296084, 238745, 304285, 238756, 205991, 222377, 165035, 337067, 165038, 238766, 230576, 238770, 304311, 230592, 312518, 279750, 230600, 230607, 148690, 320727, 279769, 304348, 279777, 304354, 296163, 320740, 279781, 304360, 320748, 279788, 279790, 304370, 296189, 320771, 312585, 296205, 230674, 320786, 230677, 296213, 296215, 320792, 230681, 230679, 214294, 230689, 173350, 312622, 296243, 312630, 222522, 296253, 222525, 296255, 312639, 230718, 296259, 378181, 296262, 230727, 296264, 238919, 320840, 296267, 296271, 222545, 230739, 312663, 337244, 222556, 230752, 312676, 230760, 173418, 410987, 230763, 148843, 230768, 296305, 312692, 230773, 304505, 181626, 304506, 279929, 181631, 148865, 312711, 312712, 296331, 288140, 288144, 230800, 304533, 337306, 288154, 288160, 288162, 288164, 279975, 304555, 370092, 279983, 173488, 288176, 279985, 312755, 296373, 312759, 337335, 288185, 279991, 222652, 312766, 173507, 296389, 222665, 230860, 312783, 288208, 230865, 288210, 370130, 288212, 222676, 148946, 288214, 239064, 329177, 288217, 280027, 288220, 288218, 239070, 288224, 280034, 288226, 280036, 288229, 280038, 288230, 288232, 370146, 288234, 320998, 288236, 288238, 288240, 288242, 296435, 288244, 288250, 148990, 321022, 206336, 402942, 296446, 296450, 230916, 230919, 214535, 304651, 370187, 304653, 230923, 402969, 230940, 222752, 108066, 296486, 296488, 157229, 239152, 230961, 157236, 288320, 288325, 124489, 280140, 280145, 288338, 280149, 288344, 280152, 239194, 280158, 403039, 181854, 370272, 239202, 370279, 312938, 280183, 280185, 280188, 280191, 116354, 280194, 280208, 280211, 288408, 280218, 280222, 419489, 190118, 321195, 296622, 321200, 337585, 296626, 296634, 296637, 419522, 313027, 280260, 419525, 206536, 280264, 206539, 206541, 206543, 263888, 280276, 313044, 321239, 280283, 18140, 313052, 288478, 313055, 419555, 321252, 313066, 280302, 288494, 280304, 313073, 419570, 288499, 321266, 288502, 280314, 288510, 67330, 280324, 198405, 288519, 280331, 198416, 280337, 296723, 116503, 321304, 329498, 296731, 321311, 313121, 313123, 304932, 321316, 280363, 141101, 165678, 280375, 321336, 296767, 288576, 345921, 280388, 337732, 304968, 280393, 280402, 173907, 313176, 42842, 280419, 321381, 296809, 296812, 313201, 1920, 255873, 305028, 280454, 247688, 280464, 124817, 280468, 239510, 280473, 124827, 214940, 247709, 214944, 280487, 313258, 321458, 296883, 124853, 214966, 10170, 296890, 288700, 296894, 190403, 296900, 280515, 337862, 165831, 280521, 231379, 296921, 354265, 354270, 239586, 313320, 354281, 231404, 124913, 165876, 321528, 313340, 239612, 288764, 239617, 313347, 288773, 313358, 305176, 321560, 313371, 354338, 305191, 223273, 313386, 354348, 124978, 215090, 124980, 288824, 288826, 321595, 313406, 288831, 288836, 67654, 280651, 354382, 288848, 280658, 215123, 354390, 288855, 288859, 280669, 313438, 149599, 280671, 149601, 321634, 149603, 223327, 329830, 280681, 313451, 223341, 280687, 215154, 313458, 280691, 149618, 313464, 329850, 321659, 280702, 288895, 321670, 215175, 141446, 288909, 141455, 141459, 280725, 313498, 100520, 288936, 280747, 288940, 280755, 288947, 321717, 280759, 280764, 280769, 280771, 280774, 280776, 321740, 313548, 280783, 280786, 280788, 313557, 280793, 280796, 280798, 338147, 280804, 280807, 157930, 280811, 280817, 125171, 157940, 280819, 182517, 280823, 280825, 280827, 280830, 280831, 280833, 125187, 280835, 125191, 125207, 125209, 321817, 125218, 321842, 223539, 125239, 280888, 305464, 280891, 289087, 280897, 280900, 239944, 305480, 280906, 239947, 305485, 305489, 379218, 280919, 248153, 215387, 354653, 354656, 313700, 313705, 280937, 190832, 280946, 223606, 313720, 280956, 239997, 280959, 313731, 240011, 199051, 289166, 240017, 297363, 190868, 297365, 297368, 297372, 141725, 297377, 289186, 297391, 289201, 240052, 289207, 305594, 289210, 281024, 289218, 289221, 289227, 436684, 281045, 281047, 215526, 166378, 305647, 281075, 174580, 240124, 281084, 305662, 305664, 240129, 305666, 305668, 223749, 330244, 281095, 223752, 338440, 150025, 240132, 223757, 281102, 223763, 223765, 281113, 322074, 281116, 281121, 182819, 281127, 281135, 150066, 158262, 158266, 289342, 281154, 322115, 158283, 281163, 281179, 338528, 338532, 281190, 199273, 281196, 158317, 19053, 313973, 297594, 281210, 158347, 264845, 182926, 133776, 182929, 314003, 117398, 314007, 289436, 174754, 330404, 289448, 133801, 174764, 314029, 314033, 240309, 133817, 314045, 314047, 314051, 199364, 297671, 158409, 256716, 289493, 363234, 289513, 289522, 289525, 289532, 322303, 289537, 322310, 264969, 322314, 322318, 281361, 281372, 322341, 215850, 281388, 289593, 281401, 289601, 281410, 281413, 281414, 240458, 281420, 240468, 281430, 322393, 297818, 281435, 281438, 281442, 174955, 224110, 207733, 207737, 183172, 158596, 338823, 322440, 314249, 240519, 183184, 142226, 240535, 289687, 224151, 297883, 289694, 289696, 289700, 289712, 281529, 289724, 52163, 183260, 420829, 281567, 289762, 322534, 297961, 183277, 281581, 322550, 134142, 322563, 314372, 330764, 175134, 322599, 322610, 314421, 281654, 314427, 314433, 207937, 314441, 207949, 322642, 314456, 281691, 314461, 281702, 281704, 314474, 281708, 281711, 289912, 248995, 306341, 306344, 306347, 322734, 306354, 142531, 199877, 289991, 306377, 289997, 249045, 363742, 363745, 298216, 330988, 126190, 216303, 322801, 388350, 257302, 363802, 199976, 199978, 314671, 298292, 298294, 257334, 216376, 298306, 380226, 224584, 224587, 224594, 216404, 306517, 150870, 314714, 224603, 159068, 314718, 265568, 314723, 281960, 150890, 306539, 314732, 314736, 290161, 216436, 306549, 298358, 314743, 306552, 306555, 314747, 298365, 290171, 290174, 224641, 281987, 314756, 298372, 281990, 265604, 298377, 314763, 142733, 298381, 314768, 224657, 306581, 314773, 314779, 314785, 314793, 282025, 282027, 241068, 241070, 241072, 282034, 241077, 150966, 298424, 306618, 282044, 323015, 306635, 306640, 290263, 290270, 290275, 339431, 282089, 191985, 282098, 290291, 282101, 241142, 191992, 290298, 151036, 290302, 282111, 290305, 175621, 192008, 323084, 257550, 282127, 290321, 282130, 323090, 282133, 290325, 241175, 290328, 282137, 290332, 241181, 282142, 282144, 290344, 306731, 290349, 290351, 290356, 28219, 282186, 224849, 282195, 282199, 282201, 306778, 159324, 159330, 314979, 298598, 323176, 224875, 241260, 323181, 257658, 315016, 282249, 290445, 282255, 282261, 175770, 298651, 323229, 282269, 298655, 323231, 61092, 282277, 306856, 196133, 282295, 323260, 282300, 323266, 282310, 323273, 282319, 306897, 241362, 306904, 282328, 298714, 52959, 216801, 282337, 241380, 216806, 323304, 282345, 12011, 282356, 323318, 282364, 282367, 306945, 241412, 323333, 282376, 216842, 323345, 282388, 323349, 282392, 184090, 315167, 315169, 282402, 315174, 323367, 241448, 315176, 241450, 282410, 306988, 306991, 315184, 323376, 315190, 241464, 159545, 282425, 307009, 413506, 241475, 307012, 298822, 315211, 282446, 307027, 315221, 323414, 315223, 241496, 241498, 307035, 307040, 110433, 282465, 241509, 110438, 298860, 110445, 282478, 315249, 110450, 315251, 282481, 315253, 315255, 339838, 315267, 282499, 315269, 241544, 282505, 241546, 241548, 298896, 298898, 282514, 241556, 298901, 44948, 241560, 282520, 241563, 241565, 241567, 241569, 282531, 241574, 282537, 298922, 36779, 241581, 282542, 241583, 323504, 241586, 282547, 241588, 290739, 241590, 241592, 241598, 290751, 241600, 241605, 151495, 241610, 298975, 241632, 298984, 241640, 241643, 298988, 241646, 241649, 241652, 323574, 290807, 241661, 299006, 282623, 315396, 241669, 315397, 282632, 307211, 282639, 290835, 282645, 241693, 282654, 241701, 102438, 217127, 282669, 323630, 282681, 290877, 282687, 159811, 315463, 315466, 192589, 307278, 192596, 176213, 307287, 315482, 217179, 315483, 192605, 233567, 200801, 299105, 217188, 299109, 307303, 315495, 356457, 307307, 45163, 315502, 192624, 307314, 323700, 299126, 233591, 299136, 307329, 315524, 307338, 233613, 241813, 307352, 299164, 241821, 184479, 299167, 184481, 315557, 184486, 307370, 307372, 184492, 307374, 307376, 299185, 323763, 176311, 299191, 307385, 307386, 258235, 307388, 176316, 307390, 184503, 299200, 184512, 307394, 307396, 299204, 184518, 307399, 323784, 307409, 307411, 176343, 299225, 233701, 307432, 184572, 282881, 184579, 282893, 323854, 291089, 282906, 291104, 233766, 176435, 307508, 315701, 332086, 307510, 307512, 168245, 307515, 307518, 282942, 282947, 323917, 110926, 282957, 233808, 323921, 315733, 323926, 233815, 276052, 315739, 323932, 299357, 242018, 242024, 299373, 315757, 250231, 242043, 315771, 299388, 299391, 291202, 299398, 242057, 291212, 299405, 291222, 315801, 283033, 242075, 291226, 291231, 61855, 283042, 291238, 291241, 127403, 127405, 127407, 291247, 299444, 127413, 283062, 291254, 127417, 291260, 283069, 127421, 127424, 299457, 127429, 315856, 176592, 127440, 315860, 176597, 283095, 127447, 299481, 127449, 176605, 242143, 127455, 127457, 291299, 340454, 127463, 242152, 291305, 127466, 176620, 127469, 127474, 291314, 291317, 135672, 127480, 233979, 291323, 127485, 291330, 127490, 283142, 127494, 127497, 233994, 135689, 127500, 291341, 233998, 127506, 234003, 127509, 234006, 127511, 152087, 283161, 242202, 234010, 135707, 135710, 242206, 242208, 291361, 242220, 291378, 152118, 234038, 234041, 315961, 70213, 242250, 111193, 242275, 299620, 242279, 168562, 184952, 135805, 135808, 291456, 373383, 299655, 135820, 316051, 225941, 316054, 299672, 135834, 373404, 299677, 225948, 135839, 299680, 225954, 135844, 299684, 242343, 209576, 242345, 373421, 135870, 135873, 135876, 135879, 299720, 299723, 299726, 225998, 226002, 119509, 226005, 226008, 242396, 299740, 201444, 299750, 283368, 234219, 283372, 185074, 226037, 283382, 316151, 234231, 234236, 226045, 242431, 234239, 209665, 234242, 299778, 242436, 226053, 234246, 226056, 234248, 291593, 242443, 234252, 242445, 234254, 291601, 242450, 234258, 242452, 234261, 201496, 234264, 234266, 234269, 283421, 234272, 234274, 152355, 234278, 299814, 283432, 234281, 234284, 234287, 283440, 185138, 242483, 234292, 234296, 234298, 160572, 283452, 234302, 234307, 242499, 234309, 316233, 234313, 316235, 234316, 283468, 242511, 234319, 234321, 234324, 201557, 185173, 234329, 234333, 308063, 234336, 234338, 349027, 242530, 234341, 234344, 234347, 177004, 234350, 324464, 234353, 152435, 177011, 234356, 234358, 234362, 226171, 234364, 291711, 234368, 234370, 201603, 291714, 234373, 316294, 226182, 234375, 308105, 226185, 234379, 324490, 291716, 234384, 234388, 234390, 324504, 234393, 209818, 308123, 324508, 234396, 291742, 226200, 234398, 234401, 291747, 291748, 234405, 291750, 234407, 324520, 324518, 234410, 291754, 291756, 324522, 226220, 324527, 291760, 234417, 201650, 324531, 234414, 234422, 226230, 324536, 275384, 234428, 291773, 234431, 242623, 324544, 324546, 234434, 324548, 234437, 226245, 234439, 226239, 234443, 291788, 234446, 275406, 193486, 234449, 316370, 193488, 234452, 234455, 234459, 234461, 234464, 234467, 234470, 168935, 5096, 324585, 234475, 234478, 316400, 234481, 316403, 234484, 234485, 324599, 234487, 234490, 234493, 234496, 316416, 234501, 275462, 308231, 234504, 234507, 234510, 234515, 300054, 234519, 316439, 234520, 234523, 234526, 234528, 300066, 234532, 300069, 234535, 234537, 234540, 144430, 234543, 234546, 275508, 234549, 300085, 300088, 234553, 234556, 234558, 316479, 234561, 308291, 316483, 234563, 160835, 234568, 234570, 316491, 300108, 234572, 234574, 300115, 234580, 234581, 242777, 234585, 275545, 234590, 234593, 234595, 300133, 234597, 234601, 300139, 234605, 160879, 234607, 275569, 234610, 316530, 300148, 234614, 398455, 144506, 234618, 275579, 234620, 234623, 226433, 234627, 275588, 234629, 242822, 234634, 234636, 177293, 234640, 275602, 234643, 308373, 226453, 234647, 275606, 275608, 234650, 308379, 324757, 234653, 300189, 119967, 324766, 324768, 283805, 234657, 242852, 234661, 283813, 300197, 234664, 177318, 275626, 234667, 316596, 308414, 300223, 234687, 300226, 308418, 283844, 300229, 308420, 308422, 226500, 234692, 283850, 300234, 300238, 300241, 316625, 300243, 300245, 316630, 300248, 300253, 300256, 300258, 300260, 234726, 300263, 300265, 300267, 161003, 300270, 300272, 120053, 300278, 316663, 275703, 300284, 275710, 300287, 300289, 292097, 161027, 300292, 300294, 275719, 234760, 177419, 300299, 242957, 283917, 300301, 177424, 349451, 275725, 349464, 415009, 283939, 259367, 292143, 283951, 300344, 226617, 243003, 283963, 226628, 283973, 300357, 177482, 283983, 316758, 357722, 316766, 316768, 292192, 218464, 292197, 316774, 243046, 218473, 284010, 324978, 136562, 275834, 333178, 275836, 275840, 316803, 316806, 226696, 316811, 226699, 316814, 226703, 300433, 234899, 226709, 357783, 316824, 316826, 144796, 300448, 144807, 144810, 144812, 144814, 144820, 284084, 284087, 292279, 144826, 144828, 144830, 144832, 144835, 144837, 38342, 144839, 144841, 144844, 144847, 144852, 144855, 103899, 300507, 333280, 226787, 218597, 292329, 300523, 259565, 300527, 308720, 259567, 226802, 292338, 316917, 292343, 308727, 300537, 316933, 316947, 308757, 308762, 284191, 316959, 284194, 284196, 235045, 284199, 284204, 284206, 284209, 284211, 284213, 308790, 284215, 316983, 194103, 284218, 194101, 226877, 292414, 284223, 284226, 284228, 292421, 226886, 284231, 128584, 243268, 284234, 366155, 317004, 276043, 284238, 226895, 284241, 292433, 284243, 300628, 284245, 194130, 284247, 317015, 235097, 243290, 276053, 284249, 284251, 300638, 284253, 284255, 243293, 284258, 292452, 292454, 284263, 177766, 284265, 292458, 284267, 292461, 284272, 284274, 276086, 284278, 292470, 292473, 284283, 276093, 284286, 292479, 284288, 292481, 284290, 325250, 284292, 292485, 325251, 276095, 276098, 284297, 317066, 284299, 317068, 276109, 284301, 284303, 284306, 276114, 284308, 284312, 284314, 284316, 276127, 284320, 284322, 284327, 284329, 317098, 284331, 276137, 284333, 284335, 284337, 284339, 300726, 284343, 284346, 284350, 358080, 276160, 284354, 358083, 276166, 284358, 358089, 284362, 276170, 276175, 284368, 276177, 284370, 358098, 284372, 317138, 284377, 276187, 284379, 284381, 284384, 358114, 284386, 358116, 276197, 317158, 358119, 284392, 325353, 358122, 284394, 284397, 358126, 284399, 358128, 276206, 358133, 358135, 276216, 358138, 300795, 358140, 284413, 358142, 358146, 317187, 284418, 317189, 317191, 284428, 300816, 300819, 317207, 284440, 300828, 300830, 276255, 325408, 300832, 300834, 317221, 227109, 358183, 186151, 276268, 300845, 243504, 300850, 284469, 276280, 325436, 358206, 276291, 366406, 276295, 300872, 153417, 292681, 358224, 284499, 276308, 284502, 317271, 178006, 276315, 292700, 284511, 317279, 227175, 292715, 300912, 284529, 292721, 300915, 284533, 292729, 317306, 284540, 292734, 325512, 169868, 276365, 358292, 284564, 317332, 399252, 284566, 350106, 284572, 276386, 284579, 276388, 358312, 284585, 317353, 276395, 292776, 292784, 276402, 358326, 161718, 276410, 276411, 358330, 276418, 276425, 301009, 301011, 301013, 292823, 301015, 301017, 358360, 292828, 276446, 153568, 276452, 292839, 276455, 350186, 292843, 276460, 292845, 276464, 227314, 350200, 325624, 276472, 317435, 276479, 276482, 350210, 276485, 317446, 178181, 276490, 350218, 292876, 350222, 317456, 276496, 317458, 178195, 243733, 243740, 317468, 317472, 325666, 243751, 292904, 276528, 178224, 243762, 309298, 325685, 325689, 235579, 325692, 235581, 178238, 276539, 276544, 243779, 284739, 325700, 292934, 243785, 276553, 350293, 350295, 309337, 194649, 227418, 350299, 350302, 227423, 194654, 178273, 309346, 194657, 309348, 350308, 309350, 227426, 309352, 350313, 309354, 301163, 350316, 194660, 227430, 276583, 276590, 350321, 284786, 276595, 301167, 350325, 227440, 350328, 292985, 301178, 350332, 292989, 301185, 292993, 350339, 317570, 317573, 350342, 350345, 350349, 301199, 317584, 325777, 350354, 350357, 350359, 350362, 350366, 276638, 284837, 153765, 350375, 350379, 350381, 350383, 350385, 350387, 350389, 350395, 350397, 350399, 227520, 350402, 227522, 301252, 350406, 227529, 309450, 301258, 276685, 309455, 276689, 227540, 309462, 301272, 276699, 309468, 194780, 309471, 301283, 317672, 317674, 325867, 243948, 194801, 309491, 309494, 243960, 276735, 227583, 227587, 276739, 211204, 276742, 227593, 227596, 325910, 309530, 342298, 211232, 317729, 276775, 211241, 325937, 325943, 211260, 260421, 285002, 276811, 235853, 276816, 235858, 276829, 276833, 391523, 276836, 276843, 293227, 276848, 293232, 186744, 211324, 227709, 285061, 366983, 317833, 178572, 285070, 285077, 178583, 227738, 317853, 276896, 317858, 342434, 285093, 317864, 285098, 276907, 235955, 276917, 293304, 293307, 293314, 309707, 293325, 129486, 317910, 293336, 235996, 317917, 293343, 358880, 276961, 227810, 293346, 276964, 293352, 236013, 293364, 301562, 293370, 317951, 309764, 301575, 121352, 236043, 317963, 342541, 55822, 113167, 309779, 317971, 309781, 55837, 227877, 227879, 293417, 227882, 309804, 293421, 105007, 236082, 285236, 23094, 277054, 244288, 219714, 129603, 318020, 301636, 301639, 301643, 277071, 285265, 309844, 277080, 309849, 285277, 285282, 326244, 318055, 277100, 309871, 121458, 277106, 170618, 170619, 309885, 309888, 277122, 227975, 277128, 285320, 301706, 318092, 326285, 334476, 318094, 277136, 277139, 227992, 334488, 318108, 285340, 318110, 227998, 137889, 383658, 285357, 318128, 277170, 342707, 318132, 154292, 293555, 277173, 285368, 277177, 277181, 318144, 277187, 277191, 277194, 277196, 277201, 342745, 137946, 342747, 342749, 113378, 203491, 228069, 277223, 342760, 285417, 56041, 56043, 56045, 277232, 228081, 56059, 310015, 285441, 310020, 285448, 310029, 228113, 285459, 277273, 293659, 326430, 228128, 293666, 228135, 318248, 277291, 318253, 293677, 285489, 301876, 293685, 285494, 301880, 285499, 301884, 310080, 293696, 277317, 277322, 293706, 277329, 162643, 310100, 301911, 301913, 277337, 301921, 400236, 236397, 162671, 326514, 310134, 15224, 236408, 277368, 416639, 416640, 113538, 310147, 416648, 39817, 187274, 277385, 301972, 424853, 277405, 277411, 310179, 293798, 293802, 236460, 277426, 276579, 293811, 293817, 293820, 203715, 326603, 342994, 276586, 293849, 293861, 228327, 228328, 228330, 318442, 228332, 326638, 277486, 351217, 318450, 293876, 293877, 285686, 302073, 285690, 121850, 293882, 244731, 302075, 293887, 277504, 277507, 277511, 293899, 277519, 293908, 302105, 293917, 293939, 318516, 277561, 277564, 310336, 7232, 293956, 277573, 228422, 310344, 277577, 293960, 277583, 203857, 310355, 293971, 310359, 236632, 277594, 138332, 277598, 203872, 277601, 285792, 310374, 203879, 310376, 228460, 318573, 203886, 187509, 285815, 285817, 367737, 302205, 285821, 392326, 285831, 302218, 285835, 294026, 384148, 162964, 187542, 302231, 285849, 302233, 285852, 302237, 285854, 285856, 302241, 285862, 277671, 302248, 64682, 277678, 294063, 294065, 302258, 277687, 294072, 318651, 294076, 277695, 318657, 244930, 302275, 130244, 302277, 228550, 302282, 310476, 302285, 302288, 310481, 302290, 203987, 302292, 302294, 302296, 384222, 310498, 285927, 318698, 302315, 195822, 228592, 294132, 138485, 228601, 204026, 228606, 204031, 64768, 310531, 285958, 138505, 228617, 318742, 204067, 277798, 130345, 277801, 113964, 277804, 384302, 285999, 285997, 113969, 277807, 277811, 318773, 318776, 277816, 286010, 277819, 294204, 417086, 277822, 286016, 302403, 294211, 384328, 277832, 277836, 146765, 294221, 326991, 294223, 277839, 277842, 277847, 277850, 179547, 277853, 277857, 302436, 277860, 294246, 327015, 310632, 327017, 351594, 277864, 277869, 277872, 351607, 310648, 277880, 310651, 277884, 277888, 310657, 310659, 351619, 294276, 327046, 277892, 253320, 310665, 318858, 277894, 277898, 277903, 310672, 351633, 277905, 277908, 277917, 310689, 277921, 130468, 277928, 277932, 310703, 277937, 310710, 130486, 310712, 277944, 310715, 277947, 302526, 228799, 277950, 277953, 302534, 245191, 310727, 64966, 163272, 277959, 292968, 302541, 277963, 302543, 277966, 310737, 277971, 228825, 277978, 310749, 277981, 277984, 310755, 277989, 277991, 187880, 277995, 310764, 286188, 278000, 228851, 310772, 278003, 278006, 40440, 212472, 278009, 40443, 286203, 310780, 40448, 228864, 286214, 228871, 302603, 65038, 302614, 302617, 286233, 302621, 187936, 146977, 286240, 187939, 40484, 294435, 40486, 286246, 40488, 278057, 245288, 40491, 294439, 294440, 294443, 310831, 294445, 286248, 40499, 40502, 212538, 40507, 40511, 40513, 228933, 327240, 40521, 286283, 40525, 40527, 400976, 212560, 228944, 40533, 147032, 40537, 40539, 40541, 278109, 40544, 40548, 40550, 40552, 286312, 40554, 286313, 310892, 40557, 40560, 188022, 122488, 294521, 343679, 294537, 310925, 286354, 278163, 302740, 122517, 278168, 179870, 327333, 229030, 212648, 278188, 302764, 278192, 319153, 278196, 302781, 319171, 302789, 294599, 278216, 302793, 294601, 343757, 212690, 278227, 286420, 319187, 229076, 286425, 319194, 278235, 278238, 229086, 286432, 294625, 294634, 302838, 319226, 286460, 278274, 302852, 278277, 302854, 311048, 294664, 352008, 319243, 311053, 302862, 319251, 294682, 278306, 188199, 294701, 319280, 278320, 319290, 229192, 302925, 188247, 280021, 188252, 237409, 229233, 294776, 360317, 294785, 327554, 360322, 40840, 40851, 294803, 188312, 294811, 319390, 237470, 40865, 319394, 294817, 294821, 311209, 180142, 188340, 40886, 319419, 294844, 294847, 237508, 393177, 294876, 294879, 294883, 393190, 294890, 311279, 278513, 237555, 311283, 278516, 278519, 237562 ]
ccdb715fec09e2c2888ed217d259ae56aeb5ba10
12d8ac951b69e6c779ab41633227cafe49437e26
/Users/AppDelegate.swift
1f2818ca917fa192c96e6ff399397401667efaac
[]
no_license
argh15/Users
d1f76c6f4d8ffb56dff842adaa24d715d0279979
3f4f68069be8e1f3f4b50e386d37fc3fe4d299d1
refs/heads/main
2023-07-13T08:13:10.072125
2021-08-22T08:41:33
2021-08-22T08:41:33
394,737,909
0
0
null
2021-08-22T08:41:34
2021-08-10T17:58:25
Swift
UTF-8
Swift
false
false
1,354
swift
// // AppDelegate.swift // Users // // Created by Arghadeep Chakraborty on 10/08/21. // import UIKit @main class AppDelegate: UIResponder, UIApplicationDelegate { func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true } // MARK: UISceneSession Lifecycle func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration { // Called when a new scene session is being created. // Use this method to select a configuration to create the new scene with. return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role) } func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set<UISceneSession>) { // Called when the user discards a scene session. // If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions. // Use this method to release any resources that were specific to the discarded scenes, as they will not return. } }
[ 393222, 393224, 393230, 393250, 344102, 393261, 393266, 213048, 385081, 376889, 393275, 376905, 327756, 254030, 286800, 368727, 180313, 368735, 180320, 376931, 286831, 368752, 286844, 417924, 262283, 286879, 286888, 377012, 327871, 180416, 377036, 180431, 377046, 418007, 418010, 377060, 327914, 205036, 393456, 393460, 418043, 336123, 336128, 385280, 262404, 180490, 164106, 368911, 262416, 262422, 377117, 262436, 336180, 262454, 393538, 262472, 344403, 213332, 65880, 262496, 418144, 262499, 213352, 246123, 262507, 262510, 213372, 385419, 393612, 262550, 262552, 385440, 385443, 262566, 385451, 262573, 393647, 385458, 262586, 344511, 262592, 360916, 369118, 328177, 328179, 328182, 328189, 328192, 164361, 410128, 393747, 254490, 188958, 385570, 33316, 197159, 377383, 352821, 197177, 418363, 188987, 369223, 385609, 385616, 352864, 369253, 262760, 352874, 352887, 254587, 377472, 148105, 377484, 352918, 98968, 344744, 361129, 336555, 385713, 434867, 164534, 336567, 328378, 164538, 328386, 344776, 352968, 418507, 352971, 352973, 385742, 385748, 361179, 189153, 369381, 361195, 418553, 344831, 336643, 344835, 344841, 361230, 336659, 418580, 418585, 434970, 369435, 418589, 262942, 418593, 336675, 328484, 418598, 418605, 336696, 361273, 328515, 328519, 361288, 336711, 328522, 336714, 426841, 197468, 254812, 361309, 361315, 361322, 328573, 377729, 369542, 361360, 222128, 345035, 345043, 386003, 386011, 386018, 386022, 435187, 328702, 328714, 361489, 386069, 386073, 336921, 336925, 345118, 377887, 345133, 345138, 386101, 361536, 197707, 189520, 345169, 156761, 361567, 148578, 345199, 386167, 361593, 410745, 361598, 214149, 345222, 386186, 337047, 345246, 214175, 337071, 337075, 345267, 386258, 328924, 66782, 222437, 328941, 386285, 386291, 345376, 353570, 345379, 410917, 345382, 337205, 345399, 378169, 369978, 337222, 337229, 337234, 263508, 402791, 345448, 271730, 378227, 271745, 181638, 353673, 181643, 181649, 181654, 230809, 181670, 181673, 181678, 181681, 337329, 181684, 181690, 361917, 181696, 337349, 181703, 337365, 271839, 329191, 361960, 329194, 116210, 337398, 337415, 329226, 419339, 419343, 419349, 345625, 419355, 370205, 419359, 394786, 419362, 370213, 419368, 419376, 206395, 214593, 419400, 419402, 353867, 419406, 419410, 345701, 394853, 222830, 370297, 353919, 403075, 198280, 345736, 403091, 345749, 419483, 345757, 345762, 419491, 345765, 419497, 419501, 370350, 419506, 419509, 419512, 337592, 419517, 337599, 419527, 419530, 419535, 272081, 394966, 419542, 419544, 181977, 345818, 419547, 419550, 419559, 337642, 419563, 337645, 370415, 337659, 141051, 337668, 362247, 395021, 362255, 116509, 345887, 378663, 345905, 354106, 354111, 247617, 354117, 370503, 329544, 370509, 354130, 247637, 337750, 370519, 313180, 354142, 354150, 354156, 345967, 345970, 345974, 403320, 354172, 247691, 337808, 247700, 329623, 436126, 436132, 337833, 362413, 337844, 346057, 247759, 346063, 329697, 354277, 190439, 247789, 354313, 346139, 436289, 378954, 395339, 338004, 100453, 329832, 329855, 329885, 411805, 346272, 362660, 100524, 387249, 379066, 387260, 256191, 395466, 346316, 411861, 411864, 411868, 411873, 379107, 411876, 387301, 346343, 338152, 387306, 387312, 346355, 436473, 321786, 379134, 411903, 411916, 379152, 395538, 387349, 338199, 387352, 182558, 338211, 395566, 248111, 362822, 436555, 190796, 379233, 354673, 321910, 248186, 420236, 379278, 272786, 354727, 338352, 338381, 330189, 338386, 256472, 338403, 338409, 248308, 199164, 330252, 199186, 330267, 354855, 10828, 199249, 346721, 174695, 248425, 191084, 191092, 346742, 330383, 354974, 150183, 174774, 248504, 174777, 223934, 355024, 273108, 355028, 264918, 183005, 256734, 436962, 338660, 338664, 264941, 363251, 207619, 264964, 338700, 256786, 199452, 363293, 396066, 346916, 396069, 215853, 355122, 355131, 355140, 355143, 338763, 355150, 330580, 355166, 265055, 265058, 355175, 387944, 355179, 330610, 330642, 355218, 412599, 207808, 379848, 396245, 330710, 248792, 248798, 347105, 257008, 183282, 265207, 330748, 265214, 330760, 330768, 248862, 347176, 158761, 396328, 199728, 330800, 396336, 396339, 339001, 388154, 388161, 347205, 248904, 330826, 248914, 412764, 339036, 257120, 265320, 248951, 420984, 330889, 347287, 248985, 339097, 44197, 380070, 339112, 249014, 126144, 330958, 330965, 265432, 265436, 388319, 388347, 175375, 159005, 175396, 208166, 273708, 347437, 372015, 347441, 372018, 199988, 44342, 175415, 396600, 437566, 175423, 437570, 437575, 437583, 331088, 437587, 331093, 396633, 175450, 437595, 175457, 208227, 175460, 175463, 265580, 437620, 175477, 249208, 175483, 249214, 175486, 175489, 249218, 249224, 249227, 249234, 175513, 175516, 396705, 175522, 355748, 380332, 396722, 208311, 372163, 216517, 380360, 216522, 339404, 372176, 208337, 339412, 413141, 339417, 249308, 339420, 249312, 339424, 339428, 339434, 249328, 69113, 372228, 208398, 380432, 175635, 265778, 265795, 396872, 265805, 224853, 224857, 257633, 224870, 372327, 257646, 372337, 224884, 224887, 224890, 224894, 372353, 224897, 216707, 421508, 126596, 224904, 224909, 159374, 11918, 224913, 126610, 224916, 224919, 126616, 208538, 224922, 224926, 224929, 224932, 224936, 257704, 224942, 257712, 224947, 257716, 257720, 224953, 257724, 224959, 257732, 224965, 224969, 339662, 224975, 257747, 224981, 224986, 224993, 257761, 257764, 224999, 339695, 225012, 257787, 225020, 339710, 257790, 225025, 257794, 257801, 339721, 257804, 225038, 257807, 372499, 167700, 225043, 225048, 257819, 225053, 184094, 225058, 257833, 225066, 257836, 413484, 225070, 225073, 372532, 257845, 225079, 397112, 225082, 397115, 225087, 225092, 225096, 323402, 257868, 257871, 225103, 397139, 225108, 225112, 257883, 257886, 225119, 257890, 339814, 225127, 257896, 274280, 257901, 225137, 339826, 257908, 225141, 257912, 257916, 225148, 257920, 225155, 339844, 225165, 397200, 225170, 380822, 225175, 225180, 118691, 184244, 372664, 372702, 372706, 356335, 380918, 405533, 430129, 266294, 266297, 421960, 356439, 430180, 421990, 266350, 356466, 266362, 381068, 225423, 250002, 250004, 225429, 356506, 225437, 135327, 225441, 438433, 225444, 438436, 225447, 438440, 225450, 258222, 225455, 430256, 225458, 225461, 225466, 389307, 225470, 381120, 372929, 430274, 225475, 389320, 225484, 225487, 225490, 225493, 266453, 225496, 225499, 225502, 225505, 356578, 217318, 225510, 225514, 225518, 372976, 381176, 397571, 389380, 61722, 356637, 356640, 356643, 356646, 266536, 356649, 356655, 332080, 340275, 356660, 397622, 332090, 225597, 332097, 201028, 348488, 332106, 332117, 348502, 250199, 250202, 332125, 250210, 348522, 348525, 348527, 332152, 389502, 250238, 332161, 356740, 332172, 373145, 340379, 389550, 324030, 266687, 160234, 127471, 340472, 381436, 324094, 266754, 324099, 324102, 324111, 340500, 324117, 324131, 332324, 381481, 324139, 356907, 324142, 356916, 324149, 324155, 348733, 324164, 356934, 348743, 381512, 324170, 324173, 324176, 389723, 332380, 373343, 381545, 340627, 184982, 373398, 258721, 332453, 332459, 389805, 332463, 381617, 332471, 332483, 332486, 373449, 357069, 332493, 357073, 332511, 332520, 340718, 332533, 348924, 373510, 389926, 152370, 348978, 340789, 348982, 398139, 127814, 357201, 357206, 389978, 357211, 430939, 357214, 201579, 201582, 349040, 340849, 201588, 430965, 381813, 324472, 398201, 119674, 324475, 340858, 340861, 324478, 430972, 324481, 373634, 398211, 324484, 324487, 381833, 324492, 324495, 430995, 324501, 324510, 422816, 324513, 398245, 201637, 324524, 340909, 324533, 324538, 324541, 398279, 340939, 340941, 209873, 340957, 431072, 398306, 340963, 209895, 201711, 349172, 349180, 439294, 431106, 250914, 357410, 185380, 357418, 209965, 209968, 209975, 209979, 209987, 341071, 349267, 250967, 210010, 341091, 210025, 210027, 210030, 210036, 210039, 349308, 160895, 152703, 349311, 210052, 210055, 349319, 218247, 210067, 210071, 210077, 210080, 251044, 210084, 185511, 210088, 210098, 210107, 210115, 332997, 210127, 333009, 210131, 333014, 210138, 210143, 218354, 218360, 251128, 275706, 275712, 275715, 275721, 349459, 333078, 251160, 349484, 349491, 251189, 415033, 251210, 357708, 210260, 365911, 259421, 365921, 333154, 251235, 374117, 333162, 234866, 390516, 333175, 357755, 251271, 136590, 374160, 112020, 349590, 357792, 259515, 415166, 415185, 366034, 366038, 415191, 415193, 415196, 415199, 423392, 333284, 415207, 366056, 366061, 415216, 210420, 415224, 423423, 415257, 415263, 366117, 415270, 144939, 415278, 415281, 415285, 210487, 415290, 415293, 349761, 415300, 333386, 366172, 333413, 423528, 423532, 210544, 415353, 333439, 415361, 267909, 153227, 333498, 210631, 333511, 259788, 358099, 333534, 366307, 366311, 431851, 366318, 210672, 366321, 366325, 210695, 268041, 210698, 366348, 210706, 399128, 333594, 210719, 358191, 366387, 210739, 399159, 358200, 325440, 366401, 341829, 325446, 46920, 341834, 341838, 341843, 415573, 358234, 341851, 350045, 399199, 259938, 399206, 358255, 399215, 268143, 358259, 333689, 243579, 325504, 333698, 333708, 333724, 382890, 350146, 333774, 358371, 350189, 350193, 350202, 333818, 350206, 350213, 268298, 350224, 350231, 333850, 350237, 350240, 350244, 350248, 178218, 350251, 350256, 350259, 350271, 243781, 350285, 374864, 342111, 342133, 374902, 432271, 333997, 334011, 260289, 260298, 350410, 350416, 350422, 211160, 350425, 334045, 350445, 375026, 358644, 350458, 350461, 350464, 350467, 325891, 350475, 375053, 268559, 350480, 432405, 350486, 325914, 350490, 325917, 350493, 325919, 350498, 194852, 350504, 358700, 350509, 391468, 358704, 358713, 358716, 383306, 334161, 383321, 383330, 383333, 391530, 383341, 334203, 268668, 194941, 391563, 366990, 416157, 268701, 342430, 375208, 326058, 375216, 334262, 326084, 358856, 334304, 334311, 375277, 334321, 350723, 391690, 186897, 342545, 334358, 342550, 342554, 334363, 358941, 350761, 252461, 334384, 383536, 358961, 334394, 252482, 219718, 334407, 334420, 350822, 375400, 334465, 334468, 162445, 326290, 342679, 342683, 260766, 342710, 244409, 260797, 260801, 350917, 154317, 391894, 154328, 416473, 64230, 113388, 342766, 375535, 203506, 342776, 391937, 391948, 375568, 326416, 375571, 375574, 162591, 326441, 383793, 326451, 326454, 375612, 244540, 326460, 260924, 326467, 244551, 326473, 326477, 416597, 326485, 326490, 342874, 326502, 375656, 433000, 326507, 326510, 211825, 211831, 351097, 392060, 359295, 351104, 342915, 400259, 236430, 342930, 252822, 392091, 400285, 252836, 359334, 211884, 400306, 351168, 359361, 326598, 359366, 359382, 359388, 383967, 343015, 359407, 261108, 244726, 261111, 383997, 261129, 359451, 261147, 211998, 261153, 261159, 359470, 359476, 343131, 384098, 384101, 367723, 384107, 187502, 343154, 384114, 212094, 351364, 384135, 384139, 384143, 351381, 384160, 384168, 367794, 384181, 367800, 351423, 384191, 384198, 326855, 244937, 253130, 343244, 146642, 359649, 343270, 351466, 351479, 384249, 343306, 261389, 384269, 359694, 253200, 261393, 384275, 245020, 245029, 171302, 351534, 376110, 245040, 384314, 425276, 384323, 212291, 343365, 212303, 367965, 343393, 343398, 367980, 425328, 343409, 154999, 253303, 343417, 327034, 245127, 384397, 245136, 245142, 245145, 343450, 245148, 245151, 245154, 245157, 245162, 327084, 359865, 384443, 146876, 327107, 384453, 327110, 327115, 327117, 359886, 359890, 343507, 368092, 343534, 343539, 368119, 343544, 368122, 409091, 359947, 359955, 359983, 343630, 179802, 155239, 327275, 245357, 138864, 155254, 155273, 368288, 245409, 425638, 425649, 155322, 425662, 155327, 253943, 155351, 155354, 212699, 155363, 155371, 245483, 409335, 155393, 155403, 155422, 360223, 155438, 155442, 155447, 417595, 360261, 155461, 376663, 155482, 261981, 425822, 155487, 376671, 155490, 155491, 327531, 261996, 376685, 261999, 262002, 327539, 147317, 262005, 425845, 262008, 262011, 155516, 155521, 155525, 360326, 262027, 155531, 262030, 262033, 262036, 262039, 262042, 155549, 262045, 262048, 262051, 327589, 155559, 155562, 155565, 393150, 384977, 393169, 155611, 253923, 155619, 155621, 253926, 327654, 204784, 393203, 360438, 393206, 393212, 155646 ]
a047fa962b9947cf2c2a990c07dae76be3642579
51c65f53b182847179d918597c49c943bc3e6cfe
/notiTrial/AppDelegate.swift
9182524b36b461506e5572a78dd516981876abf1
[]
no_license
VivaanBaid/PushNotifications
5f7a91f228d1809292380b71814fc983176fa60a
165351b581c952d652cb0378713bef22d2aec197
refs/heads/main
2023-08-30T10:50:43.841297
2021-10-22T18:10:23
2021-10-22T18:10:23
null
0
0
null
null
null
null
UTF-8
Swift
false
false
2,794
swift
// // AppDelegate.swift // notiTrial // // Created by Vivaan Baid on 22/10/21. // import UIKit import Firebase import FirebaseMessaging import UserNotifications @main class AppDelegate: UIResponder, UIApplicationDelegate, MessagingDelegate, UNUserNotificationCenterDelegate { func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { FirebaseApp.configure() let replyAction = UNNotificationAction( identifier: "reply.action", title: "Reply to this message", options: []) let pushNotificationButtons = UNNotificationCategory( identifier: "allreply.action", actions: [replyAction], intentIdentifiers: [], options: []) Messaging.messaging().delegate = self UNUserNotificationCenter.current().delegate = self UNUserNotificationCenter.current().setNotificationCategories([pushNotificationButtons]) UNUserNotificationCenter.current().requestAuthorization(options: [.alert,.sound,.badge]) { success, error in if let e = error{ print(e.localizedDescription) }else{ print("Success in APNS registry") DispatchQueue.main.async { application.registerForRemoteNotifications() } } } return true } func messaging(_ messaging: Messaging, didReceiveRegistrationToken fcmToken: String?) { messaging.token { mytoken, error in if let e = error{ print(e.localizedDescription) }else{ print(mytoken!) } } } // MARK: UISceneSession Lifecycle func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration { // Called when a new scene session is being created. // Use this method to select a configuration to create the new scene with. return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role) } func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set<UISceneSession>) { // Called when the user discards a scene session. // If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions. // Use this method to release any resources that were specific to the discarded scenes, as they will not return. } }
[ -1 ]
76029b6ba3324214835667d970723ad64f62f669
a2bcde3495dde0bd0e85e061a2a8f034e77c30ca
/ESPullToRefreshExample/ESPullToRefreshExample/Custom/Default/DefaultTableViewController.swift
ea3cb06341ba57f5c00a8491919f06fb69b614a0
[ "MIT" ]
permissive
476139183/pull-to-refresh
853c1fa04e130ebc7462ab89c59c316d78c622ad
09a7eb73f8daf9fb090cdfb3006ba8963e01c5fd
refs/heads/master
2020-12-25T09:58:03.863561
2016-05-30T02:28:27
2016-05-30T02:28:27
null
0
0
null
null
null
null
UTF-8
Swift
false
false
3,256
swift
// // DefaultTableViewController.swift // ESPullToRefreshExample // // Created by lihao on 16/5/6. // Copyright © 2016年 egg swift. All rights reserved. // import UIKit class DefaultTableViewController: UITableViewController { var array = [String]() var page = 1 override func viewDidLoad() { super.viewDidLoad() self.view.translatesAutoresizingMaskIntoConstraints = false self.tableView.registerNib(UINib.init(nibName: "DefaultTableViewCell", bundle: nil), forCellReuseIdentifier: "DefaultTableViewCell") for _ in 1...8{ self.array.append(" ") } self.tableView.es_addPullToRefresh { [weak self] in let minseconds = 3.0 * Double(NSEC_PER_SEC) let dtime = dispatch_time(DISPATCH_TIME_NOW, Int64(minseconds)) dispatch_after(dtime, dispatch_get_main_queue() , { self?.page = 1 self?.array.removeAll() for _ in 1...8{ self?.array.append(" ") } self?.tableView.reloadData() self?.tableView.es_stopPullToRefresh(completion: true) }) } self.tableView.es_addInfiniteScrolling { [weak self] in let minseconds = 3.0 * Double(NSEC_PER_SEC) let dtime = dispatch_time(DISPATCH_TIME_NOW, Int64(minseconds)) dispatch_after(dtime, dispatch_get_main_queue() , { self?.page += 1 if self?.page <= 3 { for _ in 1...8{ self?.array.append(" ") } self?.tableView.reloadData() self?.tableView.es_stopLoadingMore() } else { self?.tableView.es_noticeNoMoreData() } }) } } override func viewDidAppear(animated: Bool) { super.viewDidAppear(animated) self.tableView.es_startPullToRefresh() } // MARK: - Table view data source override func numberOfSectionsInTableView(tableView: UITableView) -> Int { return 1 } override func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return array.count } override func tableView(tableView: UITableView, heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat { return 100.0 } override func tableView(tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat { return CGFloat.min } override func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { let cell = tableView.dequeueReusableCellWithIdentifier("DefaultTableViewCell", forIndexPath: indexPath) cell.backgroundColor = UIColor.init(white: 250.0 / 255.0, alpha: 1.0) return cell } override func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) { tableView.deselectRowAtIndexPath(indexPath, animated: true) let vc = WebViewController.init() self.navigationController?.pushViewController(vc, animated: true) } }
[ -1 ]
2c0ea2840ae28a2dbf00fcc334252fa30dd06327
81a969ad64e8686af44417b2e220b618addc546b
/Birdzi/cell/menuCell.swift
48a63c334f0a7c34cdccce3ca42d549940f72da0
[]
no_license
praveenBirdzi/BirdziWLPune
0328e6b0bbe8196aaf86735129192fe323c57652
3d2f3caebe04c1c0359934f53453ebdd3523aae0
refs/heads/master
2020-03-18T16:01:26.899604
2018-05-31T04:16:25
2018-05-31T04:16:25
134,942,611
0
0
null
null
null
null
UTF-8
Swift
false
false
271
swift
// // menuCell.swift // menu // // Created by Dinesh Jagtap on 5/17/18. // Copyright © 2018 Birdzi. All rights reserved. // import UIKit class menuCell: UICollectionViewCell { @IBOutlet weak var imgView: UIImageView! @IBOutlet weak var menuLbl: UILabel! }
[ 281120, 135675 ]
2368a1445f6341c3b4df8785fb4acd9aa6537d46
ce1dc7babaa9eb64980a6befc8d51580f0a27d6b
/Carthage/Checkouts/Hybrid/src/button/select/switch/Switch.swift
8466b321ba6fb34d1103dcf92fa477479b0c7c92
[ "MIT" ]
permissive
eonist/AnimLib
a22ed14bdb7f3047f2576cee5506b7b736eb5c48
1c7086a68de3cfeea2e48cfc21dc5d40ff82a1b6
refs/heads/master
2023-03-24T06:42:27.188185
2021-03-22T20:44:22
2021-03-22T20:44:22
94,378,947
37
1
null
null
null
null
UTF-8
Swift
false
false
1,770
swift
import Foundation #if os(iOS) import Spatial #elseif os(macOS) import Spatial_macOS #endif open class Switch: Button, Selectable { var switchStyles: SwitchStyles public var switchStyle: SwitchStyle public lazy var foreground: SwitchForeground = createForeground() open var selected: Bool { didSet { Swift.print(": \(self.selected)") self.switchStyle = self.selected ? switchStyles.selected : switchStyles.unSelected // self.caLayer?.borderColor = style.borderColor.cgColor super.style.backgroundColor = self.switchStyle.backgroundColor foreground.caLayer?.backgroundColor = self.switchStyle.foregroundColor.cgColor // Swift.print("selected: \(selected)") // Swift.print("switchStyle.foregroundColor: \(switchStyle.foregroundColor)") // self.caLayer?.borderWidth = style.borderWidth toggleForegroundPosition() } } /** * Initiate */ public init(isSelected: Bool, styles: SwitchStyles = defaultSwitchStyles, frame: CGRect = .zero) { self.selected = isSelected self.switchStyles = styles self.switchStyle = isSelected ? styles.selected : styles.unSelected // let selectButtonStyle:SelectButton.Styles = let selectedStyle: Style = (styles.selected.backgroundColor, Color.clear, 0, true) let unSelectedStyle: Style = (styles.unSelected.backgroundColor, Color.clear, 0, true) let style: Style = isSelected ? selectedStyle : unSelectedStyle super.init(style: style, frame: frame) _ = foreground _ = { self.selected = self.selected }()/*hack*/ } /** * Boilerplate */ public required init?(coder aDecoder: NSCoder) { fatalError("init(coder:) has not been implemented") } }
[ -1 ]
b8ec3e207eacee7d267574285e509f48c975b2c0
05bf1b8159987fd4716962db6415976499f5d56f
/RainCat/Utility/SoundManager.swift
a2ecd44537bb616cac71c177f9bf4268b5c304cb
[]
no_license
group10-ios-programming/-BaiTapCuoiKy_RainCat
54986303ff4678bc0089e936e8f4281bbe661709
a3ea70dcbf38623084130a602c8c23f78e93a5e8
refs/heads/master
2020-03-18T12:02:05.126722
2018-05-27T15:45:17
2018-05-27T15:45:17
134,704,919
0
0
null
null
null
null
UTF-8
Swift
false
false
4,750
swift
// // SoundManager.swift // RainCat // // Created by Marc Vandehey on 9/1/16. // Copyright © 2016 Thirteen23. All rights reserved. // import AVFoundation import SpriteKit import Foundation class SoundManager : NSObject, AVAudioPlayerDelegate { static let sharedInstance = SoundManager() var audioPlayer : AVAudioPlayer? var trackPosition = 0 //Music: http://www.bensound.com/royalty-free-music static private let tracks = [ "bensound-clearday", "bensound-jazzcomedy", "bensound-jazzyfrenchy", "bensound-littleidea", "jeffmoon-raincat-1" //Except this one, this one is from Mr Moon. ] static private let extensions = [ "mp3", "mp3", "mp3", "mp3", "wav" ] private let fruitName = ["avocado.wav","carrot.wav","cherries.wav","corn.wav","grapes.wav","lemon.wav","orange.wav","pumpkin.wav","raspberry.wav","strawberry.wav" ] private let meowSFX = [ "cat_meow_1.mp3", "cat_meow_2.mp3", "cat_meow_3.mp3", "cat_meow_4.mp3", "cat_meow_5.wav", "cat_meow_6.wav", "cat_meow_7.mp3" ] private var soundTempMuted = false private let move = "move.wav" private let lcdHit = "hit.wav" private let lcdPickup = "lcd-pickup.wav" private let buttonClick = SKAction.playSoundFileNamed("buttonClick.wav", waitForCompletion: true) private override init() { //This is private so you can only have one Sound Manager ever. trackPosition = Int(arc4random_uniform(UInt32(SoundManager.tracks.count))) } public func startPlaying() { if !UserDefaultsManager.sharedInstance.isMuted && (audioPlayer == nil || audioPlayer?.isPlaying == false) { let soundURL = Bundle.main.url(forResource: SoundManager.tracks[trackPosition], withExtension: SoundManager.extensions[trackPosition]) do { audioPlayer = try AVAudioPlayer(contentsOf: soundURL!) audioPlayer?.delegate = self } catch { print("audio player failed to load: \(String(describing: soundURL)) \(trackPosition)") return } audioPlayer?.prepareToPlay() audioPlayer?.play() trackPosition = (trackPosition + 1) % SoundManager.tracks.count } } public func muteMusic() { audioPlayer?.setVolume(0, fadeDuration: 0.5) } public func resumeMusic() { audioPlayer?.setVolume(1, fadeDuration: 0.25) startPlaying() } func audioPlayerDidFinishPlaying(_ player: AVAudioPlayer, successfully flag: Bool) { //Just play the next track if !soundTempMuted { startPlaying() } } func toggleMute() -> Bool { let isMuted = UserDefaultsManager.sharedInstance.toggleMute() if isMuted { muteMusic() } else if (audioPlayer == nil || audioPlayer?.isPlaying == false) { startPlaying() } else { resumeMusic() } return isMuted } public func meow(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted && node.action(forKey: "action_sound_effect") == nil { let selectedSFX = Int(arc4random_uniform(UInt32(meowSFX.count))) node.run(SKAction.playSoundFileNamed(meowSFX[selectedSFX], waitForCompletion: true), withKey: "action_sound_effect") } } public func fruitw(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted && node.action(forKey: "action_sound_effect") == nil { node.run(SKAction.playSoundFileNamed(fruitName[GameScene.foodIndex], waitForCompletion: true), withKey: "action_sound_effect") } } public static func playLCDPickup(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted { node.run(SKAction.playSoundFileNamed(SoundManager.sharedInstance.lcdPickup, waitForCompletion: true), withKey: "lcd-pickup") } } public static func playLCDMove(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted { node.run(SKAction.playSoundFileNamed(SoundManager.sharedInstance.move, waitForCompletion: true), withKey: "lcd-move") } } public static func playLCDHit(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted { node.run(SKAction.playSoundFileNamed(SoundManager.sharedInstance.lcdHit, waitForCompletion: true), withKey: "lcd-hit") } } public static func playButtonClick(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted { node.run(SoundManager.sharedInstance.buttonClick, withKey: "buttonClick") } } public static func playUmbrellaHit(node : SKNode) { if !UserDefaultsManager.sharedInstance.isMuted { node.run(SoundManager.sharedInstance.buttonClick, withKey: "umbrellaHit") } } }
[ -1 ]
44ea98df4fe7a73e1ab9bed1099f47be149305d1
881cc7f1cfd3188c22de358f9d5ce7a4d064ab96
/NumberGames/NumberGames/ViewController.swift
c640c5e7a89db4caa43ffc26f5ec9d2347efe834
[ "MIT" ]
permissive
Prashant-mahajan/iOS-apps
4d2ca9277ccf21b56335505171f9d1f552e80ca8
447cab8916375b78af50f9e711d059efd88823f9
refs/heads/master
2021-01-19T11:34:31.768606
2017-02-23T06:32:11
2017-02-23T06:32:11
82,254,197
0
0
null
null
null
null
UTF-8
Swift
false
false
912
swift
// // ViewController.swift // NumberGames // // Created by Prashant Mahajan on 19/02/17. // Copyright © 2017 Prashant Mahajan. All rights reserved. // import UIKit class ViewController: UIViewController { @IBOutlet weak var textInput: UITextField! @IBOutlet weak var textOutput: UITextField! @IBAction func Evaluate(_ sender: Any) { let x = Int(arc4random_uniform(5)) let y = Int(textInput.text!)! if (x == y){ textOutput.text = String("You win!!!!") } else{ textOutput.text = String("You lose") } } override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
[ -1 ]
a1b8250453ac37c408a2989422af2647e7832719
879785520851fb3c83787cd2f20a460063476fda
/Sources/Crypto/Util/BoringSSL/FiniteFieldArithmeticContext_boring.swift
418de11df746d1f778a5dc59722ef201b865bc6c
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
Sajjon/swift-crypto
45df4834f725231e680181e755a96afa2175eed1
c433cd3341e14590ba7efccb0836cd3cd0a0c055
refs/heads/main
2023-07-07T07:27:53.685504
2023-06-13T17:27:01
2023-06-13T17:27:01
238,050,169
0
0
Apache-2.0
2020-02-05T21:46:37
2020-02-03T20:00:15
Swift
UTF-8
Swift
false
false
6,076
swift
//===----------------------------------------------------------------------===// // // This source file is part of the SwiftCrypto open source project // // Copyright (c) 2019 Apple Inc. and the SwiftCrypto project authors // Licensed under Apache License v2.0 // // See LICENSE.txt for license information // See CONTRIBUTORS.md for the list of SwiftCrypto project authors // // SPDX-License-Identifier: Apache-2.0 // //===----------------------------------------------------------------------===// #if (os(macOS) || os(iOS) || os(watchOS) || os(tvOS)) && CRYPTO_IN_SWIFTPM && !CRYPTO_IN_SWIFTPM_FORCE_BUILD_API @_exported import CryptoKit #else @_implementationOnly import CCryptoBoringSSL import Foundation /// A context for performing mathematical operations on ArbitraryPrecisionIntegers over a finite field. /// /// A common part of elliptic curve mathematics is to perform arithmetic operations over a finite field. These require /// performing modular arithmetic, and cannot be processed in the same way as regular math on these integers. /// /// Most operations we perform over finite fields are part of repeated, larger arithmetic operations, so this object also /// manages the lifetime of a `BN_CTX`. While `BN_CTX` is a silly data type, it does still have the effect of caching existing /// `BIGNUM`s, so it's not a terrible idea to use it here. /// /// Annoyingly, because of the way we have implemented ArbitraryPrecisionInteger, we can't actually use these temporary bignums /// ourselves. @usableFromInline class FiniteFieldArithmeticContext { private var fieldSize: ArbitraryPrecisionInteger private var bnCtx: OpaquePointer @usableFromInline init(fieldSize: ArbitraryPrecisionInteger) throws { self.fieldSize = fieldSize guard let bnCtx = CCryptoBoringSSL_BN_CTX_new() else { throw CryptoKitError.internalBoringSSLError() } CCryptoBoringSSL_BN_CTX_start(bnCtx) self.bnCtx = bnCtx } deinit { CCryptoBoringSSL_BN_CTX_end(self.bnCtx) CCryptoBoringSSL_BN_CTX_free(self.bnCtx) } } // MARK: - Arithmetic operations extension FiniteFieldArithmeticContext { @usableFromInline func square(_ input: ArbitraryPrecisionInteger) throws -> ArbitraryPrecisionInteger { var output = ArbitraryPrecisionInteger() let rc = input.withUnsafeBignumPointer { inputPointer in self.fieldSize.withUnsafeBignumPointer { fieldSizePointer in output.withUnsafeMutableBignumPointer { outputPointer in CCryptoBoringSSL_BN_mod_sqr(outputPointer, inputPointer, fieldSizePointer, self.bnCtx) } } } guard rc == 1 else { throw CryptoKitError.internalBoringSSLError() } return output } @usableFromInline func multiply(_ x: ArbitraryPrecisionInteger, _ y: ArbitraryPrecisionInteger) throws -> ArbitraryPrecisionInteger { var output = ArbitraryPrecisionInteger() let rc = x.withUnsafeBignumPointer { xPointer in y.withUnsafeBignumPointer { yPointer in self.fieldSize.withUnsafeBignumPointer { fieldSizePointer in output.withUnsafeMutableBignumPointer { outputPointer in CCryptoBoringSSL_BN_mod_mul(outputPointer, xPointer, yPointer, fieldSizePointer, self.bnCtx) } } } } guard rc == 1 else { throw CryptoKitError.internalBoringSSLError() } return output } @usableFromInline func add(_ x: ArbitraryPrecisionInteger, _ y: ArbitraryPrecisionInteger) throws -> ArbitraryPrecisionInteger { var output = ArbitraryPrecisionInteger() let rc = x.withUnsafeBignumPointer { xPointer in y.withUnsafeBignumPointer { yPointer in self.fieldSize.withUnsafeBignumPointer { fieldSizePointer in output.withUnsafeMutableBignumPointer { outputPointer in CCryptoBoringSSL_BN_mod_add(outputPointer, xPointer, yPointer, fieldSizePointer, self.bnCtx) } } } } guard rc == 1 else { throw CryptoKitError.internalBoringSSLError() } return output } @usableFromInline func subtract(_ x: ArbitraryPrecisionInteger, from y: ArbitraryPrecisionInteger) throws -> ArbitraryPrecisionInteger { var output = ArbitraryPrecisionInteger() let rc = x.withUnsafeBignumPointer { xPointer in y.withUnsafeBignumPointer { yPointer in self.fieldSize.withUnsafeBignumPointer { fieldSizePointer in output.withUnsafeMutableBignumPointer { outputPointer in // Note the order of y and x. CCryptoBoringSSL_BN_mod_sub(outputPointer, yPointer, xPointer, fieldSizePointer, self.bnCtx) } } } } guard rc == 1 else { throw CryptoKitError.internalBoringSSLError() } return output } @usableFromInline func positiveSquareRoot(_ x: ArbitraryPrecisionInteger) throws -> ArbitraryPrecisionInteger { let outputPointer = x.withUnsafeBignumPointer { xPointer in self.fieldSize.withUnsafeBignumPointer { fieldSizePointer in // We can't pass a pointer in as BN_mod_sqrt may attempt to free it. CCryptoBoringSSL_BN_mod_sqrt(nil, xPointer, fieldSizePointer, self.bnCtx) } } guard let actualOutputPointer = outputPointer else { throw CryptoKitError.internalBoringSSLError() } // Ok, we own this pointer now. defer { CCryptoBoringSSL_BN_free(outputPointer) } return try ArbitraryPrecisionInteger(copying: actualOutputPointer) } } #endif // (os(macOS) || os(iOS) || os(watchOS) || os(tvOS)) && CRYPTO_IN_SWIFTPM && !CRYPTO_IN_SWIFTPM_FORCE_BUILD_API
[ -1 ]
d4c47044b1e9b78b8a651d2e1f07cc0eec249aee
4fd9253b045a3272e55efbe2ed22b4d0c3be3a94
/QuizApp/QuizApp/SceneDelegate.swift
8e3c6236de1779028fc96d3491bc06cdfd9032d4
[]
no_license
KazutomoKita/QuizApp
31a187d77cab273b0b5a18dd51124c1792b64c37
c9b4c3885d3fe1547634f73035e39aced729416f
refs/heads/master
2021-05-18T11:25:12.817798
2020-04-06T07:50:10
2020-04-06T07:50:10
251,225,527
0
0
null
null
null
null
UTF-8
Swift
false
false
2,352
swift
// // SceneDelegate.swift // QuizApp // // Created by Kazutomo Kita on 2020/03/30. // Copyright © 2020 Kazutomo Kita. All rights reserved. // import UIKit class SceneDelegate: UIResponder, UIWindowSceneDelegate { var window: UIWindow? func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`. // If using a storyboard, the `window` property will automatically be initialized and attached to the scene. // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). guard let _ = (scene as? UIWindowScene) else { return } } func sceneDidDisconnect(_ scene: UIScene) { // Called as the scene is being released by the system. // This occurs shortly after the scene enters the background, or when its session is discarded. // Release any resources associated with this scene that can be re-created the next time the scene connects. // The scene may re-connect later, as its session was not neccessarily discarded (see `application:didDiscardSceneSessions` instead). } func sceneDidBecomeActive(_ scene: UIScene) { // Called when the scene has moved from an inactive state to an active state. // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive. } func sceneWillResignActive(_ scene: UIScene) { // Called when the scene will move from an active state to an inactive state. // This may occur due to temporary interruptions (ex. an incoming phone call). } func sceneWillEnterForeground(_ scene: UIScene) { // Called as the scene transitions from the background to the foreground. // Use this method to undo the changes made on entering the background. } func sceneDidEnterBackground(_ scene: UIScene) { // Called as the scene transitions from the foreground to the background. // Use this method to save data, release shared resources, and store enough scene-specific state information // to restore the scene back to its current state. } }
[ 393221, 163849, 393228, 393231, 393251, 352294, 344103, 393260, 393269, 213049, 376890, 385082, 16444, 393277, 376906, 327757, 254032, 286804, 368728, 254045, 368736, 180322, 376932, 286833, 286845, 286851, 417925, 262284, 360598, 286880, 286889, 377003, 377013, 164029, 327872, 180418, 377030, 377037, 180432, 377047, 418008, 385243, 418012, 377063, 327915, 205037, 393457, 393461, 393466, 418044, 336124, 385281, 336129, 262405, 180491, 336140, 164107, 262417, 368913, 262423, 377118, 377121, 262437, 254253, 336181, 262455, 393539, 262473, 344404, 213333, 418135, 270687, 262497, 418145, 262501, 213354, 246124, 262508, 262512, 213374, 385420, 262551, 262553, 385441, 385444, 262567, 385452, 262574, 393649, 385460, 262587, 344512, 262593, 336326, 360917, 369119, 328178, 328180, 328183, 328190, 254463, 328193, 98819, 164362, 328207, 410129, 393748, 377372, 188959, 385571, 377384, 197160, 33322, 352822, 270905, 197178, 418364, 188990, 369224, 385610, 270922, 352844, 385617, 352865, 262761, 352875, 344694, 352888, 336513, 377473, 336517, 344710, 385671, 148106, 377485, 352919, 98969, 336549, 344745, 361130, 336556, 385714, 434868, 164535, 336568, 164539, 328379, 328387, 352969, 418508, 385743, 385749, 189154, 369382, 361196, 418555, 344832, 336644, 344837, 344843, 328462, 361231, 394002, 336660, 418581, 418586, 434971, 369436, 262943, 369439, 418591, 418594, 336676, 418600, 418606, 271154, 328498, 369464, 361274, 328516, 336709, 328520, 336712, 361289, 328523, 336715, 361300, 213848, 426842, 361307, 197469, 361310, 254813, 361318, 344936, 361323, 361335, 328574, 369544, 222129, 345036, 115661, 386004, 345046, 386012, 386019, 386023, 328690, 435188, 328703, 328710, 418822, 377867, 328715, 386070, 271382, 336922, 345119, 377888, 328747, 214060, 345134, 345139, 361525, 361537, 377931, 197708, 189525, 156762, 402523, 361568, 148580, 345200, 361591, 386168, 361594, 410746, 214150, 345224, 386187, 337048, 345247, 361645, 337072, 345268, 337076, 402615, 361657, 402636, 328925, 165086, 165092, 328933, 222438, 328942, 386286, 386292, 206084, 115973, 328967, 345377, 345380, 353572, 345383, 337207, 345400, 378170, 369979, 386366, 337224, 337230, 337235, 263509, 353634, 337252, 402792, 345449, 99692, 271731, 378232, 337278, 271746, 181639, 353674, 181644, 361869, 181650, 181655, 230810, 181671, 181674, 181679, 181682, 337330, 181687, 370105, 181691, 181697, 361922, 337350, 181704, 337366, 271841, 329192, 361961, 329195, 116211, 337399, 402943, 337416, 329227, 419341, 419345, 329234, 419351, 345626, 419357, 345631, 419360, 370208, 394787, 419363, 370214, 419369, 394796, 419377, 419386, 206397, 214594, 419401, 353868, 419404, 173648, 419408, 214611, 419412, 403040, 345702, 222831, 370298, 353920, 403073, 403076, 345737, 198282, 403085, 403092, 345750, 419484, 345758, 345763, 419492, 345766, 419498, 419502, 370351, 419507, 337588, 419510, 419513, 419518, 403139, 337607, 419528, 419531, 419536, 272083, 394967, 419543, 419545, 345819, 419548, 181982, 419551, 345829, 419560, 337643, 419564, 337647, 370416, 141052, 337661, 337671, 362249, 362252, 395022, 362256, 321300, 345888, 116512, 378664, 354107, 345916, 354112, 247618, 370504, 329545, 345932, 354124, 370510, 247639, 337751, 370520, 313181, 182110, 354143, 354157, 345965, 345968, 345971, 345975, 182136, 403321, 1914, 354173, 395148, 247692, 337809, 247701, 329625, 436127, 436133, 247720, 337834, 362414, 337845, 190393, 247760, 346064, 346069, 329699, 354275, 190440, 247790, 354314, 346140, 337980, 436290, 395340, 378956, 436307, 338005, 329816, 100454, 329833, 329853, 329857, 329868, 411806, 329886, 346273, 362661, 100525, 387250, 379067, 387261, 256193, 395467, 346317, 411862, 256214, 411865, 411869, 411874, 379108, 411877, 387303, 346344, 395496, 338154, 387307, 346350, 338161, 436474, 321787, 379135, 411905, 411917, 43279, 379154, 395539, 387350, 387353, 338201, 182559, 338212, 395567, 248112, 362823, 436556, 321880, 362844, 379234, 354674, 182642, 321911, 420237, 379279, 272787, 354728, 338353, 338363, 338382, 272849, 248279, 256474, 182755, 338404, 338411, 330225, 248309, 199165, 248332, 330254, 199182, 199189, 420377, 330268, 191012, 330320, 199250, 191069, 346722, 248427, 191085, 338544, 191093, 346743, 330384, 346769, 150184, 174775, 248505, 174778, 363198, 223936, 355025, 273109, 264919, 256735, 338661, 338665, 264942, 330479, 363252, 338680, 207620, 264965, 191240, 338701, 256787, 363294, 199455, 396067, 346917, 396070, 215854, 355123, 355141, 355144, 338764, 330581, 330585, 387929, 355167, 265056, 265059, 355176, 355180, 355185, 330612, 330643, 412600, 207809, 379849, 347082, 396246, 330711, 248794, 248799, 437219, 257009, 265208, 330750, 199681, 338951, 330761, 330769, 330775, 248863, 158759, 396329, 347178, 404526, 396337, 330803, 396340, 339002, 388155, 339010, 347208, 248905, 330827, 330830, 248915, 183384, 339037, 412765, 257121, 322660, 265321, 330869, 248952, 420985, 330886, 330890, 347288, 248986, 44199, 380071, 339118, 249018, 339133, 126148, 322763, 330959, 330966, 265433, 265438, 388320, 363757, 388348, 339199, 396552, 175376, 175397, 208167, 273709, 372016, 437553, 347442, 199989, 175416, 396601, 208189, 437567, 175425, 437571, 437576, 437584, 331089, 437588, 396634, 175451, 437596, 429408, 175458, 208228, 175461, 175464, 265581, 331124, 175478, 249210, 175484, 175487, 249215, 175491, 249219, 249225, 249228, 249235, 175514, 175517, 396703, 396706, 175523, 355749, 396723, 388543, 380353, 216518, 339401, 380364, 339406, 372177, 339414, 249303, 413143, 339418, 339421, 249310, 339425, 249313, 339429, 339435, 249329, 69114, 372229, 339464, 249355, 208399, 380433, 175637, 405017, 134689, 339504, 265779, 421442, 413251, 265796, 265806, 224854, 224858, 339553, 257636, 224871, 372328, 257647, 372338, 339572, 224885, 224888, 224891, 224895, 126597, 421509, 224905, 11919, 224911, 224914, 126611, 224917, 224920, 126618, 208539, 224923, 224927, 224930, 224933, 257705, 224939, 224943, 257713, 224949, 257717, 257721, 224954, 257725, 224960, 257733, 224966, 224970, 257740, 224976, 257745, 257748, 224982, 257752, 224987, 257762, 224996, 225000, 339696, 225013, 257788, 225021, 339711, 257791, 225027, 257796, 339722, 257802, 257805, 225039, 257808, 249617, 225044, 167701, 372500, 257815, 225049, 257820, 225054, 184096, 397089, 257825, 225059, 339748, 225068, 257837, 413485, 225071, 225074, 257843, 225077, 257846, 225080, 397113, 225083, 397116, 257853, 225088, 225094, 225097, 323404, 257869, 257872, 225105, 339795, 397140, 225109, 225113, 257881, 257884, 257887, 225120, 257891, 413539, 225128, 257897, 225138, 339827, 257909, 225142, 372598, 257914, 257917, 225150, 257922, 380803, 225156, 339845, 257927, 225166, 397201, 225171, 380823, 225176, 225183, 184245, 372698, 372704, 372707, 356336, 380919, 393215, 372739, 405534, 266295, 266298, 217158, 421961, 200786, 356440, 217180, 430181, 266351, 356467, 266365, 266375, 381069, 225425, 250003, 225430, 250008, 356507, 250012, 225439, 135328, 192674, 225442, 438434, 225445, 225448, 438441, 225451, 258223, 225456, 430257, 225459, 225462, 225468, 389309, 225472, 372931, 225476, 389322, 225485, 225488, 225491, 266454, 225494, 225497, 225500, 225503, 225506, 356580, 225511, 217319, 225515, 225519, 381177, 397572, 389381, 356631, 356638, 356641, 356644, 356647, 266537, 389417, 356650, 356656, 332081, 307507, 340276, 356662, 397623, 332091, 225599, 332098, 201030, 348489, 332107, 151884, 430422, 348503, 332118, 250203, 332130, 250211, 340328, 250217, 348523, 348528, 332153, 356734, 389503, 332158, 438657, 332162, 389507, 348548, 356741, 250239, 332175, 160152, 373146, 373149, 70048, 356783, 266688, 324032, 201158, 340452, 127473, 217590, 340473, 324095, 324100, 324103, 324112, 340501, 324118, 324122, 340512, 332325, 324134, 381483, 356908, 324141, 324143, 356917, 324150, 324156, 168509, 348734, 324161, 324165, 356935, 348745, 381513, 324171, 324174, 324177, 389724, 332381, 373344, 340580, 348777, 381546, 119432, 340628, 184983, 373399, 340639, 258723, 332455, 332460, 332464, 332473, 381626, 332484, 332487, 332494, 357070, 357074, 332512, 332521, 340724, 332534, 373499, 348926, 389927, 348979, 152371, 398141, 127815, 357202, 389971, 357208, 136024, 389979, 430940, 357212, 357215, 201580, 201583, 349041, 340850, 201589, 381815, 430967, 324473, 398202, 119675, 340859, 324476, 430973, 324479, 340863, 324482, 324485, 324488, 185226, 381834, 324493, 324496, 324499, 430996, 324502, 324511, 422817, 324514, 201638, 398246, 373672, 324525, 5040, 111539, 324534, 5047, 324539, 324542, 398280, 349129, 340940, 340942, 209874, 340958, 431073, 398307, 340964, 209896, 201712, 209904, 349173, 381947, 201724, 349181, 431100, 431107, 349203, 209944, 209948, 250915, 250917, 169002, 357419, 209966, 209969, 209973, 209976, 209980, 209988, 209991, 431180, 209996, 349268, 177238, 250968, 210011, 373853, 341094, 210026, 210028, 210032, 349296, 210037, 210042, 210045, 349309, 152704, 349313, 160896, 210053, 210056, 349320, 259217, 373905, 210068, 210072, 210078, 210081, 210085, 210089, 210096, 210100, 324792, 210108, 357571, 210116, 210128, 333010, 210132, 333016, 210139, 210144, 218355, 251123, 218361, 275709, 128254, 275713, 242947, 275717, 275723, 333075, 349460, 333079, 251161, 349486, 349492, 415034, 251211, 210261, 365912, 259423, 374113, 251236, 374118, 234867, 390518, 357756, 374161, 112021, 349591, 357793, 333222, 210357, 259516, 415168, 366035, 415187, 366039, 415192, 415194, 415197, 415200, 333285, 415208, 366057, 366064, 415217, 415225, 423424, 415258, 415264, 366118, 415271, 382503, 349739, 144940, 415279, 415282, 415286, 210488, 415291, 415295, 333387, 333396, 333400, 366173, 333415, 423529, 423533, 333423, 210547, 415354, 333440, 267910, 267929, 333472, 333512, 259789, 358100, 366301, 333535, 366308, 366312, 431852, 399086, 366319, 210673, 366322, 399092, 366326, 333566, 268042, 210700, 366349, 210707, 399129, 333593, 333595, 210720, 366384, 358192, 210740, 366388, 358201, 399166, 325441, 366403, 325447, 341831, 341835, 341839, 341844, 415574, 358235, 341852, 350046, 399200, 399208, 268144, 358256, 358260, 399222, 325494, 186233, 333690, 243584, 325505, 333699, 399244, 333709, 333725, 333737, 382891, 382898, 333767, 358348, 333777, 219094, 358372, 350190, 350194, 333819, 350204, 350207, 325633, 325637, 350214, 268299, 333838, 350225, 350232, 333851, 350238, 350241, 374819, 350245, 350249, 350252, 178221, 350257, 350260, 350272, 243782, 350281, 350286, 374865, 252021, 342134, 374904, 268435, 333989, 333998, 334012, 260299, 350411, 350417, 350423, 211161, 350426, 334047, 350449, 375027, 358645, 350454, 350459, 350462, 350465, 350469, 325895, 268553, 194829, 350477, 268560, 350481, 432406, 350487, 350491, 350494, 325920, 350500, 350505, 358701, 391469, 350510, 358705, 358714, 358717, 383307, 358738, 334162, 383331, 383334, 391531, 383342, 334204, 268669, 194942, 391564, 366991, 334224, 342431, 375209, 326059, 375220, 342453, 334263, 326087, 358857, 195041, 334306, 334312, 104940, 375279, 162289, 350724, 186898, 342546, 350740, 342551, 334359, 342555, 334364, 416294, 350762, 252463, 358962, 334386, 334397, 358973, 252483, 219719, 399957, 244309, 334425, 326240, 375401, 334466, 334469, 391813, 162446, 326291, 342680, 342685, 260767, 342711, 244410, 260798, 334530, 260802, 350918, 154318, 342737, 391895, 154329, 416476, 64231, 113389, 342769, 203508, 375541, 342777, 391938, 391949, 375569, 375572, 375575, 375580, 162592, 334633, 326444, 383794, 326452, 326455, 375613, 244542, 260925, 375616, 326468, 244552, 342857, 326474, 326479, 326486, 416599, 342875, 244572, 326494, 326503, 433001, 326508, 400238, 326511, 211826, 211832, 392061, 351102, 252801, 260993, 400260, 211846, 342921, 342931, 252823, 400279, 392092, 400286, 359335, 211885, 400307, 351169, 359362, 351172, 170950, 187335, 326599, 359367, 359383, 359389, 383968, 343018, 359411, 261109, 261112, 244728, 383999, 261130, 261148, 359452, 211999, 261155, 261160, 261166, 359471, 375868, 384099, 384102, 384108, 367724, 326764, 187503, 343155, 384115, 212095, 384136, 384140, 384144, 351382, 384152, 384158, 384161, 351399, 384169, 367795, 244917, 384182, 384189, 384192, 351424, 343232, 244934, 367817, 244938, 384202, 253132, 326858, 343246, 384209, 146644, 351450, 384225, 359650, 343272, 351467, 359660, 384247, 351480, 384250, 351483, 351492, 343307, 384270, 359695, 261391, 253202, 261395, 384276, 384284, 245021, 384290, 253218, 245032, 171304, 384299, 351535, 245042, 326970, 384324, 343366, 212296, 212304, 367966, 343394, 343399, 367981, 343410, 155000, 327035, 245121, 245128, 253321, 155021, 384398, 245137, 245143, 245146, 245149, 343453, 245152, 245155, 155045, 245158, 40358, 245163, 114093, 327090, 343478, 359867, 384444, 146878, 327108, 327112, 384457, 327118, 359887, 359891, 343509, 368093, 155103, 343535, 343540, 368120, 343545, 409092, 359948, 359951, 245295, 359984, 400977, 400982, 179803, 155241, 138865, 155255, 155274, 368289, 245410, 425639, 245415, 425652, 425663, 155328, 245463, 155352, 155356, 212700, 155364, 245477, 155372, 245487, 212723, 245495, 409336, 155394, 155404, 245528, 155423, 360224, 155439, 204592, 155444, 155448, 417596, 384829, 360262, 155463, 155477, 376665, 155484, 261982, 425823, 155488, 376672, 155492, 327532, 261997, 376686, 262000, 262003, 425846, 262006, 147319, 262009, 327542, 262012, 155517, 155523, 155526, 360327, 376715, 155532, 262028, 262031, 262034, 262037, 262040, 262043, 155550, 253854, 262046, 262049, 262052, 327590, 155560, 155563, 155566, 327613, 393152, 311244, 212945, 393170, 155604, 155620, 253924, 155622, 253927, 327655, 360432, 393204, 360439, 253944, 393209, 155647 ]
8a4355002049e71a9a6ff3363e70a5bd2b909d90
e60fb5ed39386cbc44cabf8c4daee349493e332b
/Synonym/ViewController.swift
ab91cb4c66fb245afed2ab0ff7a1bb52f56dcca4
[]
no_license
tben2010/Synonym
99c80ded3c6a706851096fc37fb88c4a40183280
66adee68fdbd7aae17216e7177439a345d9aae7c
refs/heads/master
2021-01-10T02:52:48.388478
2016-02-19T12:03:41
2016-02-19T12:03:41
52,063,219
0
0
null
null
null
null
UTF-8
Swift
false
false
2,205
swift
// // ViewController.swift // Synonym // // Created by tben on 19.02.16|KW7. // Copyright © 2016 tben. All rights reserved. // import UIKit class ViewController: UIViewController, UITableViewDataSource, UITableViewDelegate { //MARK: - Outlets @IBOutlet weak var tabelView: UITableView! @IBOutlet weak var searchText: UITextField! //MARK: - Actions @IBAction func searchSynonym(sender: AnyObject) { if searchText.text != nil { getSynonyms(searchText.text!) } } override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. tabelView.delegate = self tabelView.dataSource = self title = NSLocalizedString("synonymTile", comment: "Title in Search View Controller") } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } //MARK: - UITableViewDataSource func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return 5 } func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { let cell = tableView.dequeueReusableCellWithIdentifier("synonymCell", forIndexPath: indexPath) cell.textLabel?.text = "Zeile \(indexPath.row)" return cell } //MARK: - Methoden func getSynonyms(searchText:String){ var foundedSynonyms = [String]() let jsonDictionary = fetchSynonyms(searchText) } func fetchSynonyms(searchText:String) -> NSDictionary { let apiUrl = NSURL(string: "https://www.openthesaurus.de/synonyme/search?q=\(searchText)&format=application/json") let jsonRespones = NSData(contentsOfURL: apiUrl!) var jsonDict: NSDictionary = [:] do { jsonDict = try NSJSONSerialization.JSONObjectWithData(jsonRespones!, options: []) as! NSDictionary }catch { print(error) } return jsonDict } }
[ -1 ]