Class: config
小于 1 分钟
index / network / http_ / config
Class: config
配置信息
Table of contents
Constructors
Properties
Constructors
constructor
• new config(init_?
)
Parameters
Name | Type |
---|---|
init_? | Partial <config > |
Defined in
assets/@framework/network/mk_http.ts:133
Properties
timeout_n
• timeout_n: number
= 5000
超时时间(ms)
Defined in
assets/@framework/network/mk_http.ts:138
return_type
• Optional
return_type: XMLHttpRequestResponseType
返回数据类型
Defined in
assets/@framework/network/mk_http.ts:140
codec
• Optional
codec: codec_base
编解码器
Defined in
assets/@framework/network/mk_http.ts:142
body
• Optional
body: string
| Document
| Blob
| BufferSource
| FormData
| URLSearchParams
内容
Defined in
assets/@framework/network/mk_http.ts:144
header
• Optional
header: Record
<string
, string
>
标头
Defined in
assets/@framework/network/mk_http.ts:146
open_callback_f
• Optional
open_callback_f: (http
: XMLHttpRequest
) => void
Type declaration
▸ (http
): void
open 后回调
Parameters
Name | Type |
---|---|
http | XMLHttpRequest |
Returns
void
Remarks
可在函数内注册回调,设置请求数据