/Main/src/DynamicDataDisplay/Common/TokenizerHelper.cs
C# | 24 lines | 21 code | 3 blank | 0 comment | 3 complexity | a114997e6205c83b6c59278f06d3a001 MD5 | raw file
Possible License(s): CC-BY-SA-3.0
1using System; 2using System.Collections.Generic; 3using System.Linq; 4using System.Text; 5using System.Globalization; 6 7namespace Microsoft.Research.DynamicDataDisplay.Common 8{ 9 internal static class TokenizerHelper 10 { 11 public static char GetNumericListSeparator(IFormatProvider provider) 12 { 13 char separator = ','; 14 15 NumberFormatInfo numberInfo = NumberFormatInfo.GetInstance(provider); 16 if (numberInfo.NumberDecimalSeparator.Length > 0 && separator == numberInfo.NumberDecimalSeparator[0]) 17 { 18 separator = ';'; 19 } 20 21 return separator; 22 } 23 } 24}