Exemplo n.º 1
0
        /// <summary>
        /// Writes the Atom entry body.
        /// </summary>
        private void WriteEntry(AtomEntry entry)
        {
            if (this._writer == null)
            {
                throw new InvalidOperationException("AtomWriter has been closed, and can not be written to.");
            }

            if (entry == null)
            {
                throw new RequiredElementNotFoundException("AtomEntry cannot be null.");
            }

            this._writer.WriteRaw(entry.ToString());

            this._writer.Flush();
            this._writer.Close();
            this._writer = null;
        }