Newtonsoft.Json.JsonConverter.CanConvert C# (CSharp) Method

CanConvert() public abstract method

Determines whether this instance can convert the specified object type.
public abstract CanConvert ( Type objectType ) : bool
objectType System.Type Type of the object.
return bool
        public abstract bool CanConvert(Type objectType);

Usage Example

Ejemplo n.º 1
0
 internal static JsonConverter GetMatchingConverter(IList <JsonConverter> converters, Type objectType)
 {
     if (converters != null)
     {
         for (int index = 0; index < converters.Count; ++index)
         {
             JsonConverter jsonConverter = converters[index];
             if (jsonConverter.CanConvert(objectType))
             {
                 return(jsonConverter);
             }
         }
     }
     return((JsonConverter)null);
 }
All Usage Examples Of Newtonsoft.Json.JsonConverter::CanConvert