Click or drag to resize

JsonConfFlagConverter Class

Serializes / Deserializes a flags based enum type between the flag value and a json object with a boolean property for each flag (true if the flags is set).
Inheritance Hierarchy
SystemObject
  JsonConverter
    MFiles.VAF.ConfigurationJsonConfFlagConverter

Namespace:  MFiles.VAF.Configuration
Assembly:  MFiles.VAF.Configuration (in MFiles.VAF.Configuration.dll) Version: 2.2.0.9
Syntax
C#
public class JsonConfFlagConverter : JsonConverter

The JsonConfFlagConverter type exposes the following members.

Constructors
  NameDescription
Public methodJsonConfFlagConverter
Top
Properties
  NameDescription
Public propertyCanRead
Gets a value indicating whether this JsonConverter can read JSON.
(Inherited from JsonConverter.)
Public propertyCanWrite
Gets a value indicating whether this JsonConverter can write JSON.
(Inherited from JsonConverter.)
Top
Methods
  NameDescription
Public methodCanConvert
Determines if the converted can convert a certain type.
(Overrides JsonConverter.CanConvert(Type).)
Public methodConvertFlagObject(Type, JObject, Int32)
Converts a flag object to a corresponding numeric flags value.
Public methodConvertFlagObjectTFlags(JObject, Int32)
Converts a flag object to a corresponding numeric flags value.
Public methodConvertFlags
Converts a numeric flags value to a corresponding flag object.
Public methodGetFlagPropertyName
Gets the json property name for a flag.
Public methodReadJson
Converts various json types to a valid flags type.
(Overrides JsonConverter.ReadJson(JsonReader, Type, Object, JsonSerializer).)
Public methodWriteJson
Serializes a flag value to a json value.
(Overrides JsonConverter.WriteJson(JsonWriter, Object, JsonSerializer).)
Top
See Also