包括哪些 properties/fields (System.Text.Json.JsonSerializer)?
What properties/fields are included (System.Text.Json.JsonSerializer)?
JsonSerializer 包含以下哪些?
Private/Protected/Internal 字段
Private/Protected/Internal 属性
Public 字段
Public 属性
只读
只写
读写
Private OR
Protected OR
Internal
Fields OR Properties
Public Fields -
Public Properties
Readonly
❌
Default: ❌
✔ if IncludeFields (default false)
AND
!IgnoreReadOnlyFields
(default false)
Default: ✔
if !IgnoreReadOnlyProperties (default false)
Writeonly
❌
Default: ❌
✔ if IncludeFields (default false)
✔
Read & Write
❌
Default: ❌
✔ if IncludeFields (default false)
✔
JsonSerializer 包含以下哪些?
Private/Protected/Internal 字段 | Private/Protected/Internal 属性 | Public 字段 | Public 属性 | |
---|---|---|---|---|
只读 | ||||
只写 | ||||
读写 |
Private OR Protected OR Internal Fields OR Properties |
Public Fields - | Public Properties | |
---|---|---|---|
Readonly | ❌ |
Default: ❌ ✔ if IncludeFields (default false) AND !IgnoreReadOnlyFields (default false) |
Default: ✔ if !IgnoreReadOnlyProperties (default false) |
Writeonly | ❌ |
Default: ❌ ✔ if IncludeFields (default false) |
✔ |
Read & Write | ❌ |
Default: ❌ ✔ if IncludeFields (default false) |
✔ |