public void Serialize(Stream stream, ILocalizationTable table)
        {
            // Sort localization table entries by key before writing to the file.
            List<KeyValuePair<string, string>> data = table.ToList();
            data.Sort((first, second) => string.Compare(first.Key, second.Key, StringComparison.Ordinal));

            // Write data to file.
            using (TextWriter writer = new StreamWriter(stream))
            {
                foreach (var keyValuePair in data)
                {
                    writer.WriteLine("{0}={1}", keyValuePair.Key, keyValuePair.Value);
                }
            }
        }
        public void Serialize(Stream stream, ILocalizationTable table)
        {
            // Sort localization table entries by key before writing to the file.
            List <KeyValuePair <string, string> > data = table.ToList();

            data.Sort((first, second) => string.Compare(first.Key, second.Key, StringComparison.Ordinal));

            // Write data to file.
            using (TextWriter writer = new StreamWriter(stream))
            {
                foreach (var keyValuePair in data)
                {
                    writer.WriteLine("{0}={1}", keyValuePair.Key, keyValuePair.Value);
                }
            }
        }