Ejemplo n.º 1
0
        private void MergeResults(VaultClientHelper client, VaultHistoryDataSet destination, VaultHistoryItem [] history, string featureTag)
        {
            if (history == null)
            {
                return;
            }

            foreach (VaultHistoryItem item in history)
            {
                if (HistoryQueryHelper.IsChangeRelatedToTask(item.Comment, featureTag))
                {
                    destination.Add(client, item);
                }
            }
        }
Ejemplo n.º 2
0
        private ChangeHistoryDataSet GetVersions(string[] featureTags, VaultRepositoryAuthSettings connectionSettings)
        {
            using (VaultClientHelper client = new VaultClientHelper(connectionSettings))
            {
                VaultHistoryQueryRequest query    = PrepareQuery(client);
                VaultHistoryDataSet      versions = new VaultHistoryDataSet();

                foreach (string featureTag in featureTags)
                {
                    query.CommentSubstring = featureTag;
                    MergeResults(client, versions, Process(client, query), featureTag);
                }

                return(versions);
            }
        }
Ejemplo n.º 3
0
        public ChangeHistoryDataSet GetVersions(string featureBranch, VaultRepositoryAuthSettings connectionSettings)
        {
            using (VaultClientHelper client = new VaultClientHelper(connectionSettings))
            {
                VaultHistoryDataSet results = new VaultHistoryDataSet(featureBranch);
                foreach (VaultTxHistoryItem changeSet in GetChangeSets(client, featureBranch))
                {
                    foreach (VaultHistoryItemBase change in GetChanges(client, changeSet))
                    {
                        if (change != null)
                        {
                            // Don't query promotion info because it's done via branches, not labels.
                            results.Add(client, change);
                        }
                    }
                }

                return(results);
            }
        }