public void AddConvTargets(Type[] targetTypes, MySqlDataConversionTechnique convTech) { for (int i = targetTypes.Length - 1; i >= 0; --i) { _convTechniques.Add(targetTypes[i], convTech); } }
public bool TryGetConvTechnique(Type targetType, out MySqlDataConversionTechnique found) => _convTechniques.TryGetValue(targetType, out found);
public void AddConvTarget(Type targetType, MySqlDataConversionTechnique convTech) { _convTechniques.Add(targetType, convTech); }
public static bool TryGetImplicitConversion(MySqlDataType mysqlDataType, Type targetType, out MySqlDataConversionTechnique foundTechnique) { if (s_implicitConvPlan.TryGetValue(mysqlDataType, out MySqlTypeConversionPlan convPlan)) { //found conv for some mysql data type if (convPlan.TryGetConvTechnique(targetType, out foundTechnique)) { return(true); } } //not found foundTechnique = MySqlDataConversionTechnique.Unknown; return(false); }
public bool TryGetConvTechnique(Type targetType, out MySqlDataConversionTechnique found) { return convTechniques.TryGetValue(targetType, out found); }
public void AddConvTargets(Type[] targetTypes, MySqlDataConversionTechnique convTech) { for (int i = targetTypes.Length - 1; i >= 0; --i) { convTechniques.Add(targetTypes[i], convTech); } }
public void AddConvTarget(Type targetType, MySqlDataConversionTechnique convTech) { this.convTechniques.Add(targetType, convTech); }
public static bool TryGetImplicitConversion(MySqlDataType mysqlDataType, Type targetType, out MySqlDataConversionTechnique foundTechnique) { MySqlTypeConversionPlan convPlan; if (implicitConvPlan.TryGetValue(mysqlDataType, out convPlan)) { //found conv for some mysql data type if (convPlan.TryGetConvTechnique(targetType, out foundTechnique)) { return true; } } //not found foundTechnique = MySqlDataConversionTechnique.Unknown; return false; }