repo_name
stringlengths
6
91
path
stringlengths
6
999
copies
stringclasses
283 values
size
stringlengths
1
7
content
stringlengths
3
1.05M
license
stringclasses
15 values
notbakaneko/JsonType
JsonType/JsonType.swift
1
5955
// // JsonType.swift // JsonType // // Created by bakaneko on 6/02/2015. // Copyright (c) 2015 bakaneko. All rights reserved. // import Foundation public enum JsonType { case DictionaryType(NSDictionary) case ArrayType(NSArray) case StringType(String) case NumberType(NSNumber) case BoolType(B...
mit
mrdepth/Neocom
Legacy/Neocom/Neocom/NCAccountsFolderPickerViewController.swift
2
370
// // NCAccountsFolderPickerViewController.swift // Neocom // // Created by Artem Shimanski on 04.08.17. // Copyright © 2017 Artem Shimanski. All rights reserved. // import UIKit import CoreData class NCAccountsFolderPickerViewController: NCNavigationController { var completionHandler: ((NCAccountsFolderPicker...
lgpl-2.1
fschneider1509/RuleBasedXMLParserDelegate
RuleBasedXMLParserDelegateKit/XMLParserDelegateError.swift
1
278
// // XMLParserDelegateError.swift // RuleBasedXMLParserDelegate // // Created by Fabian Schneider // fabian(at)fabianschneider.org // MIT License // import Foundation enum XMLParserDelegateError : Error { case elementParsingError(message: String, element: String) }
mit
venmo/Static
Sources/Static/ButtonCell.swift
1
661
import UIKit @objc(STCButtonCell) open class ButtonCell: UITableViewCell, Cell { // MARK: - Initializers public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) { super.init(style: .default, reuseIdentifier: reuseIdentifier) initialize() } public required ini...
mit
NathanE73/Blackboard
Tests/BlackboardFrameworkTests/Color Assets/AssetColorSetTests.swift
1
2217
// // Copyright (c) 2022 Nathan E. Walczak // // MIT License // // 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...
mit
ZhangHangwei/100_days_Swift
Project_01/Project_1/ViewController.swift
1
688
// // ViewController.swift // Project_1 // // Created by 章航伟 on 15/01/2017. // Copyright © 2017 章航伟. All rights reserved. // import UIKit class ViewController: UIViewController { @IBOutlet weak var numberLabel: UILabel! override func viewDidLoad() { super.viewDidLoad() // Do any...
mit
KrishMunot/swift
test/Inputs/clang-importer-sdk/swift-modules-without-ns/Foundation.swift
5
5540
@_exported import ObjectiveC @_exported import CoreGraphics @_exported import Foundation @_silgen_name("swift_StringToNSString") internal func _convertStringToNSString(_ string: String) -> NSString @_silgen_name("swift_NSStringToString") internal func _convertNSStringToString(_ nsstring: NSString?) -> String public ...
apache-2.0
ruslanskorb/CoreStore
CoreStoreDemo/CoreStoreDemo/List and Object Observers Demo/Palette.swift
1
2343
// // Palette.swift // CoreStoreDemo // // Created by John Rommel Estropia on 2015/05/05. // Copyright © 2018 John Rommel Estropia. All rights reserved. // import Foundation import UIKit import CoreData import CoreStore // MARK: - Palette final class Palette: CoreStoreObject { let hue = Value.Required<...
mit
tkremenek/swift
validation-test/StdlibUnittest/Stdin.swift
19
1479
// RUN: %target-run-simple-swift // REQUIRES: executable_test import StdlibUnittest #if canImport(Darwin) import Darwin #elseif canImport(Glibc) import Glibc #elseif os(Windows) import MSVCRT #else #error("Unsupported platform") #endif func simple_getline() -> [UInt8]? { var result = [UInt8]() while true ...
apache-2.0
aguptaadco/cordoba-plugin-iosrtc
src/PluginEnumerateDevices.swift
1
1808
import Foundation import AVFoundation /** * Doc: https://developer.apple.com/library/mac/documentation/AVFoundation/Reference/AVCaptureDevice_Class/index.html */ class PluginEnumerateDevices { class func call(callback: (data: NSDictionary) -> Void) { NSLog("PluginEnumerateDevices#call()") ...
mit
TalkingBibles/Talking-Bible-iOS
TalkingBible/String+extensions.swift
1
848
// // Copyright 2015 Talking Bibles International // // 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 applicabl...
apache-2.0
radex/swift-compiler-crashes
crashes-fuzzing/22050-swift-funcdecl-setdeserializedsignature.swift
11
266
// Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing let a { func f: CollectionType class a { { { } } struct Q<T where T: P { class B<T where H.c = g
mit
appsquickly/TyphoonRestClient-Demos
TyphoonRestClientDemoSwift/TyphoonRestClientDemoSwift/AppDelegate.swift
1
2400
//////////////////////////////////////////////////////////////////////////////// // // APPS QUICKLY // Copyright 2015 Apps Quickly Pty Ltd // All Rights Reserved. // // NOTICE: Prepared by AppsQuick.ly on behalf of Apps Quickly. This software // is proprietary information. Unauthorized use is prohibited. // //////...
apache-2.0
shorlander/firefox-ios
Client/Frontend/Share/FindInPageActivity.swift
7
837
/* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ import Foundation class FindInPageActivity: UIActivity { fileprivate let callback: () -> Void init(callb...
mpl-2.0
kylef/CommandKit
Examples/generator.swift
1
545
#!/usr/bin/swift -FRome import Commander import Stencil import PathKit command( Option("amount", default: 15, description: "The number of arguments to support.") ) { amount in let template = try Template(path: Path("generator-template.swift")) let structure = (1..<amount).map { return [ "count": $0, ...
bsd-3-clause
LesCoureurs/Courir
Courir/Courir/ScoreSpriteNode.swift
1
2517
// // ScoreSpriteNode.swift // Courir // // Created by Sebastian Quek on 8/4/16. // Copyright © 2016 NUS CS3217. All rights reserved. // import SpriteKit class ScoreSpriteNode: SKSpriteNode { // ============================================== // Static variables and methods // ====================...
mit
vamsiac/AsyncImageView
Examples/BasicExample/BasicExampleTests/BasicExampleTests.swift
1
997
// // BasicExampleTests.swift // BasicExampleTests // // Created by Vamsi Chaitanya on 10/20/16. // Copyright © 2016 Vamsi Anguluru. All rights reserved. // import XCTest @testable import BasicExample class BasicExampleTests: XCTestCase { override func setUp() { super.setUp() // Put setup...
mit
wordpress-mobile/WordPress-iOS
WordPress/Classes/Models/TagsCategoriesStatsRecordValue+CoreDataClass.swift
2
3402
import Foundation import CoreData public enum TagsCategoriesType: Int16 { case tag case category case folder } public class TagsCategoriesStatsRecordValue: StatsRecordValue { public var linkURL: URL? { guard let url = urlString as String? else { return nil } retur...
gpl-2.0
jtbandes/swift-compiler-crashes
fixed/26932-swift-typebase-isequal.swift
4
205
// Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing {<n var d{var d{{ func b{{let:{(a=c
mit
buddax2/tmpNote
LauncherApplication/AppDelegate.swift
1
1751
// // AppDelegate.swift // LauncherApplication // // Created by BUDDAx2 on 9/25/17. // Copyright © 2017 BUDDAx2. All rights reserved. // import Cocoa @NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate { func applicationDidFinishLaunching(_ aNotification: Notification) { // Insert...
mit
kickstarter/ios-oss
Library/ViewModels/LandingPageCardType.swift
1
2181
public enum LandingPageCardType { case allOrNothing case discoverProjects case successfulProjects case totalBackers case totalPledged case trackBackings public static var statsCards: [LandingPageCardType] { return [.totalPledged, .successfulProjects, .totalBackers] } public static var howToCards...
apache-2.0
mathcamp/Carlos
Tests/DispatchedCacheTests.swift
1
6694
import Foundation import Quick import Nimble import Carlos import PiedPiper var kCurrentQueue = 0 func getMutablePointer (object: AnyObject) -> UnsafeMutablePointer<Void> { return UnsafeMutablePointer<Void>(bitPattern: Int(ObjectIdentifier(object).uintValue)) } struct DispatchedShareExamplesContext { static let ...
mit
Eric217/-OnSale
打折啦/打折啦/ESTabBar.swift
1
16390
// // ESTabBar.swift // // Created by Vincent Li on 2017/2/8. // Copyright (c) 2013-2017 ESTabBarController (https://github.com/eggswift/ESTabBarController) // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to...
apache-2.0
lenssss/whereAmI
Whereami/Manager/SettingUpManager.swift
1
9814
// // SettingUpManager.swift // Whereami // // Created by WuQifei on 16/2/4. // Copyright © 2016年 WuQifei. All rights reserved. // import Foundation import UIKit import ReactiveCocoa import MagicalRecord import SVProgressHUD import SocketIOClientSwift public var KNotificationLogin: String { get{ return "KNotifica...
mit
zom/Zom-iOS
Zom/Zom/Classes/View Controllers/Onboarding/ZomCongratsViewController.swift
1
4730
// // ZomCongratsViewController.swift // Zom // // Created by N-Pex on 2017-01-24. // // import UIKit import ChatSecureCore import MobileCoreServices open class ZomCongratsViewController: UIViewController { @IBOutlet weak var avatarImageView:UIButton! open var account:OTRAccount? { didSet { ...
mpl-2.0
amit-sgwn/Pitch-Perfect
Pitch PerfectTests/Pitch_PerfectTests.swift
1
980
// // Pitch_PerfectTests.swift // Pitch PerfectTests // // Created by Amit on 01/09/17. // Copyright © 2017 Amit. All rights reserved. // import XCTest @testable import Pitch_Perfect class Pitch_PerfectTests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This ...
gpl-3.0
liyoro/LIPAImageView
Demo/LIPAImageView/LIPAImageView/AppDelegate.swift
1
2142
// // AppDelegate.swift // LIPAImageView // // Created by liyoro on 15/7/28. // Copyright (c) 2015年 liyoro. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, didFinishLaunchi...
mit
openHPI/xikolo-ios
Common/Logger.swift
1
1864
// // Created for xikolo-ios under GPL-3.0 license. // Copyright © HPI. All rights reserved. // import os let logger = Logger(subsystem: "de.xikolo.common", category: "Common") public struct Logger { private let log: OSLog public init(subsystem: String, category: String) { self.log = OSLog(subsys...
gpl-3.0
WorldDownTown/Kintai
KintaiUITests/KintaiUITests.swift
1
1185
// // KintaiUITests.swift // KintaiUITests // // Created by shoji on 2015/11/29. // // import XCTest class KintaiUITests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This method is called before the invocation of each test method in the class. ...
mit
CocoaHeadsConference/CHConferenceApp
NSBrazilConf/Extensions/Image+SFSymbols.swift
1
341
// // Image+SFSymbols.swift // NSBrazilConf // // Created by Mauricio Cardozo on 1/18/21. // Copyright © 2021 Cocoaheadsbr. All rights reserved. // import SwiftUI enum SystemImage: String { case linkCircle = "link.circle" } extension Image { init(_ image: SystemImage) { self.init(systemName: imag...
mit
daniel-barros/ExtendedFoundation
Sources/Extensions/Array.swift
2
2000
// // Array.swift // ExtendedFoundation // // Created by Daniel Barros López on 11/5/16. // // Copyright (c) 2016 - 2017 Daniel Barros López // // 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 th...
mit
josercc/ZHTableViewGroupSwift
Sources/SwiftTableViewGroup/UICollectionView/CollectionSection.swift
1
1083
// // CollectionSection.swift // // // Created by 张行 on 2019/7/17. // import UIKit.UICollectionViewCell public struct CollectionSection : DataNode { public var header:CollectionHeaderView? public var footer:CollectionFooterView? public var cells:[CollectionCell] = [CollectionCell]() public init(@C...
mit
chadoneba/MTools
MTools/Classes/Base/Views.swift
1
379
// // Views.swift // Pods // // Created by Mikhail Maltsev on 18.09.17. // // import Foundation public extension UIView { public class func loadFromNibNamed(nibNamed: String, bundle : Bundle? = nil) -> UIView? { return UINib( nibName: nibNamed, bundle: bundle ).insta...
mit
psobot/hangover
Hangover/Channel.swift
1
16244
// // Channel.swift // Hangover // // Created by Peter Sobot on 5/26/15. // Copyright (c) 2015 Peter Sobot. All rights reserved. // import Foundation import Alamofire import JavaScriptCore protocol ChannelDelegate { func channelDidConnect(channel: Channel) func channelDidDisconnect(channel: Channel) f...
mit
goblinr/omim
iphone/Maps/UI/Search/Filters/FilterCollectionHolderCell.swift
1
1045
@objc(MWMFilterCollectionHolderCell) final class FilterCollectionHolderCell: MWMTableViewCell { @IBOutlet weak var collectionView: UICollectionView! @IBOutlet private weak var collectionViewHeight: NSLayoutConstraint! private weak var tableView: UITableView? override var frame: CGRect { didSet { if fr...
apache-2.0
yagiz/Bagel
mac/Bagel/Workers/BagelController/Models/KeyValue.swift
1
329
// // KeyValue.swift // Bagel // // Created by Yagiz Gurgul on 21.10.2018. // Copyright © 2018 Yagiz Lab. All rights reserved. // import Cocoa class KeyValue: Codable { var key: String? var value: String? init(key: String?, value: String?) { self.key = key self.value = value ...
apache-2.0
quadro5/swift3_L
swift_question.playground/Pages/Dictionary.xcplaygroundpage/Contents.swift
1
668
//: [Previous](@previous) import Foundation var str = "Hello, playground" //: [Next](@next) var dict1 = Dictionary<Int, Int>() // contain if dict1[3] != nil { print("dict1 has key 3") } else { print("dict1 has not key 3") } var dict2 = Dictionary<Int, Int?>() dict2[3] = nil dict2.count if dict2[3] != ...
unlicense
littlelightwang/firefox-ios
Providers/ProfilePrefs.swift
2
2806
/* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ import Foundation public protocol ProfilePrefs { func setObject(value: AnyObject?, forKey defaultName: String...
mpl-2.0
Antidote-for-Tox/Antidote
Antidote/TabBarBadgeItem.swift
1
5362
// This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/. import UIKit import SnapKit private struct Constants { static let ImageAndTextContainerYOffset = 2.0 static ...
mpl-2.0
bizz84/SwiftyStoreKit
Sources/SwiftyStoreKit/SKProductDiscount+LocalizedPrice.swift
1
3060
// // SKProductDiscount+LocalizedPrice.swift // SwiftyStoreKit // // Created by Sam Spencer on 5/29/20. // Copyright © 2020 Sam Spencer. All rights reserved. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to...
mit
FabrizioBrancati/SwiftyBot
Sources/Messenger/Activation/Activation.swift
1
3032
// // Activation.swift // SwiftyBot // // The MIT License (MIT) // // Copyright (c) 2016 - 2019 Fabrizio Brancati. // // 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 restric...
mit
kirkvogen/masterdetail-j2objc-swift
masterdetail-ios/masterdetail-ios/MasterViewController.swift
1
5498
// // Copyright 2014-2015 Kirk C. Vogen // // 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 agr...
apache-2.0
practicalswift/swift
stdlib/public/core/SIMDVector.swift
2
30784
infix operator .== : ComparisonPrecedence infix operator .!= : ComparisonPrecedence infix operator .< : ComparisonPrecedence infix operator .<= : ComparisonPrecedence infix operator .> : ComparisonPrecedence infix operator .>= : ComparisonPrecedence // Not used in the stdlib, but declared here so the declarations are...
apache-2.0
practicalswift/swift
test/SILGen/without_actually_escaping_block.swift
25
1092
// RUN: %empty-directory(%t) // RUN: %build-silgen-test-overlays // RUN: %target-swift-emit-silgen(mock-sdk: -sdk %S/Inputs -I %t) -module-name without_actually_escaping %s -sdk %S/Inputs -enable-objc-interop | %FileCheck %s // REQUIRES: objc_interop import Foundation typealias Callback = @convention(block) () -> Vo...
apache-2.0
blockchain/My-Wallet-V3-iOS
Modules/FeatureActivity/Sources/FeatureActivityData/DIKit.swift
1
493
// Copyright © Blockchain Luxembourg S.A. All rights reserved. import DIKit import FeatureActivityDomain import PlatformKit extension DependencyContainer { // MARK: - FeatureInterestData Module public static var featureActivityDataKit = module { // MARK: - Data factory { APIClient() as Int...
lgpl-3.0
toshiapp/toshi-ios-client
Toshi/Resources/DevelopmentTokenURLPaths.swift
1
1301
// Copyright (c) 2018 Token Browser, Inc // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // This program is di...
gpl-3.0
blockchain/My-Wallet-V3-iOS
Modules/FeatureInterest/Sources/FeatureInterestDomain/TransactionEngines/InterestDepositTradingTransactionEngine.swift
1
9028
// Copyright © Blockchain Luxembourg S.A. All rights reserved. import Combine import DIKit import FeatureProductsDomain import FeatureTransactionDomain import MoneyKit import PlatformKit import RxSwift import ToolKit /// Transaction Engine for Interest Deposit from a Trading Account. public final class InterestDeposi...
lgpl-3.0
NeoGolightly/CartographyKit
CartographyKit/Sizes.swift
1
1142
// // Sizes.swift // CartographyKit iOS // // Created by Michael Helmbrecht on 07/01/2018. // #if os(iOS) || os(tvOS) import UIKit #else import AppKit #endif import Cartography //Sizes private protocol BasicSizes{ static func width(_ view: View) -> NSLayoutConstraint? static func height(_ view: View) -> NS...
mit
gaurav1981/Swiftz
Swiftz/List.swift
1
12486
// // List.swift // swiftz_core // // Created by Maxwell Swadling on 3/06/2014. // Copyright (c) 2014 Maxwell Swadling. All rights reserved. // /// An enum representing the possible values a list can match against. public enum ListMatcher<A> { /// The empty list. case Nil /// A cons cell. case Cons(A, List<A>)...
bsd-3-clause
lincoly/LLDropDownMenuSwift
core/LLDropDownMenu.swift
1
31956
// // LLDropDownMenu.swift // LLDropDownMenuViewSwift // // Created by lin on 2017/3/7. // Copyright © 2017年 lin. All rights reserved. // import UIKit struct LLIndexPath { var corlumn : Int! var row : Int? var item : Int? var index : Int? var selectedText = "" } protocol LLDropDownMenuDelegat...
mit
amrap-labs/TeamupKit
Sources/TeamupKit/Controllers/Account/Memberships/MembershipsController.swift
1
963
// // MembershipsController.swift // TeamupKit // // Created by Merrick Sapsford on 20/06/2017. // Copyright © 2017 Merrick Sapsford. All rights reserved. // import Foundation public protocol MembershipsController: class, PageableController { /// Load all memberships associated with the current user. ...
mit
johntvolk/TableViewConfigurator
TableViewConfigurator/Classes/ModelRowConfiguration.swift
1
8789
// // ModelRowConfiguration.swift // Pods // // Created by John Volk on 3/1/16. // Copyright © 2016 John Volk. All rights reserved. // import UIKit import Dwifft public protocol RowModel: class, Equatable { var identityTag: String? { get set } } public func == <T: RowModel>(lhs: T, rhs: T) -> Bool ...
mit
chrisjmendez/swift-exercises
Concurrency/Operational Queues/Concurrency/AppDelegate.swift
1
2155
// // AppDelegate.swift // Concurrency // // Created by tommy trojan on 4/11/15. // Copyright (c) 2015 Skyground Media Inc. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, d...
mit
Ryce/flickrpickr
Carthage/Checkouts/judokit/Tests/PreAuthTests.swift
2
8600
// // PreAuthTests.swift // JudoTests // // Copyright (c) 2016 Alternative Payments Ltd // // 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 limi...
mit
IBM-MIL/IBM-Ready-App-for-Venue
iOS/Venue/DataSources/UserDataManager.swift
1
4520
/* Licensed Materials - Property of IBM © Copyright IBM Corporation 2015. All Rights Reserved. */ /** * Asks ManagerHelper to initiate a resource request to get authorized User data */ class UserDataManager: NSObject { var oneUserCallback: ((User)->())! /// Callback object to return data to the requesti...
epl-1.0
Dith3r/FrameworkBenchmarks
frameworks/Swift/swift-nio/Package.swift
1
413
// swift-tools-version:4.0 // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription let package = Package( name: "SwiftNIOTFB", dependencies: [ .package(url: "https://github.com/apple/swift-nio.git", from: "2.0.0"), ], targets: ...
bsd-3-clause
SoySauceLab/CollectionKit
Sources/Addon/SpaceProvider.swift
1
1009
// // SpaceProvider.swift // CollectionKit // // Created by Luke Zhao on 2017-07-23. // Copyright © 2017 lkzhao. All rights reserved. // import UIKit open class SpaceProvider: EmptyCollectionProvider { public enum SpaceSizeStrategy { case fill case absolute(CGFloat) } open var sizeStrategy: (SpaceSi...
mit
nanoxd/Bourne
Tests/BourneTests/StringExtensionTests.swift
1
1884
import Foundation import XCTest @testable import Bourne class StringExtensionTests: XCTestCase { func testStringThrow() throws { let array = JSON([1, 2, 3]) XCTAssertThrowsError(try String.decode(array)) } func testNilString() { let optional: String? = nil XCTAssertEqual(JS...
mit
yangligeryang/codepath
labs/HamburgerDemo/HamburgerDemoUITests/HamburgerDemoUITests.swift
1
1258
// // HamburgerDemoUITests.swift // HamburgerDemoUITests // // Created by Yang Yang on 11/1/16. // Copyright © 2016 Yang Yang. All rights reserved. // import XCTest class HamburgerDemoUITests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This met...
apache-2.0
ibm-bluemix-mobile-services/bms-samples-ios-bluelist
bluelist-swift/bluelist-swift/AuthenticationViewController.swift
1
11932
// Copyright 2014, 2015 IBM Corp. All Rights Reserved. // // 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...
apache-2.0
bitboylabs/selluv-ios
selluv-ios/Pods/SwifterSwift/Source/Extensions/UIKit/UISliderExtensions.swift
5
962
// // UISliderExtensions.swift // SwifterSwift // // Created by Omar Albeik on 9/28/16. // Copyright © 2016 Omar Albeik. All rights reserved. // #if os(iOS) import UIKit // MARK: - Methods public extension UISlider { /// SwifterSwift: Set slide bar value with completion handler. /// /// - Parameters: /// ...
mit
irlabs/ActionKit
ActionKit/UIBarButtonItem+ActionKit.swift
1
6761
// // UIBarButtonItem+ActionKit.swift // ActionKit // // Created by Manue on 30/6/16. // Copyright © 2016 ActionKit. All rights reserved. // import Foundation import UIKit private extension Selector { static let runBarButtonItem = #selector(UIBarButtonItem.runActionKitVoidClosure) } /** Extension to provide c...
mit
SwiftKit/Reactant
Example/Application/Sources/Wireframe/MainWireframe.swift
2
1653
// // MainWireframe.swift // Reactant // // Created by Matous Hybl on 3/24/17. // Copyright © 2017 Brightify s.r.o. All rights reserved. // import Reactant class MainWireframe: Wireframe { private let dependencyModule: DependencyModule init(dependencyModule: DependencyModule) { self.dependencyMo...
mit
austinzheng/swift-compiler-crashes
crashes-duplicates/18529-swift-sourcemanager-getmessage.swift
11
236
// Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing for b : { init( ) { case { let a { deinit { class a { class case ,
mit
audiokit/AudioKit
Tests/AudioKitTests/Node Tests/Generator Tests/ShakerTests.swift
2
1196
// Copyright AudioKit. All Rights Reserved. Revision History at http://github.com/AudioKit/AudioKit/ import XCTest import AudioKit import CAudioKit class ShakerTests: XCTestCase { func testShaker() { let engine = AudioEngine() akSetSeed(0) let shaker = Shaker() shaker.trigger(ty...
mit
dmitriy-shmilo/portfolio-app
ios/Portfolio App/Portfolio App/Data/Profile.swift
1
1173
// // PAProfile.swift // Portfolio App // // Created by Dmitriy Shmilo on 10/14/17. // Copyright © 2017 Dmitriy Shmilo. All rights reserved. // import Foundation /** Represents information about a user. */ class Profile : CustomStringConvertible { init(firstName:String, lastName:String, title:String, b...
mit
danielmartin/swift
stdlib/public/core/SequenceAlgorithms.swift
1
33258
//===--- SequenceAlgorithms.swift -----------------------------*- swift -*-===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
apache-2.0
prccaraujo/openwhisk
core/swift3Action/spm-build/Package.swift
3
1242
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
apache-2.0
LukaszLiberda/Swift-Design-Patterns
PatternProj/Examples/ChainOfResponsibilityPattern.swift
1
7386
// // ChainOfResponsibilityEx1.swift // // // Created by lukasz on 05/07/15. // // import UIKit import Swift import Foundation // Design Pattern // Behavioral /* --- Chain of responsibility delegates commands to a chain of processing objects. In object-oriented design, the chain-of-responsibility pattern is a ...
gpl-2.0
wongzigii/SwiftyJSON
Tests/SwiftyJSONTests/StringTests.swift
3
2684
// StringTests.swift // // Copyright (c) 2014 - 2017 Pinglin Tang // // 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 // t...
mit
EstefaniaGilVaquero/ciceIOS
App_TableView_Estatica/App_TableView_Estatica/AppDelegate.swift
1
2143
// // AppDelegate.swift // App_TableView_Estatica // // Created by cice on 20/6/16. // Copyright © 2016 cice. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(application: UIApplication, didFinishLaunc...
apache-2.0
buscarini/vitemo
vitemo/Carthage/Checkouts/GRMustache.swift/MustacheTests/Public/ServicesTests/LocalizerTests.swift
4
7307
// The MIT License // // Copyright (c) 2015 Gwendal Roué // // 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, mo...
mit
AngryLi/note-iOS
iOS/Demos/Assignments_swift/assignment-2-wechat/swift课堂/Smashtag/Smashtag/TweetTableViewCell.swift
6
1859
// // TweetTableViewCell.swift // Smashtag // // Created by CS193p Instructor. // Copyright (c) 2015 Stanford University. All rights reserved. // import UIKit class TweetTableViewCell: UITableViewCell { var tweet: Tweet? { didSet { updateUI() } } @IBOutlet weak var twe...
mit
paulz/PerspectiveTransform
Example/PerspectiveTransform/Visual.playground/Sources/QuadrilateralCalc.swift
1
4169
import UIKit public class QuadrilateralCalc { public init() {} public var topLeft = CGPoint.zero public var topRight = CGPoint.zero public var bottomLeft = CGPoint.zero public var bottomRight = CGPoint.zero public func box() -> CGRect { let xmin = min(min(min(topRight.x, topLeft.x), b...
mit
JoshHenderson/Flatline
Flatline/Response/BaseDataMapper/BaseResponseDataMapper.swift
1
2351
// // BaseResponseDataMapper.swift // Flatline // // Created by Joshua Henderson on 6/30/16. // Copyright © 2016 Joshua Henderson. All rights reserved. // import Foundation let defaultErrorDomain: String = "com.base.response.mapper.default.error" let defaultErrorCode: Int = 601 /** Protocol used to define Re...
mit
kripple/bti-watson
ios-app/Carthage/Checkouts/AlamofireObjectMapper/Carthage/Checkouts/ObjectMapper/ObjectMapper/Core/Operators.swift
13
13944
// // Operators.swift // ObjectMapper // // Created by Tristan Himmelman on 2014-10-09. // Copyright (c) 2014 hearst. All rights reserved. // /** * This file defines a new operator which is used to create a mapping between an object and a JSON key value. * There is an overloaded operator definition for each type o...
mit
microeditionbiz/reddit-client
reddit-client/reddit-client/AppDelegate.swift
1
1102
// // AppDelegate.swift // reddit-client // // Created by Pablo Romero on 1/18/17. // Copyright © 2017 Pablo Romero. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFin...
mit
cnoon/swift-compiler-crashes
crashes-duplicates/21011-no-stacktrace.swift
11
221
// Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing for { extension NSSet { { { } } init { class case ,
mit
cloudinary/cloudinary_ios
Example/Tests/TransformationTests/CLDTransformationTests/CLDTransformationExpressionsTests.swift
1
18224
// // CLDTransformationExpressionsTests.swift // // // 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, modif...
mit
ZwxWhite/V2EX
V2EX/V2EX/Class/Expand/Tools/DateTool.swift
1
1001
// // DateTool.swift // V2EX // // Created by wenxuan.zhang on 15/11/17. // Copyright © 2015年 张文轩. All rights reserved. // import SwiftDate public func relationshipOfDate(firstDate: NSDate, anotherDate: NSDate) -> String { let second = firstDate.timeIntervalSinceDate(anotherDate) let minite = second ...
mit
cnoon/swift-compiler-crashes
crashes-duplicates/19970-no-stacktrace.swift
11
246
// Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing for { struct S { let end = { func a( ) { return m( [ { deinit { class case ,
mit
muhlenXi/SwiftEx
projects/AudioDemo/AudioDemo/AudioPlayerViewController.swift
1
1503
// // AudioPlayerViewController.swift // AudioDemo // // Created by 席银军 on 2017/9/4. // Copyright © 2017年 muhlenXi. All rights reserved. // import UIKit import AVFoundation class AudioPlayerViewController: UIViewController { var player: AVAudioPlayer? = nil var timer: Timer? = nil let musicName ...
mit
413738916/ZhiBoTest
ZhiBoSwift/Pods/Kingfisher/Sources/AnimatedImageView.swift
33
13294
// // AnimatableImageView.swift // Kingfisher // // Created by bl4ckra1sond3tre on 4/22/16. // // The AnimatableImageView, AnimatedFrame and Animator is a modified version of // some classes from kaishin's Gifu project (https://github.com/kaishin/Gifu) // // The MIT License (MIT) // // Copyright (c) 2017 Reda L...
mit
aslanyanhaik/youtube-iOS
YouTube/Model/User.swift
1
2746
// MIT License // Copyright (c) 2017 Haik Aslanyan // 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, mod...
mit
ccrama/Slide-iOS
Slide for Reddit/PostContentPresentationAnimator.swift
1
7952
// // PostContentPresentationAnimator.swift // Slide for Reddit // // Created by Jonathan Cole on 8/3/18. // Copyright © 2018 Haptic Apps. All rights reserved. // import AVFoundation import UIKit final class PostContentPresentationAnimator: NSObject { // MARK: - Properties let isPresentation: Bool ...
apache-2.0
WJachowicz/TableViewDemo
TableViewDemo/AnimalDetailsViewController.swift
1
1525
// // AnimalDetailsViewController.swift // TableViewDemo // // Created by Wojciech Jachowicz on 03.06.2014. // Copyright (c) 2014 Wojciech Jachowicz. All rights reserved. // import UIKit class AnimalDetailsViewController: UIViewController { var animalName : String var boshLabel : UILabel ini...
mit
wolfhous/haochang_swift
haochang_swift/haochang_swift/公共文件-public/HCBasicCollectionCell.swift
1
492
// // HCBasicCollectionCell.swift // haochang_swift // // Created by 壹号商圈 on 16/12/29. // Copyright © 2016年 com.houshuai. All rights reserved. // import UIKit class HCBasicCollectionCell: UICollectionViewCell { override func awakeFromNib() { super.awakeFromNib() //设置背景颜色 self.backgrou...
mit
bwhiteley/EnumTable
EnumTable/ViewModel.swift
1
2053
import UIKit enum Row { case Twitter, Facebook, Instagram, Contact, Settings case FirstName(String) case LastName(String) var displayName:String { switch self { case .Twitter: return NSLocalizedString("Twitter", comment:"") case .Facebook: re...
mit
146BC/StyleKit
StyleKitDemo/StyleKitDemo/CustomViews/SKLabel.swift
1
356
import Foundation import UIKit class SKLabel: UILabel { @objc dynamic var padding: [CGFloat] = [0,0,0,0] override func drawText(in rect: CGRect) { let insets = UIEdgeInsets.init(top: padding[0], left: padding[1], bottom: padding[2], right: padding[3]) super.drawText(in: UIEdgeInsetsIn...
mit
samantharachelb/todolist
Pods/OctoKit.swift/OctoKit/PullRequest.swift
1
7524
import Foundation import RequestKit @objc open class PullRequest: NSObject { open var id: Int open var url: URL? open var htmlURL: URL? open var diffURL: URL? open var patchURL: URL? open var issueURL: URL? open var commitsURL: URL? open var reviewCommentsURL: URL? open var review...
mit
zisko/swift
test/sil-opt/sil-opt.swift
1
2025
// RUN: %target-swift-frontend -primary-file %s -module-name Swift -g -module-link-name swiftCore -O -parse-as-library -parse-stdlib -emit-module -emit-module-path - -o /dev/null | %target-sil-opt -enable-sil-verify-all -module-name="Swift" | %FileCheck %s // RUN: %target-swift-frontend -primary-file %s -module-name Sw...
apache-2.0
zisko/swift
stdlib/public/SDK/Foundation/JSONEncoder.swift
1
109956
//===----------------------------------------------------------------------===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
apache-2.0
zhangjk4859/MyWeiBoProject
sinaWeibo/sinaWeibo/AppDelegate.swift
1
2893
// // AppDelegate.swift // sinaWeibo // // Created by 张俊凯 on 16/6/5. // Copyright © 2016年 张俊凯. All rights reserved. // import UIKit // 切换控制器通知 let JKSwitchRootVCNotification = "SwitchRootVCNotification" @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? fu...
mit
niunaruto/DeDaoAppSwift
testSwift/Pods/RxSwift/RxSwift/Subjects/PublishSubject.swift
14
4506
// // PublishSubject.swift // RxSwift // // Created by Krunoslav Zaher on 2/11/15. // Copyright © 2015 Krunoslav Zaher. All rights reserved. // /// Represents an object that is both an observable sequence as well as an observer. /// /// Each notification is broadcasted to all subscribed observers. public final cla...
mit
edx/edx-app-ios
Source/CelebratoryModalViewController.swift
1
21351
// // CelebratoryModalViewController.swift // edX // // Created by Salman on 22/01/2021. // Copyright © 2021 edX. All rights reserved. // import UIKit private let UTM_ParameterString = "utm_campaign=edxmilestone&utm_medium=social&utm_source=%@" enum ActivityType:String { case linkedin = "com.linkedin.LinkedI...
apache-2.0
mrdepth/EVEUniverse
Legacy/Neocom/Neocom/NCEventTableViewCell.swift
2
1343
// // NCEventTableViewCell.swift // Neocom // // Created by Artem Shimanski on 05.05.17. // Copyright © 2017 Artem Shimanski. All rights reserved. // import UIKit import EVEAPI import CoreData class NCEventTableViewCell: NCTableViewCell { @IBOutlet weak var dateLabel: UILabel! @IBOutlet weak var titleLabel: UIL...
lgpl-2.1
scottrhoyt/Noonian
Sources/NoonianKit/Utilities/Logger/Logger.swift
1
1396
// // Printer.swift // Noonian // // Created by Scott Hoyt on 11/7/16. // Copyright © 2016 Scott Hoyt. All rights reserved. // import Foundation import Rainbow public var log: Logger.Type = FancyLogger.self public protocol Logger { static func start(_: String) static func process(_: String) static fu...
mit
edx/edx-app-ios
Source/OEXInterface+AppReview.swift
1
1092
// // OEXInterface+AppReview.swift // edX // // Created by Danial Zahid on 2/16/17. // Copyright © 2017 edX. All rights reserved. // import UIKit private let OEXSavedAppRating = "OEXSavedAppRating" private let OEXSavedAppVersionWhenLastRated = "OEXSavedAppVersionWhenLastRated" extension OEXInterface { /...
apache-2.0
takezou621/todayextensionsample
todayextensionsample/ViewController.swift
1
526
// // ViewController.swift // todayextensionsample // // Created by KawaiTakeshi on 2014/09/18. // Copyright (c) 2014年 KawaiTakeshi. All rights reserved. // import UIKit class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after...
apache-2.0
RailwayStations/Bahnhofsfotos
Modules/Domain/Sources/Interfaces/StationsRepositoryType.swift
1
301
// // StationsRepositoryType.swift // // // Created by Miguel Dönicke on 25.10.20. // import Combine @available(iOS 13.0, *) public protocol StationsRepositoryType { func fetchStations() -> AnyPublisher<[Station], Error> func readStations() throws func getStations() -> [Station] }
apache-2.0