Created
January 4, 2018 19:42
-
-
Save azamsharp/1912d630da39df9f196fecb41f9c7b39 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
enum TranslationType : String, Codable { | |
case international | |
case domestic | |
} | |
class Transaction : Codable { | |
var from :String | |
var to :String | |
var amount :Double | |
var fees :Double = 0.0 | |
var transactionType :TranslationType = .domestic | |
init(from :String, to:String, amount :Double, transactionType :TranslationType = .domestic) { | |
self.from = from | |
self.to = to | |
self.amount = amount | |
self.transactionType = transactionType | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment