Microsoft.TeamFoundation.Client.TeamFoundationServer.ToLocalXml C# (CSharp) Method

ToLocalXml() public method

public ToLocalXml ( ) : System.Xml.Linq.XElement
return System.Xml.Linq.XElement
        public override XElement ToLocalXml()
        {
            var serverElement = new XElement("Server", 
                                    new XAttribute("Type", (int)ServerType.TFS),
                                    new XAttribute("Name", this.Name),
                                    new XAttribute("Url", this.Uri),
                                    new XAttribute("Domain", this.Credentials.Domain),
                                    new XAttribute("UserName", this.Credentials.UserName),
                                    this.ProjectCollections.Select(p => p.ToLocalXml()));
            if (IsPasswordSavedInXml)
                serverElement.Add(new XAttribute("Password", this.Credentials.Password));
            return serverElement;
        }