|
@@ -267,37 +267,21 @@ namespace InABox.Core
|
|
|
public bool IncludeNullables { get; set; }
|
|
|
public string Version { get; set; }
|
|
|
|
|
|
- /// <summary>
|
|
|
- /// Handle correctly arrays of <see cref="object"/> inside of <see cref="Filter{T}.Value"/>.
|
|
|
- /// </summary>
|
|
|
- /// <remarks>
|
|
|
- /// True in all serialisation versions >= 1.2.
|
|
|
- /// </remarks>
|
|
|
- public bool HandleFilterObjectArrays { get; set; }
|
|
|
-
|
|
|
- public static BinarySerializationSettings Latest => V1_2;
|
|
|
+ public static BinarySerializationSettings Latest => V1_1;
|
|
|
|
|
|
public static BinarySerializationSettings V1_0 = new BinarySerializationSettings("1.0")
|
|
|
{
|
|
|
- IncludeNullables = false,
|
|
|
- HandleFilterObjectArrays = false
|
|
|
+ IncludeNullables = false
|
|
|
};
|
|
|
public static BinarySerializationSettings V1_1 = new BinarySerializationSettings("1.1")
|
|
|
{
|
|
|
- IncludeNullables = true,
|
|
|
- HandleFilterObjectArrays = false
|
|
|
- };
|
|
|
- public static BinarySerializationSettings V1_2 = new BinarySerializationSettings("1.2")
|
|
|
- {
|
|
|
- IncludeNullables = true,
|
|
|
- HandleFilterObjectArrays = true
|
|
|
+ IncludeNullables = true
|
|
|
};
|
|
|
|
|
|
public static BinarySerializationSettings ConvertVersionString(string version) => version switch
|
|
|
{
|
|
|
"1.0" => V1_0,
|
|
|
"1.1" => V1_1,
|
|
|
- "1.2" => V1_2,
|
|
|
_ => V1_0
|
|
|
};
|
|
|
|