internal static InvalidOperationException GetJsonElementWrongTypeException( string expectedTypeName, JsonTokenType actualType) { return(GetInvalidOperationException( SR.Format(SR.JsonElementHasWrongType, expectedTypeName, actualType.ToValueKind()))); }
internal static InvalidOperationException GetJsonElementWrongTypeException( JsonTokenType expectedType, JsonTokenType actualType) { return(GetJsonElementWrongTypeException(expectedType.ToValueKind(), actualType.ToValueKind())); }
internal static void ThrowJsonElementWrongTypeException( JsonTokenType expectedType, JsonTokenType actualType) { throw GetJsonElementWrongTypeException(expectedType.ToValueKind(), actualType.ToValueKind()); }