示例#1
0
        /// <summary>
        /// Writes the record in the form of string, object dictionary.
        /// </summary>
        /// <param name="record">The record to write.</param>
        public void WriteRecord(Dictionary <string, object> record)
        {
            CheckDisposed();

            Dictionary <string, string> values = null;
            var errors = _validator.ValidateRecord(record, out values);

            if (errors.Count > 0)
            {
                throw SDMXValidationException.Create(errors, string.Format("Invalid record: {0}. See Errors property for details:", RecordToString(record)));
            }

            WriteRecord(values);
        }