Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/samasaur1/protocolkit
A collection of Swift protocols that I use in all my projects
https://github.com/samasaur1/protocolkit
Last synced: 19 days ago
JSON representation
A collection of Swift protocols that I use in all my projects
- Host: GitHub
- URL: https://github.com/samasaur1/protocolkit
- Owner: Samasaur1
- Created: 2018-10-03T23:01:13.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-10-07T14:31:07.000Z (over 6 years ago)
- Last Synced: 2024-12-06T01:34:03.770Z (about 1 month ago)
- Language: Swift
- Size: 8.79 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ProtocolKit
A collection of Swift protocols that define common basic functionality. The current list includes:
## Copiable
### Declaration:
```swift
public protocol Copiable {
associatedtype ReturnType = Self
func copy() -> ReturnType
}
```
### Requirements:
Implement the `copy()` function. This function should return the type of the implementing object (e.g. the `copy()` method of `SomeClass` returns a `SomeClass` instance).