/// <summary>
        /// Construtor usado na deserialização dos dados.
        /// </summary>
        /// <param name="info"></param>
        /// <param name="context"></param>
        private TokenPingResult(SerializationInfo info, StreamingContext context)
        {
            Message       = (TokenPingResultMessage)info.GetValue("Message", typeof(TokenPingResultMessage));
            ServerTime    = new DateTimeOffset(info.GetDateTime("ServerTimer"));
            Notifications = new List <IPingMessage>();
            TokenPingResultStatus status = TokenPingResultStatus.Success;

            if (Enum.TryParse <TokenPingResultStatus>(info.GetString("Status"), out status))
            {
                Status = status;
            }
        }
        /// <summary>
        /// Lê os dados serializados.
        /// </summary>
        /// <param name="reader"></param>
        void IXmlSerializable.ReadXml(System.Xml.XmlReader reader)
        {
            reader.ReadStartElement();
            if (!reader.IsEmptyElement && reader.LocalName == "Message")
            {
                var message = new TokenPingResultMessage();
                ((IXmlSerializable)message).ReadXml(reader);
                Message = message;
                reader.ReadEndElement();
            }
            else
            {
                reader.Skip();
            }
            var            serverTimeValue = reader.ReadElementString("ServerTime", SecurityNamespaces.Security);
            DateTimeOffset serverTime      = DateTimeOffset.Now;

            if (DateTimeOffset.TryParse(serverTimeValue, System.Globalization.CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.None, out serverTime))
            {
                this.ServerTime = serverTime;
            }
            var status = reader.ReadElementString("Status", SecurityNamespaces.Security);
            TokenPingResultStatus tokenStatus = TokenPingResultStatus.Success;

            if (Enum.TryParse <TokenPingResultStatus>(status, out tokenStatus))
            {
                Status = tokenStatus;
            }
            if (!reader.IsEmptyElement && reader.LocalName == "Notifications")
            {
                var notifications = new List <IPingMessage>();
                reader.ReadStartElement("Notifications", SecurityNamespaces.Security);
                while (reader.NodeType != System.Xml.XmlNodeType.EndElement)
                {
                    var join = new PingMessage();
                    ((System.Xml.Serialization.IXmlSerializable)join).ReadXml(reader);
                    notifications.Add(join);
                }
                Notifications = notifications;
                reader.ReadEndElement();
            }
            else
            {
                reader.Skip();
            }
            reader.ReadEndElement();
        }