Esempio n. 1
0
 internal override void Update(XmlNode node)
 {
     Status    = TeamCityUtility.LoadBuildStatus(node.Attributes[StatusProperty.XmlNodeName]);
     Number    = TeamCityUtility.LoadString(node.Attributes[NumberProperty.XmlNodeName]);
     StartDate = TeamCityUtility.LoadDateForSure(node.Attributes[StartDateProperty.XmlNodeName]);
     BuildType = Context.BuildTypes.Lookup(node.Attributes[BuildTypeProperty.XmlNodeName].InnerText);
 }
Esempio n. 2
0
 internal override void Update(XmlNode node)
 {
     base.Update(node);
     Project = Context.Projects.Lookup(
         TeamCityUtility.LoadString(node.Attributes["projectId"]),
         TeamCityUtility.LoadString(node.Attributes["projectName"]));
 }
Esempio n. 3
0
 internal Build(TeamCityServiceContext context, XmlNode node)
     : base(context, node)
 {
     _status    = TeamCityUtility.LoadBuildStatus(node.Attributes[StatusProperty.XmlNodeName]);
     _number    = TeamCityUtility.LoadString(node.Attributes[NumberProperty.XmlNodeName]);
     _startDate = TeamCityUtility.LoadDateForSure(node.Attributes[StartDateProperty.XmlNodeName]);
     _buildtype = Context.BuildTypes.Lookup(node.Attributes[BuildTypeProperty.XmlNodeName].InnerText);
 }
Esempio n. 4
0
        protected TeamCityObject(TeamCityServiceContext context, XmlNode node)
        {
            Verify.Argument.IsNotNull(context, "context");
            Verify.Argument.IsNotNull(node, "node");

            _context = context;
            _id      = TeamCityUtility.LoadString(node.Attributes[IdProperty.XmlNodeName]);
            _webUrl  = TeamCityUtility.LoadString(node.Attributes[WebUrlProperty.XmlNodeName]);
        }
Esempio n. 5
0
        internal T Lookup(XmlNode node)
        {
            Verify.Argument.IsNotNull(node, "node");

            var id = TeamCityUtility.LoadString(node.Attributes[TeamCityObject.IdProperty.XmlNodeName]);
            T   obj;

            lock (SyncRoot)
            {
                if (!_cache.TryGetValue(id, out obj))
                {
                    obj = Create(node);
                    _cache.Add(id, obj);
                }
                else
                {
                    obj.Update(node);
                }
            }
            return(obj);
        }
Esempio n. 6
0
        internal virtual void Update(XmlNode node)
        {
            Verify.Argument.IsNotNull(node, "node");

            WebUrl = TeamCityUtility.LoadString(node.Attributes[WebUrlProperty.XmlNodeName]);
        }
Esempio n. 7
0
 internal BuildType(TeamCityServiceContext context, XmlNode node)
     : base(context, node)
 {
     _builds  = new BuildTypeBuildsCollection(this, Context.Builds);
     _project = Context.Projects.Lookup(TeamCityUtility.LoadString(node.Attributes["projectId"]), TeamCityUtility.LoadString(node.Attributes["projectName"]));
 }
Esempio n. 8
0
 internal override void Update(XmlNode node)
 {
     base.Update(node);
     Name = TeamCityUtility.LoadString(node.Attributes[NameProperty.XmlNodeName]);
 }
Esempio n. 9
0
 protected NamedTeamCityObject(TeamCityServiceContext context, XmlNode node)
     : base(context, node)
 {
     _name = TeamCityUtility.LoadString(node.Attributes[NameProperty.XmlNodeName]);
 }