-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
Showing
6 changed files
with
97 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// | ||
// DefaultsKey + keys.swift | ||
// DefaultsKit | ||
// | ||
// Created by Nuno Dias on 10/06/2018. | ||
// Copyright © 2018 Nuno Dias. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
@testable import DefaultsKit | ||
|
||
extension DefaultsKey { | ||
static let integerKey = Key<Int>("integerKey") | ||
static let floatKey = Key<Float>("floatKey") | ||
static let doubleKey = Key<Double>("doubleKey") | ||
static let stringKey = Key<String>("stringKey") | ||
static let boolKey = Key<Bool>("boolKey") | ||
static let dateKey = Key<Date>("dateKey") | ||
static let arrayOfIntegersKey = Key<[Int]>("arrayOfIntegersKey") | ||
static let personMockKey = Key<PersonMock>("personMockKey") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// PersonMock.swift | ||
// DefaultsKit | ||
// | ||
// Created by Nuno Dias on 10/06/2018. | ||
// Copyright © 2018 Nuno Dias. All rights reserved. | ||
// | ||
|
||
import Foundation | ||
|
||
struct PersonMock: Codable { | ||
let name: String | ||
let age: Int | ||
let children: [PersonMock] | ||
} |