/// <summary>
        /// Initializes a new instance of the <see cref="LazyDataFormat" /> class.
        /// </summary>
        /// <param name="sdmxDataFormat">The SDMX data format.</param>
        /// <param name="actions">The actions.</param>
        /// <param name="encoding">The encoding.</param>
        public LazyDataFormat(DataType sdmxDataFormat, Queue<Action> actions, Encoding encoding)
        {
            this._sdmxDataFormat = sdmxDataFormat;
            this._actions = actions;
            this._encoding = encoding;

            // Rest always 2.1 behavior for no results
            this._delayBehavior = DataWriterDelayBehavior.UntilFirstKey;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="DelayedDataWriterEngine" /> class.
        /// </summary>
        /// <param name="dataWriterEngine">The data writer engine.</param>
        /// <param name="actions">The actions.</param>
        /// <param name="delayBehavior">The delay behavior.</param>
        /// <exception cref="System.ArgumentNullException">dataWriterEngine</exception>
        public DelayedDataWriterEngine(IDataWriterEngine dataWriterEngine, Queue<Action> actions, DataWriterDelayBehavior delayBehavior)
        {
            if (dataWriterEngine == null)
            {
                throw new ArgumentNullException("dataWriterEngine");
            }

            this._dataWriterEngine = dataWriterEngine;
            this._delayBehavior = delayBehavior;
            this._actions = actions ?? new Queue<Action>();
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="DelayedCrossWriterEngine" /> class.
 /// </summary>
 /// <param name="actions">The actions.</param>
 /// <param name="dataWriterEngine">The data writer engine.</param>
 /// <param name="delayBehavior">The delay behavior.</param>
 public DelayedCrossWriterEngine(Queue<Action> actions, ICrossSectionalWriterEngine dataWriterEngine, DataWriterDelayBehavior delayBehavior)
 {
     this._actions = actions;
     this._dataWriterEngine = dataWriterEngine;
     this._delayBehavior = delayBehavior;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="LazyDataFormat"/> class.
 /// </summary>
 /// <param name="sdmxDataFormat">The SDMX data format.</param>
 /// <param name="actions">The actions.</param>
 /// <param name="delayBehavior">The delay behavior.</param>
 /// <param name="xmlWriter">The XML writer.</param>
 public LazyDataFormat(DataType sdmxDataFormat, Queue<Action> actions, DataWriterDelayBehavior delayBehavior, XmlWriter xmlWriter)
 {
     this._sdmxDataFormat = sdmxDataFormat;
     this._actions = actions;
     this._delayBehavior = delayBehavior;
     this._xmlWriter = xmlWriter;
 }