Class: TFSGraph::Populators::ForArchivedBranch
- Inherits:
-
Object
- Object
- TFSGraph::Populators::ForArchivedBranch
- Includes:
- Utilities
- Defined in:
- lib/tfs_graph/populators/for_archived_branch.rb
Overview
incremental updates for a branch and its changesets does not update merges. have to do that once all changesets for a project are fetched
Constant Summary
Constants included from StoreHelpers
Instance Method Summary collapse
-
#initialize(project, branch) ⇒ ForArchivedBranch
constructor
A new instance of ForArchivedBranch.
- #populate ⇒ Object
Methods included from Utilities
#clean, #finalize, #find_branch, #find_project
Methods included from StoreHelpers
#flush_all, #last_updated_on, #mark_as_updated
Constructor Details
#initialize(project, branch) ⇒ ForArchivedBranch
Returns a new instance of ForArchivedBranch.
10 11 12 13 14 15 |
# File 'lib/tfs_graph/populators/for_archived_branch.rb', line 10 def initialize(project, branch) @project = project @branch = branch @changeset_store = ChangesetStore.new(branch) end |
Instance Method Details
#populate ⇒ Object
17 18 19 20 21 22 23 24 25 |
# File 'lib/tfs_graph/populators/for_archived_branch.rb', line 17 def populate return @branch.changesets unless @branch.changesets.empty? all_changesets = @changeset_store.fetch_and_cache ChangesetTreeBuilder.to_tree(@branch, all_changesets.sort) @branch.updated! all_changesets end |