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
noxytrux/ButtonsGoodPracticeTutorial
FlatButtons/UIImage+Extension.swift
1
832
// // UIImage+Extension.swift // FlatButtons // // Created by Marcin Pędzimąż on 24.09.2014. // Copyright (c) 2014 Marcin Pedzimaz. All rights reserved. // import UIKit extension UIImage { class func imageWithColor(color:UIColor?) -> UIImage! { let rect = CGRectMake(0.0, 0.0, 1.0, 1.0); ...
mit
jholsapple/TIY-Assignments
30 -- HighVoltage -- John Holsapple/30 -- HighVoltage -- John Holsapple/ConversionsTableViewController.swift
2
6625
// // ConversionsTableViewController.swift // 30 -- HighVoltage -- John Holsapple // // Created by John Holsapple on 7/24/15. // Copyright (c) 2015 John Holsapple -- The Iron Yard. All rights reserved. // import UIKit protocol PopoverVCDelegate { func valueTypeWasChosen(chosenValueType: String) } protocol Ele...
cc0-1.0
jverkoey/FigmaKit
Sources/FigmaKit/Node/StarNode.swift
1
68
extension Node { public final class StarNode: VectorNode { } }
apache-2.0
halo/LinkLiar
LinkTools/Log.swift
1
2979
/* * Copyright (C) 2012-2021 halo https://io.github.com/halo/LinkLiar * * 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, ...
mit
kstaring/swift
validation-test/compiler_crashers_fixed/27591-swift-modulefile-gettype.swift
11
454
// This source file is part of the Swift.org open source project // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See http://swift.org/LICENSE.txt for license information // See http://swift.org/CONTRIBUTORS.txt for the list...
apache-2.0
apple/swift-async-algorithms
Sources/AsyncAlgorithms/Merge/MergeStateMachine.swift
1
24933
//===----------------------------------------------------------------------===// // // This source file is part of the Swift Async Algorithms open source project // // Copyright (c) 2022 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift...
apache-2.0
AssafYehudai/MarkDownKit
MarkDownKit/Classes/OSColorEx.swift
1
266
// // OSColorEx.swift // Pods // // Created by assaf yehudai on 9/26/17. // // import Foundation extension OSColor { class var codeForeground: OSColor { return OSColor(red: 206 / 255.0 , green: 26 / 255.0 , blue: 83 / 255.0 , alpha: 1) } }
mit
easyui/Alamofire
Source/Request.swift
1
78663
// // Request.swift // // Copyright (c) 2014-2020 Alamofire Software Foundation (http://alamofire.org/) // // 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, includi...
mit
portah/dangerous-room
dangerous-room/Meteor/CoreDataExtensions.swift
1
1491
// Copyright (c) 2015 Peter Siegesmund <peter.siegesmund@icloud.com> // // 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 u...
apache-2.0
huangboju/Moots
Examples/UIScrollViewDemo/UIScrollViewDemo/Controllers/InfiniteScrollViewController.swift
1
4696
// // InfiniteScrollViewController.swift // UIScrollViewDemo // // Created by 伯驹 黄 on 2016/11/29. // Copyright © 2016年 伯驹 黄. All rights reserved. // import UIKit class InfiniteScrollViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() view.backgroundColor = UIC...
mit
luksfarris/SwiftRandomForest
SwiftRandomForestTests/RandomForestPerformanceTest.swift
1
1201
// // RandomForestPerformanceTest.swift // SwiftRandomForest // // Created by Lucas Farris on 02/06/2017. // Copyright © 2017 Lucas Farris. All rights reserved. // import XCTest class RandomForestPerformanceTest: XCTestCase { func testPerformance() { measure { let reader = CS...
mit
mightydeveloper/swift
validation-test/compiler_crashers_fixed/1796-swift-modulefile-getdecl.swift
13
332
// RUN: not %target-swift-frontend %s -parse // Distributed under the terms of the MIT license // Test case submitted to project by https://github.com/practicalswift (practicalswift) // Test case found by fuzzing func b(b: Hashable> A { A<T : [1](") class a { deinit { func f: A { } init(T: Any, let a { } protocol e :...
apache-2.0
steelwheels/KiwiScript
KiwiShell/Test/Shell/main.swift
1
1193
/** * @file main.swift * @brief Main function of shell test * @par Copyright * Copyright (C) 2018 Steel Wheels Project */ import KiwiShell import KiwiEngine import KiwiLibrary import CoconutData import CoconutShell import JavaScriptCore import Foundation public func main() { let inhdl = FileHandle.standardI...
lgpl-2.1
WhatsTaste/WTImagePickerController
Vendor/Views/WTEditingControlsView.swift
1
5165
// // WTEditingControlsView.swift // WTImagePickerController // // Created by Jayce on 2017/2/10. // Copyright © 2017年 WhatsTaste. All rights reserved. // import UIKit protocol WTEditingControlsViewDelegate: class { func editingControlsViewDidCancel(_ view: WTEditingControlsView) func editingControlsViewD...
mit
Jnosh/swift
test/SILGen/super_init_refcounting.swift
3
4169
// RUN: %target-swift-frontend -emit-silgen %s | %FileCheck %s class Foo { init() {} init(_ x: Foo) {} init(_ x: Int) {} } class Bar: Foo { // CHECK-LABEL: sil hidden @_T022super_init_refcounting3BarC{{[_0-9a-zA-Z]*}}fc // CHECK: bb0([[INPUT_SELF:%.*]] : $Bar): // CHECK: [[SELF_BOX:%.*]] = alloc_b...
apache-2.0
Viddi/ios-process-button
ProcessButton/Util/Util.swift
1
652
// // Util.swift // ProcessButton // // Created by Vidar Ottosson on 2/7/15. // Copyright (c) 2015 Vidar Ottosson. All rights reserved. // import UIKit class Util { /** Randomizes the time it takes for the mocked request to process (2 - 6) seconds :returns: seconds */ class func randomProcessTime...
mit
evgenyneu/ShareImageDemo
ShareImageDemo/ViewController.swift
1
282
import UIKit class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() } // Change the status bar text color to white override func preferredStatusBarStyle() -> UIStatusBarStyle { return UIStatusBarStyle.LightContent } }
mit
atl009/WordPress-iOS
WordPress/WordPressScreenshotGeneration/WordPressScreenshotGeneration.swift
1
3921
import UIKit import XCTest class WordPressScreenshotGeneration: XCTestCase { override func setUp() { super.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 oc...
gpl-2.0
qasim/CDFLabs
CDFLabs/Computers/Lab.swift
1
703
// // Lab.swift // CDFLabs // // Created by Qasim Iqbal on 12/30/15. // Copyright © 2015 Qasim Iqbal. All rights reserved. // import Foundation public class Lab { var name: String var avail: Int var busy: Int var total: Int var percent: Int public init() { self.nam...
mit
noppoMan/aws-sdk-swift
Sources/Soto/Services/ComprehendMedical/ComprehendMedical_API.swift
1
14736
//===----------------------------------------------------------------------===// // // This source file is part of the Soto for AWS open source project // // Copyright (c) 2017-2020 the Soto project authors // Licensed under Apache License v2.0 // // See LICENSE.txt for license information // See CONTRIBUTORS.txt for t...
apache-2.0
barteljan/VISPER
Example/VISPER-Wireframe-Tests/Mocks/MockComposedRoutingObserver.swift
1
2476
// // MockComposedRoutingObserver.swift // VISPER-Wireframe_Tests // // Created by bartel on 22.11.17. // Copyright © 2017 CocoaPods. All rights reserved. // import Foundation import VISPER_Core import VISPER_Wireframe class MockComposedRoutingObserver: NSObject, ComposedRoutingObserver { var invokedAdd = f...
mit
PiXeL16/SendToMe
SendToMeFramework/ShareContentExtractor.swift
1
5912
// // ShareContentExtractor.swift // SendToMe // // Created by Chris Jimenez on 1/30/16. // Copyright © 2016 Chris Jimenez. All rights reserved. // import Foundation import MobileCoreServices //Class in charge of extracting content of URL and pages using the extensionContext inputItems public class ShareContentEx...
mit
gewill/Feeyue
Feeyue/Main/Weibo/WeiboModel.swift
1
4868
// // Status.swift // Feeyue // // Created by Will on 1/16/16. // Copyright © 2016 gewill.org. All rights reserved. // import Foundation import RealmSwift import IGListKit import SwiftyJSON import Moya_SwiftyJSONMapper class User: BaseModel, ALSwiftyJSONAble { enum Property: String { case userId, scre...
mit
PureSwift/Bluetooth
Sources/BluetoothHCI/HCILEReadLocalP256PublicKeyComplete.swift
1
1699
// // HCILEReadLocalP256PublicKeyComplete.swift // Bluetooth // // Created by Alsey Coleman Miller on 6/15/18. // Copyright © 2018 PureSwift. All rights reserved. // import Foundation /// LE Read Local P-256 Public Key Complete Event /// /// This event is generated when local P-256 key generation is complete. @fr...
mit
ijoshsmith/swift-tic-tac-toe
Framework/TicTacToeTests/PlayerTests.swift
1
998
// // PlayerTests.swift // TicTacToe // // Created by Joshua Smith on 11/28/15. // Copyright © 2015 iJoshSmith. All rights reserved. // import XCTest class PlayerTests: XCTestCase { func test_choosePositionWithCompletionHandler_strategyChoosesCenterPosition_choosesCenterPosition() { let board...
mit
tristanchu/FlavorFinder
FlavorFinder/FlavorFinder/AddHotpotToList.swift
1
8549
// // addHotpotToList.swift // FlavorFinder // // Created by Courtney Ligh on 2/15/16. // Copyright © 2016 TeamFive. All rights reserved. // import UIKit import Parse class AddHotpotToListController: UITableViewController { // MARK: Properties: let listCellIdentifier = "listAddCellIdentifier" let cre...
mit
obrichak/discounts
discounts/Classes/BarCodeGenerator/UIColorExtension.swift
1
1604
// // UIColorExtension.swift // RSBarcodesSample // // Created by R0CKSTAR on 6/13/14. // Copyright (c) 2014 P.D.Q. All rights reserved. // import UIKit extension UIColor { convenience init(rgba: String) { var red: CGFloat = 0.0 var green: CGFloat = 0.0 var blue: CGFloat = 0.0 ...
gpl-3.0
qpre/swifter
Sources/Swifter/DemoServer.swift
1
2235
// // DemoServer.swift // Swifter // Copyright (c) 2015 Damian Kołakowski. All rights reserved. // import Foundation public func demoServer(publicDir: String?) -> HttpServer { let server = HttpServer() if let publicDir = publicDir { server["/resources/:file"] = HttpHandlers.directory(publicDir...
bsd-3-clause
itsaboutcode/WordPress-iOS
WordPress/WordPressDraftActionExtension/Tracks+DraftAction.swift
1
2420
import Foundation /// This extension implements helper tracking methods, meant for Draft Action Extension usage. /// extension Tracks { // MARK: - Public Methods public func trackExtensionLaunched(_ wpcomAvailable: Bool) { let properties = ["is_configured_dotcom": wpcomAvailable] trackExtensio...
gpl-2.0
merlos/iOS-Open-GPX-Tracker
Pods/CoreGPX/Classes/GPXMetadata.swift
1
4084
// // GPXMetadata.swift // GPXKit // // Created by Vincent on 22/11/18. // import Foundation /** A value type that represents the metadata header of a GPX file. Information about the GPX file should be stored here. - Supported Info types: - Name - Description - Author Info - Copyright - Da...
gpl-3.0
pixel-ink/PIImageCache
PIImageCache/PIImageCacheTests/PIImageCacheDiskCacheTests.swift
2
2230
// https://github.com/pixel-ink/PIImageCache import UIKit import XCTest class PIImageDiskCacheTests: XCTestCase { let max = PIImageCache.Config().maxMemorySum func testDiskCache() { let cache = PIImageCache() var image: UIImage?, result: PIImageCache.Result var urls :[NSURL] = [] for i in 0 ....
mit
abertelrud/swift-package-manager
IntegrationTests/Fixtures/XCBuild/SystemTargets/Foo/Sources/foo/main.swift
2
62
import SystemLib print(String(cString: GetSystemLibName()!))
apache-2.0
RuiAAPeres/TeamGen
TeamGenFoundation/Sources/Components/UI/Flow.swift
1
1759
import UIKit public protocol Flow { func present(_ viewController: UIViewController, animated: Bool) func dismiss(_ animated: Bool) } private struct ModalFlow: Flow { private let origin: UIViewController init(_ viewController: UIViewController) { self.origin = viewController } func p...
mit
nalexn/ViewInspector
Tests/ViewInspectorTests/SwiftUI/MenuButtonTests.swift
1
2523
import XCTest import SwiftUI @testable import ViewInspector #if os(macOS) @available(macOS 10.15, *) @available(iOS, unavailable) @available(tvOS, unavailable) final class MenuButtonTests: XCTestCase { func testEnclosedView() throws { let sut = MenuButton(label: Text("")) { EmptyView() } XCTA...
mit
inket/MacSymbolicator
MacSymbolicatorTests/TestProject/AnotherTarget/CrashingClass.swift
1
237
// // CrashingClass.swift // AnotherTarget // import Foundation @objc public class CrashingClass: NSObject { @objc public static func crash() { NSException(name: .init(rawValue: "Crash"), reason: nil).raise() } }
gpl-2.0
ayvazj/BrundleflyiOS
Pod/Classes/Model/BtfyColor.swift
1
2067
/* * Copyright (c) 2015 James Ayvaz * * 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, dist...
mit
clutter/Pelican
Tests/PelicanTests/PelicanTests.swift
1
10404
// // PelicanTests.swift // Pelican // // Created by Robert Manson on 4/5/17. // Copyright © 2017 CocoaPods. All rights reserved. // import XCTest @testable import Pelican private class TaskCollector { enum Task { case taskA(value: HouseAtreides) case taskB(value: HouseHarkonnen) var ...
mit
krzysztofzablocki/Sourcery
SourceryFramework/Sources/Parsing/Utils/InlineParser.swift
1
4284
// // Created by Krzysztof Zablocki on 16/01/2017. // Copyright (c) 2017 Pixle. All rights reserved. // import Foundation public enum TemplateAnnotationsParser { public typealias AnnotatedRanges = [String: [(range: NSRange, indentation: String)]] private static func regex(annotation: String) throws -> NSReg...
mit
onevcat/Rainbow
Sources/ControlCode.swift
1
1530
// // ControlCode.swift // Rainbow // // Created by Wei Wang on 15/12/22. // // Copyright (c) 2018 Wei Wang <onevcat@gmail.com> // // 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 wi...
mit
erosnick/SoftRenderer
SoftRenderer/DotMatrixFont.swift
1
159
// // DotMatrixFont.swift // SoftRenderer // // Created by Princerin on 4/9/16. // Copyright © 2016 Princerin. All rights reserved. // import Foundation
mit
lorentey/GlueKit
Sources/UIDevice Glue.swift
1
5911
// // UIDevice Glue.swift // GlueKit // // Created by Károly Lőrentey on 2016-03-13. // Copyright © 2015–2017 Károly Lőrentey. // #if os(iOS) import UIKit extension UIDevice { open override var glue: GlueForUIDevice { return _glue() } } open class GlueForUIDevice: GlueForNSObject { private va...
mit
lorentey/GlueKit
Package.swift
1
718
// swift-tools-version:4.0 import PackageDescription let package = Package( name: "GlueKit", products: [ .library(name: "GlueKit", type: .dynamic, targets: ["GlueKit"]) ], dependencies: [ .package(url: "https://github.com/attaswift/SipHash", from: "1.2.0"), .package(url: "https:...
mit
vbudhram/firefox-ios
ThirdParty/SQLite.swift/Tests/SQLiteTests/ConnectionTests.swift
2
13305
import XCTest @testable import SQLite #if SQLITE_SWIFT_STANDALONE import sqlite3 #elseif SQLITE_SWIFT_SQLCIPHER import SQLCipher #else import SQLite3 #endif class ConnectionTests : SQLiteTestCase { override func setUp() { super.setUp() CreateUsersTable() } func test_init_withInMemory_re...
mpl-2.0
keitaito/HackuponApp
HackuponApp/Models/Person.swift
1
208
// // Person.swift // HackuponApp // // Created by Keita Ito on 3/14/16. // Copyright © 2016 Keita Ito. All rights reserved. // import Foundation struct Person { let name: String let id: Int }
mit
timgrohmann/vertretungsplan_ios
Vertretungsplan/ChangedLesson.swift
1
1686
// // ChangedLesson.swift // Vertretungsplan // // Created by Tim Grohmann on 15.08.16. // Copyright © 2016 Tim Grohmann. All rights reserved. // import Foundation import UIKit import CoreData class ChangedLesson: Equatable{ var subject: String = "" var origSubject: String? var teacher: String = ...
apache-2.0
jbennett/Bugology
Bugology/MockPresentationContext.swift
1
1207
// // MockPresentationContext.swift // Bugology // // Created by Jonathan Bennett on 2016-01-20. // Copyright © 2016 Jonathan Bennett. All rights reserved. // import UIKit // swiftlint:disable variable_name_min_length public class MockPresentationContext: PresentationContext { func adsfa() { // let a = UIVi...
mit
IngmarStein/swift
test/attr/attr_noescape.swift
4
18654
// RUN: %target-parse-verify-swift @noescape var fn : () -> Int = { 4 } // expected-error {{@noescape may only be used on 'parameter' declarations}} {{1-11=}} func conflictingAttrs(_ fn: @noescape @escaping () -> Int) {} // expected-error {{@escaping conflicts with @noescape}} // expected-warning@-1{{@noescape is t...
apache-2.0
collegboi/MBaaSKit
Example/MBaaSKit/TestObject.swift
1
459
// // TestObject.swift // MBaaSKit // // Created by Timothy Barnard on 29/01/2017. // Copyright © 2017 CocoaPods. All rights reserved. // import Foundation import MBaaSKit //struct TestObject: JSONSerializable { // // var name: String! // // init() { // // } // // init(name: String) { // ...
mit
h-n-y/BigNerdRanch-SwiftProgramming
chapter-25/GoldChallenge.playground/Contents.swift
1
915
/* GOLD CHALLENGE The method indexOf(_:) is made available in an extension on `CollectionType` that requires the `CollectionType`s `Element`s to conform to the `Equatable` protocol. `Array<Person>` ( the type of *people*, below ) conforms to `CollectionType`, but `Person` must also conform to `Eq...
mit
swift-lang/swift-k
tests/language-behaviour/mappers/075-array-mapper.swift
2
364
type messagefile; (messagefile t) write() { app { echo @filename(t) stdout=@filename(t); } } string fns[]=["075-array-mapper.first.out", "075-array-mapper.second.out", "075-array-mapper.third.out"]; messagefile outfile[] <array_mapper; files=fns>; outfile[0] = write(); o...
apache-2.0
dnpp73/SimpleCamera
Package.swift
1
406
// swift-tools-version:5.3 import PackageDescription let package = Package( name: "SimpleCamera", platforms: [ .iOS(.v12), .macOS(.v10_11), ], products: [ .library(name: "SimpleCamera", targets: ["SimpleCamera"]), ], targets: [ .target( name: "Simple...
mit
LoganHollins/SuperStudent
SuperStudent/AddEventViewController.swift
1
2130
// // AddEventViewController.swift // SuperStudent // // Created by Logan Hollins on 2015-11-28. // Copyright © 2015 Logan Hollins. All rights reserved. // import UIKit import Alamofire class AddEventViewController: UIViewController { var eventObject = Event() @IBOutlet weak var descriptionField...
gpl-2.0
Chantalisima/Spirometry-app
EspiroGame/ResultViewController.swift
1
6616
// // ResultViewController.swift // BLEgame4 // // Created by Chantal de Leste on 25/3/17. // Copyright © 2017 Universidad de Sevilla. All rights reserved. // import Foundation import UIKit import CoreData import MessageUI struct cellData { var name: String! var value: Float! } class ResultViewContro...
apache-2.0
steveholt55/metro
iOS/Pods/OHHTTPStubs/OHHTTPStubs/Sources/Swift/OHHTTPStubsSwift.swift
3
8086
/*********************************************************************************** * * Copyright (c) 2012 Olivier Halligon * * 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 restrict...
mit
cuappdev/eatery
Eatery/Onboarding/Controllers/OnboardingViewController.swift
1
5372
// // OnboardingViewController.swift // Eatery // // Created by Reade Plunkett on 11/11/19. // Copyright © 2019 CUAppDev. All rights reserved. // import UIKit protocol OnboardingViewControllerDelegate { func onboardingViewControllerDidTapNext(_ viewController: OnboardingViewController) } class OnboardingView...
mit
JohnSundell/SwiftKit
Source/iOS/Animate.swift
1
356
import UIKit /// Perform a closure of animations with a certain duration, optionally attaching a completion handler public func Animate(animations: () -> Void, duration: NSTimeInterval = 0.3, onCompletion: (() -> Void)? = nil) { UIView.animateWithDuration(duration, animations: animations) { didComplete -> Void...
mit
TJ-93/TestKitchen
TestKitchen/TestKitchen/classes/Ingredient/service(处理公共点击事件)/WebViewService.swift
1
193
// // WebViewService.swift // TestKitchen // // Created by qianfeng on 2016/11/3. // Copyright © 2016年 陶杰. All rights reserved. // import UIKit class WebViewService: NSObject { }
mit
saeta/penguin
Tests/PenguinStructuresTests/XCTestManifests.swift
1
1734
// Copyright 2020 Penguin Authors // // 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 t...
apache-2.0
zimcherDev/ios
Zimcher/UIKit Objects/MainScenes/TabBarViewController.swift
1
793
// // TabBarViewController.swift // SwiftPort // // Created by Weiyu Huang on 11/13/15. // Copyright © 2015 Kappa. All rights reserved. // import UIKit class TabBarViewController: UITabBarController { override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading ...
apache-2.0
zpz1237/NirZhihuDaily2.0
zhihuDaily 2.0/ThemeViewController.swift
2
12746
// // ThemeViewController.swift // zhihuDaily 2.0 // // Created by Nirvana on 10/15/15. // Copyright © 2015 NSNirvana. All rights reserved. // import UIKit import Alamofire import SwiftyJSON import SDWebImage class ThemeViewController: UIViewController { @IBOutlet weak var tableView: UITableView! @IB...
mit
ps2/rileylink_ios
MinimedKit/Messages/PowerOnCarelinkMessageBody.swift
1
782
// // PowerOnCarelinkMessageBody.swift // Naterade // // Created by Nathan Racklyeft on 12/26/15. // Copyright © 2015 Nathan Racklyeft. All rights reserved. // import Foundation public struct PowerOnCarelinkMessageBody: MessageBody { public static var length: Int = 65 public var txData: Data let dur...
mit
feinstruktur/Nimble
Tests/Nimble/Matchers/ContainTest.swift
14
3466
import Foundation import XCTest import Nimble class ContainTest: XCTestCase, XCTestCaseProvider { var allTests: [(String, () throws -> Void)] { return [ ("testContain", testContain), ("testContainSubstring", testContainSubstring), ("testContainObjCSubstring", testContain...
apache-2.0
SakuragiTen/DYTV
DYTV/DYTV/AppDelegate.swift
1
2170
// // AppDelegate.swift // DYTV // // Created by 龚胜 on 16/10/10. // Copyright © 2016年 gongsheng. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOpt...
mit
benlangmuir/swift
test/Interop/SwiftToCxx/structs/swift-struct-in-cxx.swift
2
4450
// RUN: %empty-directory(%t) // RUN: %target-swift-frontend %s -typecheck -module-name Structs -clang-header-expose-public-decls -emit-clang-header-path %t/structs.h // RUN: %FileCheck %s < %t/structs.h // RUN: %check-interop-cxx-header-in-clang(%t/structs.h -Wno-unused-private-field -Wno-unused-function) // CHECK: n...
apache-2.0
codepgq/LearningSwift
ListenKeyboard/ListenKeyboard/ViewController.swift
1
4231
// // ViewController.swift // ListenKeyboard // // Created by ios on 16/9/24. // Copyright © 2016年 ios. All rights reserved. // import UIKit class ViewController: UIViewController,UITextViewDelegate { @IBOutlet weak var toolBarConstraints: NSLayoutConstraint! @IBOutlet weak var toobar: UIToolbar! ...
apache-2.0
PodBuilder/XcodeKit
SwiftXcodeKit/Resources/CopyResourcesBuildPhase.swift
1
1940
/* * The sources in the "XcodeKit" directory are based on the Ruby project Xcoder. * * Copyright (c) 2012 cisimple * * 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 w...
mit
tannernelson/hamburger-menu
Pod/Classes/DefaultMenuView.swift
1
2171
// // DefaultMenu.swift // Pods // // Created by Tanner Nelson on 1/16/16. // // import Foundation @available(iOS 9 , *) class DefaultMenuView: MenuView { override init(rootView: UIView, controller: MenuController) { super.init(rootView: rootView, controller: controller) self.back...
mit
rpitting/LGLinearFlow
Example/LGMagnifyingLinearFlowLayout/CollectionViewCell.swift
1
278
// // CollectionViewCell.swift // LGLinearFlowView // // Created by Luka Gabric on 16/08/15. // Copyright © 2015 Luka Gabric. All rights reserved. // import UIKit public class CollectionViewCell: UICollectionViewCell { @IBOutlet public weak var pageLabel: UILabel! }
mit
paulomendes/nextel-challange
nextel-challange/Source/DataProvider/MoviesConnector.swift
1
5084
import Alamofire import Gloss import UIKit protocol MoviesConnectorProtocol { func getNowPlayingMovies(success: @escaping (Data) -> Void, failure: @escaping (MoviesConnectorError) -> Void ) func getUpcomingMovies(success: @escaping (Data) -> Void, failure: @escaping (MoviesConnectorError) -> Void ) func s...
mit
piwik/piwik-sdk-ios
MatomoTracker/Application.swift
1
2297
#if SWIFT_PACKAGE import Foundation #endif public struct Application { /// Creates an returns a new application object representing the current application public static func makeCurrentApplication() -> Application { let displayName = bundleDisplayNameForCurrentApplication() let name = bundleNa...
mit
pabloroca/NewsApp
NewsApp/Controllers/ViewControllers/DetailViewController.swift
1
1921
// // DetailViewController.swift // NewsApp // // Created by Pablo Roca Rozas on 28/03/2017. // Copyright © 2017 PR2Studio. All rights reserved. // import UIKit class DetailViewController: UIViewController, UIWebViewDelegate { @IBOutlet weak var detailDescriptionLabel: UILabel! //UI @IBOutlet we...
mit
kunass2/BSTableViewReorder
Example/BSTableViewReorder/BSTableViewCell.swift
1
255
// // BSTableViewCell.swift // BSTableViewReorder // // Created by Bartłomiej Semańczyk on 12/08/16. // Copyright © 2016 CocoaPods. All rights reserved. // import UIKit class BSTableViewCell: UITableViewCell { @IBOutlet var label: UILabel! }
mit
i-schuetz/SwiftCharts
SwiftCharts/Axis/ChartAxisModel.swift
3
6047
// // ChartAxisModel.swift // SwiftCharts // // Created by ischuetz on 22/04/15. // Copyright (c) 2015 ivanschuetz. All rights reserved. // import UIKit public enum ChartAxisPadding { case label /// Add padding corresponding to half of leading / trailing label sizes case none case fixed(CGFloat) /// S...
apache-2.0
digitalcatnip/Pace-SSS-iOS
SSSFreshmanApp/SSSFreshmanApp/RootGroup/RootVC.swift
1
3132
// // RootVC.swift // SSS Freshman App // // Created by James McCarthy on 8/15/16. // Copyright © 2016 Digital Catnip. All rights reserved. // import UIKit class RootVC: UIViewController { override func viewDidAppear(animated: Bool) { registerScreen("StartScreen") } override func vie...
mit
loganSims/wsdot-ios-app
wsdot/MountainPassesViewController.swift
1
6419
// // MountainPassesViewController.swift // WSDOT // // Copyright (c) 2016 Washington State Department of Transportation // // 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 versio...
gpl-3.0
e6-1/e6-1.github.io
iOS Class/Tic-Tac-Toe/Tic-Tac-ToeUITests/Tic_Tac_ToeUITests.swift
1
1258
// // Tic_Tac_ToeUITests.swift // Tic-Tac-ToeUITests // // Created by Ethan Petersen on 6/5/16. // Copyright © 2016 Rose-Hulman. All rights reserved. // import XCTest class Tic_Tac_ToeUITests: XCTestCase { override func setUp() { super.setUp() // Put setup code here. This met...
mit
toymachiner62/myezteam-ios
Myezteam/TeamDao.swift
1
1373
// // TeamDao.swift // Myezteam // // Created by Caflisch, Thomas J. (Tom) on 11/24/15. // Copyright (c) 2015 Tom Caflisch. All rights reserved. // import Foundation struct TeamDao { // MARK: Functions /** Gets the team info from the team id */ static func getTeamInfo(id: Int, ca...
mit
iAmNaz/FormValidationKit
FormValidationKit/ValidatorIterator.swift
1
783
// // ArrayIteratorNZ.swift // FormValidator // // Created by JMariano on 11/11/14. // Copyright (c) 2014 JMariano. All rights reserved. // import UIKit public class ValidatorIterator: NSObject, IteratorNZ { var mutableList: Array<Validator>? var position: Int required public init(listItems: Arra...
mit
deepak475121/JustForFun
justForFun/Archive/SecondCell.swift
1
998
// // SecondCell.swift // justForFun // // Created by Hari Crayond Digital Reach Pvt Ltd on 20/05/2017. // Copyright © 2017 Crayond Digital Reach Pvt Ltd. All rights reserved. // import UIKit class SecondCell: UITableViewCell { @IBOutlet weak var RegBt: UIButton! @IBOutlet weak var WhatTextView: UITextVi...
apache-2.0
nguyenantinhbk77/practice-swift
CoreMotion/Retrieving Altitude Data/Retrieving Altitude Data/ViewController.swift
3
184
// // ViewController.swift // Retrieving Altitude Data // // Created by Domenico Solazzo on 20/05/15. // License MIT // import UIKit class ViewController: UIViewController { }
mit
OscarSwanros/swift
test/SILGen/testable-multifile-other.swift
4
2779
// This test is paired with testable-multifile.swift. // RUN: %empty-directory(%t) // RUN: %target-swift-frontend -emit-module %S/Inputs/TestableMultifileHelper.swift -enable-testing -o %t // RUN: %target-swift-frontend -emit-silgen -enable-sil-ownership -I %t %s %S/testable-multifile.swift -module-name main | %FileC...
apache-2.0
OscarSwanros/swift
test/IRGen/dynamic_self_metadata.swift
18
2000
// RUN: %target-swift-frontend -assume-parsing-unqualified-ownership-sil %s -emit-ir -parse-as-library | %FileCheck %s // REQUIRES: CPU=x86_64 // FIXME: Not a SIL test because we can't parse dynamic Self in SIL. // <rdar://problem/16931299> // CHECK: [[TYPE:%.+]] = type <{ [8 x i8] }> @inline(never) func id<T>(_ t:...
apache-2.0
leonereveel/Moya
Source/Moya+Internal.swift
1
12726
import Foundation import Result /// Internal extension to keep the inner-workings outside the main Moya.swift file. internal extension MoyaProvider { // Yup, we're disabling these. The function is complicated, but breaking it apart requires a large effort. // swiftlint:disable cyclomatic_complexity // swif...
mit
babumoshai-ankush/UITableView-Self-Sizing
TableViewSelfSizingDemo/ViewController.swift
1
3425
// // ViewController.swift // TableViewSelfSizingDemo // // Created by Ankush Chakraborty on 05/07/17. // Copyright © 2017 Ankush Chakraborty. All rights reserved. // import UIKit struct Data { var title: String? var description: String? init(title: String, description: String) { self.title = ...
gpl-3.0
SASAbus/SASAbus-ios
SASAbus/Controller/About/Credits/CreditsViewController.swift
1
1276
import UIKit class CreditsViewController: UIViewController, UIToolbarDelegate { @IBOutlet weak var infoView: UITextView! @IBOutlet weak var infoTextView: UITextView! @IBOutlet weak var titleLabel: UILabel! init() { super.init(nibName: "CreditsViewController", bundle: nil) title = L...
gpl-3.0
infobip/mobile-messaging-sdk-ios
Classes/Core/PrivacySettings.swift
1
1865
// // PrivacySettings.swift // MobileMessaging // // Created by Andrey Kadochnikov on 01/11/2018. // import Foundation /// The `MMPrivacySettings` class incapsulates privacy settings that affect the SDK behaviour and business logic. @objcMembers public class MMPrivacySettings: NSObject { /// A boolean variable th...
apache-2.0
thiagotmb/BEPiD-Challenges-2016
2016-02-15-TimerWatch/TimerWatch/desafio_3 WatchKit Extension/InterfaceController.swift
2
4174
// // InterfaceController.swift // desafio_3 WatchKit Extension // // Created by Dennis Merli Rodrigues on 2/15/16. // Copyright © 2016 Dennis Merli Rodrigues. All rights reserved. // import WatchKit import Foundation class InterfaceController: WKInterfaceController { //Outlets @IBOutlet v...
mit
RoverPlatform/rover-ios-beta
Sources/Rover.swift
1
310
// // Rover.swift // Rover // // Created by Andrew Clunis on 2019-03-13. // Copyright © 2019 Rover Labs Inc. All rights reserved. // import Foundation import UIKit /// Set your Rover Account Token (API Key) here. public var accountToken: String? { didSet { Analytics.shared.enable() } }
mit
rudkx/swift
test/Interop/Cxx/stdlib/use-std-string.swift
1
636
// RUN: %target-run-simple-swift(-I %S/Inputs -Xfrontend -enable-cxx-interop) // // REQUIRES: executable_test // // Enable this everywhere once we have a solution for modularizing libstdc++: rdar://87654514 // REQUIRES: OS=macosx import StdlibUnittest import StdString import std.string var StdStringTestSuite = TestSu...
apache-2.0
BalestraPatrick/Tweetometer
TweetometerTests/MenuOptionsTests.swift
2
793
// // MenuOptionsTests.swift // TweetsCounter // // Created by Patrick Balestra on 2/5/16. // Copyright © 2016 Patrick Balestra. All rights reserved. // import XCTest @testable import TweetometerKit class MenuOptionsTests: XCTestCase { func testDataSource() { let options = MenuDataSource().option...
mit
tkrajacic/SampleCodeStalker
SampleCodeStalker/MainWindow.swift
1
1024
// // MainWindow.swift // SampleCodeStalker // // Created by Thomas Krajacic on 23.1.2016. // Copyright © 2016 Thomas Krajacic. All rights reserved. // import Cocoa class MainWindow: NSWindow { override init(contentRect: NSRect, styleMask aStyle: NSWindowStyleMask, backing bufferingType: NSBackingStoreType, ...
mit
DevilWang/BlinkingLabel
Example/BlinkingLabel/ViewController.swift
1
1685
// // ViewController.swift // BlinkingLabel // // Created by DevilWang on 07/19/2017. // Copyright (c) 2017 DevilWang. All rights reserved. // import UIKit import BlinkingLabel class ViewController: UIViewController { var isBlinking = false; let blinkingLabel = BlinkingLabel(frame:CGRect(origin:CGPoint.i...
mit
lkzhao/ElasticTransition
Pods/MotionAnimation/MotionAnimation/NSObject+MotionAnimation.swift
1
4258
// // NSObject+MotionAnimation.swift // DynamicView // // Created by YiLun Zhao on 2016-01-17. // Copyright © 2016 lkzhao. All rights reserved. // import UIKit public extension NSObject{ fileprivate struct m_associatedKeys { static var m_propertyStates = "m_propertyStates_key" } // use NSMutableDictiona...
mit
watson-developer-cloud/ios-sdk
Sources/DiscoveryV1/Models/ListConfigurationsResponse.swift
1
1081
/** * (C) Copyright IBM Corp. 2018, 2020. * * 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 agre...
apache-2.0
dreamsxin/swift
validation-test/compiler_crashers_fixed/00279-swift-nominaltypedecl-getdeclaredtypeincontext.swift
11
454
// This source file is part of the Swift.org open source project // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See http://swift.org/LICENSE.txt for license information // See http://swift.org/CONTRIBUTORS.txt for the list...
apache-2.0
emilstahl/swift
validation-test/compiler_crashers_fixed/26676-swift-parser-parsetoken.swift
13
253
// RUN: not %target-swift-frontend %s -parse // 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 s={{}{{{let a{struct B{class d{a}}
apache-2.0
ben-ng/swift
validation-test/compiler_crashers_fixed/26620-swift-tupletype-get.swift
1
432
// This source file is part of the Swift.org open source project // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/LICENSE.txt for license information // See https://swift.org/CONTRIBUTORS.txt for the li...
apache-2.0
lrtitze/Swift-VectorBoolean
Swift VectorBoolean/CanvasView.swift
1
9584
// // CanvasView.swift // Swift VectorBoolean // // Created by Leslie Titze on 2015-07-12. // Copyright (c) 2015 Starside Softworks. All rights reserved. // import UIKit import VectorBoolean enum DisplayMode { case original case union case intersect case subtract case join } class PathItem { filepriv...
mit
coreyjv/Emby.ApiClient.Swift
Emby.ApiClient/model/connect/ConnectPassword.swift
2
759
// // ConnectPassword.swift // Emby.ApiClient // // Created by Vedran Ozir on 07/10/15. // Copyright © 2015 Vedran Ozir. All rights reserved. // import Foundation //package mediabrowser.model.connect; extension String { func replace(what: String, with: String) -> String { return self.stringByRep...
mit
ben-ng/swift
validation-test/compiler_crashers_fixed/00772-swift-substitutedtype-get.swift
1
438
// This source file is part of the Swift.org open source project // Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/LICENSE.txt for license information // See https://swift.org/CONTRIBUTORS.txt for the li...
apache-2.0