Last active
August 15, 2016 18:48
-
-
Save jstart/f8c466dc2ddc81118893d733fa13628f 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
import Alamofire | |
protocol Request { | |
var path : String { get } | |
var method : Method { get } | |
func parameters() -> [String : AnyObject] | |
} | |
struct AuthRequest : Request { | |
let path = "auth" | |
let method = Method.POST | |
var password : String | |
var password_verify : String | |
var name : String | |
var email : String | |
func parameters() -> [String : AnyObject] { | |
return ["password" : password, "password_verify" : password_verify, "name" : name, "email" : email] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment