~ruther/NosSmooth

ref: 8a7e32d9846a743cf31ae8c05dff37fc77b6875a NosSmooth/Packets/NosSmooth.PacketSerializer.Abstractions/DeserializeOptions.cs -rw-r--r-- 806 bytes
8a7e32d9 — František Boháček chore(packets): update versions 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//
//  DeserializeOptions.cs
//
//  Copyright (c) František Boháček. All rights reserved.
//  Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System.Diagnostics.CodeAnalysis;

namespace NosSmooth.PacketSerializer.Abstractions;

/// <summary>
/// Options for deserialization.
/// </summary>
/// <param name="CanBeNull">Whether the argument may be null.</param>
[SuppressMessage
(
    "StyleCop.CSharp.NamingRules",
    "SA1313:Parameter names should begin with lower-case letter",
    Justification = "Fix this."
)]
public record struct DeserializeOptions(bool CanBeNull = false)
{
    /// <summary>
    /// Gets the nullable deserialize options.
    /// </summary>
    public static DeserializeOptions Nullable => new DeserializeOptions(true);
}
Do not follow this link