123456789101112131415161718192021222324252627282930313233343536373839 |
- //
- // ZYLURLRequestGenerator.h
- // NetworkLayerBuild
- //
- // Created by 翟玉磊 on 2017/8/31.
- // Copyright © 2017年 翟玉磊. All rights reserved.
- //
- #import <Foundation/Foundation.h>
- #import "ZYLService.h"
- #import "ZYLUploadFile.h"
- @interface ZYLURLRequestGenerator : NSObject
- + (instancetype)sharedInstance;
- /**
- 发起数据请求
- */
- - (NSMutableURLRequest *)generateRequestWithUrlPath:(NSString *)urlPath
- useHttps:(BOOL)useHttps
- method:(NSString *)method
- params:(NSDictionary *)params
- header:(NSDictionary *)header;
- /**
- 发起上传请求
- */
- - (NSMutableURLRequest *)generateUploadRequestWithUrlPath:(NSString *)urlPath
- useHttps:(BOOL)useHttps
- params:(NSDictionary *)params
- contents:(NSArray<ZYLUploadFile *> *)contents
- header:(NSDictionary *)header;
- /// 获取header
- - (NSMutableURLRequest *)setCommonRequestHeaderForRequest:(NSMutableURLRequest *)request;
- @end
|