Swift 协议详解
来源:互联网 发布:数据库具备的特性 编辑:程序博客网 时间:2024/06/16 03:27
protocol OutputStreamType `文本输出流`{ mutating func write(_ string: String)}protocol Streamable `可以被输出`{ func writeTo<Target : OutputStreamType>(inout _ target: Target)}protocol CustomDebugStringConvertible `调试用自定义字符串`{ var debugDescription: String { get }}protocol Hashable `哈希值`{ var hashValue: Int { get }}protocol StringInterpolationConvertible `可以被\()`{ init(stringInterpolation strings: Self...) init<T>(stringInterpolationSegment expr: T)}protocol UnicodeScalarLiteralConvertible{ associatedtype UnicodeScalarLiteralType init(unicodeScalarLiteral value: Self.UnicodeScalarLiteralType)}protocol Comparable `可以被比较`{ func <(lhs: Self, rhs: Self) -> Bool func ==(lhs: Self, rhs: Self) -> Bool}enum Process `进程参数`{ static var argc: CInt { get } static let arguments: [String] static var unsafeArgv: UnsafeMutablePointer<UnsafeMutablePointer<Int8>> { get }}protocol CollectionType `可以被索引`{ var count: Self.Index.Distance { get } var first: Self.Generator.Element? { get } var isEmpty: Bool { get } func generate() -> Self.Generator @warn_unused_result func prefixThrough(_ position: Self.Index) -> Self.SubSequence @warn_unused_result func prefixUpTo(_ end: Self.Index) -> Self.SubSequence @warn_unused_result func suffixFrom(_ start: Self.Index) -> Self.SubSequence subscript (_ bounds: Range<Self.Index>) -> Self.SubSequence { get } subscript (_ position: Self.Index) -> Self.Generator.Element { get }}protocol CVarArgType {} `C 可变参数`{}
0 0
- Swift 协议详解
- [Swift]协议
- Swift-协议
- Swift 协议
- Swift 协议
- swift 协议
- swift协议
- Swift协议
- Swift-协议
- swift 协议
- swift 协议
- Swift 协议
- swift详解之十一------------协议、委托(代理)模式
- iOS swift学习之入门详解(协议和扩展)
- swift 协议和扩展
- swift入门- 协议
- Swift-协议和扩展
- Swift 协议(十八)
- js正则融合字符串
- Spark配置属性详解(1)
- 第5周项目二—游戏中的角色类
- 使用 VisualVM 进行性能分析及调优
- B+树实现
- Swift 协议详解
- 浅谈服务器压力解决方案
- spring+hibernate4配置
- Spark配置属性详解(1)
- HDU 5700 区间交 (枚举 + multiset)
- 一个菜的不能再菜的菜鸟第一次写网页
- Spring3.3 整合 Hibernate3、MyBatis3.2 配置多数据源/动态切换数据源 方法
- Spark三种属性配置方式详细说明
- 二分查找