Enum JsonSerializationOptions
- Namespace
- Alis.Core.Aspect.Data.Json
- Assembly
- Alis.dll
Define options for JSON serialization.
[Flags]
public enum JsonSerializationOptions
Fields
None = 0
-
No option. Use Type Descriptor (including custom ones) when serializing custom objects.
UseReflection = 1
-
Use pure reflection when serializing custom objects.
UseXmlIgnore = 2
-
Avoid fields and properties marked with the XmlIgnore attribute.
DateFormatCustom = 4
-
Use the format defined in the DateTimeFormat property of the JsonOptions class.
SerializeFields = 8
-
Serializes fields.
UseISerializable = 16
-
Use the ISerializable interface.
DateFormatJs = 32
-
Use the [new Date(utc milliseconds)] format. Note this format is not generally supported by browsers native JSON parsers.
DateFormatIso8601 = 64
-
Use the ISO 8601 string format ('s' DateTime format).
UseScriptIgnore = 128
-
Avoid fields and properties marked with the ScriptIgnore attribute.
DateFormatRoundtripUtc = 256
-
Use the ISO 8601 roundtrip string format ('o' DateTime format).
EnumAsText = 512
-
Serialize enum values as text.
ContinueOnCycle = 1024
-
Continue serialization if a cycle was detected.
ContinueOnValueError = 2048
-
Continue serialization if getting a value throws error.
SkipNullPropertyValues = 4096
-
Don't serialize properties with a null value.
DateTimeOffsetFormatCustom = 8192
-
Use the format defined in the DateTimeOffsetFormat property of the JsonOptions class.
SkipNullDateTimeValues = 16384
-
Don't serialize null date time values.
AutoParseDateTime = 32768
-
Automatically parse date time.
WriteKeysWithoutQuotes = 65536
-
Write dictionary keys without quotes.
ByteArrayAsBase64 = 131072
-
Serializes byte arrays as base 64 strings.
StreamsAsBase64 = 262144
-
Serializes streams as base 64 strings.
SkipZeroValueTypes = 524288
-
Don't serialize value type with a zero value.
UseJsonAttribute = 1048576
-
Use the JSON attribute.
SkipDefaultValues = 2097152
-
Don't serialize values equal to the default member (property, field) value, if defined.
TimeSpanAsText = 4194304
-
Serialize TimeSpan values as text.
SkipGetOnly = 8388608
-
Skip members with get only method.
Default = 1082392
-
The default value.