Tusker/Pachyderm/Request/Method.swift

31 lines
524 B
Swift
Raw Permalink Normal View History

2018-09-11 14:52:21 +00:00
//
// Method.swift
// Pachyderm
//
// Created by Shadowfacts on 9/8/18.
// Copyright © 2018 Shadowfacts. All rights reserved.
//
import Foundation
enum Method {
case get, post, put, patch, delete
}
extension Method {
var name: String {
switch self {
case .get:
return "GET"
case .post:
return "POST"
case .put:
return "PUT"
case .patch:
return "PATCH"
case .delete:
return "DELETE"
}
}
}